/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/settings/ |
D | TwoStatePreferenceHelper.java | 67 final SwitchPreference switchPref = new SwitchPreference(checkBox.getContext()); in addSwitchPreferenceBasedOnCheckBoxPreference() local 68 switchPref.setTitle(checkBox.getTitle()); in addSwitchPreferenceBasedOnCheckBoxPreference() 69 switchPref.setKey(checkBox.getKey()); in addSwitchPreferenceBasedOnCheckBoxPreference() 70 switchPref.setOrder(checkBox.getOrder()); in addSwitchPreferenceBasedOnCheckBoxPreference() 71 switchPref.setPersistent(checkBox.isPersistent()); in addSwitchPreferenceBasedOnCheckBoxPreference() 72 switchPref.setEnabled(checkBox.isEnabled()); in addSwitchPreferenceBasedOnCheckBoxPreference() 73 switchPref.setChecked(checkBox.isChecked()); in addSwitchPreferenceBasedOnCheckBoxPreference() 74 switchPref.setSummary(checkBox.getSummary()); in addSwitchPreferenceBasedOnCheckBoxPreference() 75 switchPref.setSummaryOn(checkBox.getSummaryOn()); in addSwitchPreferenceBasedOnCheckBoxPreference() 76 switchPref.setSummaryOff(checkBox.getSummaryOff()); in addSwitchPreferenceBasedOnCheckBoxPreference() [all …]
|
/packages/apps/Settings/src/com/android/settings/notification/modes/ |
D | ZenModeSetTriggerLinkPreferenceController.java | 57 Preference switchPref = ((PreferenceCategory) preference).findPreference( in updateState() local 59 if (switchPref == null) { in updateState() 62 ((PrimarySwitchPreference) switchPref).setChecked(zenMode.getRule().isEnabled()); in updateState() 63 switchPref.setOnPreferenceChangeListener(mSwitchChangeListener); in updateState() 71 switchPref.setTitle(R.string.zen_mode_set_schedule_link); in updateState() 72 switchPref.setSummary(zenMode.getRule().getTriggerDescription()); in updateState() 73 switchPref.setIntent(new SubSettingLauncher(mContext) in updateState() 81 switchPref.setTitle(R.string.zen_mode_set_calendar_link); in updateState() 82 switchPref.setSummary(zenMode.getRule().getTriggerDescription()); in updateState() 83 switchPref.setIntent(new SubSettingLauncher(mContext) in updateState() [all …]
|
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/device/apps/specialaccess/ |
D | HighPower.java | 86 final TwoStatePreference switchPref = (SwitchWithSoundPreference) preference; in bindPreference() local 87 switchPref.setTitle(entry.label); in bindPreference() 88 switchPref.setKey(entry.info.packageName); in bindPreference() 89 switchPref.setIcon(entry.icon); in bindPreference() 91 switchPref.setChecked(false); in bindPreference() 92 switchPref.setEnabled(false); in bindPreference() 94 switchPref.setEnabled(true); in bindPreference() 95 switchPref.setChecked(!(Boolean) entry.extraInfo); in bindPreference() 96 switchPref.setOnPreferenceChangeListener((pref, newValue) -> { in bindPreference() 107 updateSummary(switchPref, entry.info.uid); in bindPreference() [all …]
|
D | ExternalSources.java | 75 final RestrictedSwitchPreference switchPref = (RestrictedSwitchPreference) preference; in bindPreference() local 76 switchPref.setTitle(entry.label); in bindPreference() 77 switchPref.setKey(entry.info.packageName); in bindPreference() 78 switchPref.setIcon(entry.icon); in bindPreference() 79 switchPref.setOnPreferenceChangeListener((pref, newValue) -> { in bindPreference() 86 switchPref.setChecked(state.isAllowed()); in bindPreference() 90 switchPref.setDisabledByAdmin(admin); in bindPreference() 92 switchPref.setEnabled(canChange(entry)); in bindPreference() 93 switchPref.setSummary(getPreferenceSummary(entry)); in bindPreference() 96 return switchPref; in bindPreference()
|
D | TurnScreenOn.java | 72 final TwoStatePreference switchPref = (SwitchWithSoundPreference) preference; in bindPreference() local 73 switchPref.setTitle(entry.label); in bindPreference() 74 switchPref.setKey("package:" + entry.info.uid + ":" + entry.info.packageName); in bindPreference() 75 switchPref.setIcon(entry.icon); in bindPreference() 76 switchPref.setChecked(((PermissionState) entry.extraInfo).isAllowed()); in bindPreference() 77 switchPref.setOnPreferenceChangeListener((pref, newValue) -> { in bindPreference() 82 switchPref.setSummaryOn(R.string.app_permission_summary_allowed); in bindPreference() 83 switchPref.setSummaryOff(R.string.app_permission_summary_not_allowed); in bindPreference() 84 return switchPref; in bindPreference()
|
D | AlarmsAndReminders.java | 67 final TwoStatePreference switchPref = (SwitchWithSoundPreference) preference; in bindPreference() local 68 switchPref.setTitle(entry.label); in bindPreference() 69 switchPref.setKey(entry.info.packageName); in bindPreference() 70 switchPref.setIcon(entry.icon); in bindPreference() 71 switchPref.setOnPreferenceChangeListener((pref, newValue) -> { in bindPreference() 78 switchPref.setSummary(getPreferenceSummary(entry)); in bindPreference() 79 switchPref.setChecked(((PermissionState) entry.extraInfo).isAllowed()); in bindPreference() 81 return switchPref; in bindPreference()
|
D | AppUsageAccess.java | 63 final TwoStatePreference switchPref = (SwitchWithSoundPreference) preference; in bindPreference() local 64 switchPref.setTitle(entry.label); in bindPreference() 65 switchPref.setKey(entry.info.packageName); in bindPreference() 66 switchPref.setIcon(entry.icon); in bindPreference() 67 switchPref.setOnPreferenceChangeListener((pref, newValue) -> { in bindPreference() 73 switchPref.setSummary(getPreferenceSummary(entry)); in bindPreference() 74 switchPref.setChecked(((PermissionState) entry.extraInfo).isAllowed()); in bindPreference() 76 return switchPref; in bindPreference()
|
D | AllFilesAccess.java | 59 final TwoStatePreference switchPref = (SwitchWithSoundPreference) preference; in bindPreference() local 60 switchPref.setTitle(entry.label); in bindPreference() 61 switchPref.setKey(entry.info.packageName); in bindPreference() 62 switchPref.setIcon(entry.icon); in bindPreference() 63 switchPref.setOnPreferenceChangeListener((pref, grant) -> { in bindPreference() 68 switchPref.setSummary(getPreferenceSummary(entry)); in bindPreference() 69 switchPref.setChecked(((PermissionState) entry.extraInfo).isAllowed()); in bindPreference() 71 return switchPref; in bindPreference()
|
D | WriteSettings.java | 67 final TwoStatePreference switchPref = (SwitchWithSoundPreference) preference; in bindPreference() local 68 switchPref.setTitle(entry.label); in bindPreference() 69 switchPref.setKey(entry.info.packageName); in bindPreference() 70 switchPref.setIcon(entry.icon); in bindPreference() 71 switchPref.setOnPreferenceChangeListener((pref, newValue) -> { in bindPreference() 77 switchPref.setSummary(getPreferenceSummary(entry)); in bindPreference() 78 switchPref.setChecked(((PermissionState) entry.extraInfo).isAllowed()); in bindPreference() 80 return switchPref; in bindPreference()
|
D | SystemAlertWindow.java | 72 final TwoStatePreference switchPref = (SwitchWithSoundPreference) preference; in bindPreference() local 73 switchPref.setTitle(entry.label); in bindPreference() 74 switchPref.setKey(entry.info.packageName); in bindPreference() 75 switchPref.setIcon(entry.icon); in bindPreference() 76 switchPref.setOnPreferenceChangeListener((pref, newValue) -> { in bindPreference() 83 switchPref.setSummary(getPreferenceSummary(entry)); in bindPreference() 84 switchPref.setChecked(((PermissionState) entry.extraInfo).isAllowed()); in bindPreference() 86 return switchPref; in bindPreference()
|
D | PictureInPicture.java | 116 final TwoStatePreference switchPref = (SwitchWithSoundPreference) preference; in bindPreference() local 117 switchPref.setTitle(entry.label); in bindPreference() 118 switchPref.setKey(entry.info.packageName); in bindPreference() 119 switchPref.setIcon(entry.icon); in bindPreference() 120 switchPref.setChecked((Boolean) entry.extraInfo); in bindPreference() 121 switchPref.setOnPreferenceChangeListener((pref, newValue) -> { in bindPreference() 126 switchPref.setSummaryOn(R.string.app_permission_summary_allowed); in bindPreference() 127 switchPref.setSummaryOff(R.string.app_permission_summary_not_allowed); in bindPreference() 128 return switchPref; in bindPreference()
|
/packages/apps/Settings/src/com/android/settings/inputmethod/ |
D | KeyboardLayoutPickerController.java | 99 if (!(preference instanceof TwoStatePreference switchPref)) { in handlePreferenceTreeClick() 103 final KeyboardLayout layout = mPreferenceMap.get(switchPref); in handlePreferenceTreeClick() 105 final boolean checked = switchPref.isChecked(); in handlePreferenceTreeClick()
|
/packages/apps/Settings/src/com/android/settings/network/telephony/ |
D | ContactDiscoveryPreferenceController.java | 122 TwoStatePreference switchPref = (TwoStatePreference) preference; in registerUceObserver() 123 switchPref.setChecked(isChecked()); in registerUceObserver()
|
/packages/apps/Settings/src/com/android/settings/applications/specialaccess/deviceadmin/ |
D | DeviceAdminListPreferenceController.java | 190 if (!(pref instanceof RestrictedSwitchPreference switchPref)) { in refreshUI() 193 preferenceCache.put(switchPref.getKey(), switchPref); in refreshUI() local
|
/packages/apps/Dialer/java/com/android/dialer/assisteddialing/ui/ |
D | AssistedDialingSettingFragment.java | 74 SwitchPreference switchPref = in onCreate() local 86 switchPref.setOnPreferenceChangeListener(this::logIfUserDisabledFeature); in onCreate()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/wifi/calling/ |
D | WifiCallingSettingsForSubTest.java | 381 protected void setSwitchBar(SettingsMainSwitchPreference switchPref) { in setSwitchBar() argument 382 mSwitchPref = switchPref; in setSwitchBar()
|
/packages/apps/Car/Settings/src/com/android/car/settings/inputmethod/ |
D | KeyboardManagementPreferenceController.java | 217 switchPreference.setOnPreferenceChangeListener((switchPref, newValue) -> { in createSwitchPreference() argument
|