Home
last modified time | relevance | path

Searched refs:Preference (Results 1 – 25 of 1742) sorted by relevance

12345678910>>...70

/packages/apps/StorageManager/robotests/src/com/android/storagemanager/utils/
DPreferenceListCacheTest.java20 import androidx.preference.Preference;
53 setupMockPreferenceGroup(new Preference[0]); in testEmptyPreferenceGroup()
58 verify(mGroup, never()).removePreference(any(Preference.class)); in testEmptyPreferenceGroup()
63 Preference first = createPreference("first"); in testCacheAndRestoreAllPreferences()
64 Preference second = createPreference("second"); in testCacheAndRestoreAllPreferences()
65 Preference third = createPreference("third"); in testCacheAndRestoreAllPreferences()
66 Preference[] preferences = new Preference[] {first, second, third}; in testCacheAndRestoreAllPreferences()
75 verify(mGroup, never()).removePreference(any(Preference.class)); in testCacheAndRestoreAllPreferences()
80 Preference first = createPreference("first"); in testRestoreSomePreferences()
81 Preference second = createPreference("second"); in testRestoreSomePreferences()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/dashboard/
DDashboardFeatureProviderImplTest.java57 import androidx.preference.Preference;
151 final Preference preference = new Preference(RuntimeEnvironment.application); in bindPreference_shouldBindAllData()
158 MetricsEvent.SETTINGS_GESTURES, preference, tile, "123", Preference.DEFAULT_ORDER); in bindPreference_shouldBindAllData()
171 final Preference preference = new SwitchPreference(RuntimeEnvironment.application); in bindPreference_shouldBindAllSwitchData()
179 null /* key*/, Preference.DEFAULT_ORDER); in bindPreference_shouldBindAllSwitchData()
192 final Preference preference = new Preference(RuntimeEnvironment.application); in bindPreference_noFragmentMetadata_shouldBindIntent()
197 MetricsEvent.SETTINGS_GESTURES, preference, tile, "123", Preference.DEFAULT_ORDER); in bindPreference_noFragmentMetadata_shouldBindIntent()
206 final Preference preference = new Preference(RuntimeEnvironment.application); in bindPreference_noFragmentMetadata_shouldBindToProfileSelector()
213 MetricsEvent.SETTINGS_GESTURES, preference, tile, "123", Preference.DEFAULT_ORDER); in bindPreference_noFragmentMetadata_shouldBindToProfileSelector()
221 final Preference preference = new Preference(RuntimeEnvironment.application); in bindPreference_noFragmentMetadataSingleUser_shouldBindToDirectLaunchIntent()
[all …]
/packages/apps/Settings/src/com/android/settings/applications/
DAppStorageSizesController.java24 import androidx.preference.Preference;
33 private final Preference mTotalSize;
34 private final Preference mAppSize;
35 private final Preference mDataSize;
36 private final Preference mCacheSize;
50 private AppStorageSizesController(Preference total, Preference app, in AppStorageSizesController()
51 Preference data, Preference cache, @StringRes int computing, @StringRes int error) { in AppStorageSizesController()
137 private Preference mTotalSize;
138 private Preference mAppSize;
139 private Preference mDataSize;
[all …]
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/applications/
DAppStorageSizesController.java24 import androidx.preference.Preference;
34 private final Preference mTotalSize;
35 private final Preference mAppSize;
36 private final Preference mDataSize;
37 private final Preference mCacheSize;
51 private AppStorageSizesController(Preference total, Preference app, in AppStorageSizesController()
52 Preference data, Preference cache, @StringRes int computing, @StringRes int error) { in AppStorageSizesController()
138 private Preference mTotalSize;
139 private Preference mAppSize;
140 private Preference mDataSize;
[all …]
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/language/
DLanguageBasePreferenceControllerTest.java29 import androidx.preference.Preference;
128 assertThat(mController.onPreferenceClick(new Preference(mContext))).isFalse(); in testOnPreferenceClick_noLocale_returnsFalse()
134 Preference preference = new Preference(mContext); in testOnPreferenceClick_hasMultipleChildLocales_returnsTrue()
142 Preference preference = new Preference(mContext); in testOnPreferenceClick_hasMultipleChildLocales_localeNotUpdated()
151 Preference preference = new Preference(mContext); in testOnPreferenceClick_hasMultipleChildLocales_neverCallsGoBack()
160 Preference preference = new Preference(mContext); in testOnPreferenceClick_hasSingleChildLocale_returnsTrue()
168 Preference preference = new Preference(mContext); in testOnPreferenceClick_hasSingleChildLocale_localeUpdated()
177 Preference preference = new Preference(mContext); in testOnPreferenceClick_hasSingleChildLocale_callsGoBack()
186 Preference preference = new Preference(mContext); in testOnPreferenceClick_noChildLocale_returnsTrue()
194 Preference preference = new Preference(mContext); in testOnPreferenceClick_noChildLocale_localeUpdated()
[all …]
/packages/apps/Car/libs/car-ui-lib/src/com/android/car/ui/preference/
DPreferenceFragment.java35 import androidx.preference.Preference;
137 public void onDisplayPreferenceDialog(Preference preference) { in onDisplayPreferenceDialog()
207 Map<Preference, String> dependencies = new HashMap<>(); in setPreferenceScreen()
208 List<Preference> children = new ArrayList<>(); in setPreferenceScreen()
211 Deque<Preference> stack = new ArrayDeque<>(); in setPreferenceScreen()
215 Preference preference = stack.removeFirst(); in setPreferenceScreen()
227 for (Preference child : children) { in setPreferenceScreen()
228 Preference replacement = getReplacementFor(child); in setPreferenceScreen()
242 for (Map.Entry<Preference, String> entry : dependencies.entrySet()) { in setPreferenceScreen()
249 private static final List<Pair<Class<? extends Preference>, Class<? extends Preference>>>
[all …]
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/common/
DFakePreferenceController.java22 import androidx.preference.Preference;
30 public class FakePreferenceController extends PreferenceController<Preference> {
42 private Preference mUpdateStateArg;
44 private Preference mHandlePreferenceChangedPreferenceArg;
47 private Preference mHandlePreferenceClickedArg;
58 protected Class<Preference> getPreferenceType() { in getPreferenceType()
59 return Preference.class; in getPreferenceType()
136 protected void updateState(Preference preference) { in updateState()
141 Preference getUpdateStateArg() { in getUpdateStateArg()
150 protected boolean handlePreferenceChanged(Preference preference, Object newValue) { in handlePreferenceChanged()
[all …]
DExtraSettingsLoaderTest.java32 import androidx.preference.Preference;
92 Map<Preference, Bundle> preferenceToBundleMap = mExtraSettingsLoader.loadPreferences( in testLoadPreference_stringResources_shouldLoadResources()
97 for (Preference p : preferenceToBundleMap.keySet()) { in testLoadPreference_stringResources_shouldLoadResources()
126 Map<Preference, Bundle> preferenceToBundleMap = mExtraSettingsLoader.loadPreferences( in testLoadPreference_metadataBundleIsValue()
131 for (Preference p : preferenceToBundleMap.keySet()) { in testLoadPreference_metadataBundleIsValue()
166 Map<Preference, Bundle> preferenceToBundleMap = mExtraSettingsLoader.loadPreferences( in testLoadPreference_integerResources_shouldLoadResources()
171 for (Preference p : preferenceToBundleMap.keySet()) { in testLoadPreference_integerResources_shouldLoadResources()
197 Map<Preference, Bundle> preferenceToBundleMap = mExtraSettingsLoader.loadPreferences( in testLoadPreference_noDefaultSummary()
200 for (Preference p : preferenceToBundleMap.keySet()) { in testLoadPreference_noDefaultSummary()
225 Map<Preference, Bundle> preferenceToBundleMap = mExtraSettingsLoader.loadPreferences( in testLoadPreference_noCategory_shouldSetToDeviceCategory()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/accounts/
DAccountTypePreferenceLoaderTest.java33 import androidx.preference.Preference;
97 Preference pref1 = mock(Preference.class); in updatePreferenceIntents_shouldRunRecursively()
100 Preference pref3 = mock(Preference.class); in updatePreferenceIntents_shouldRunRecursively()
109 Preference pref21 = mock(Preference.class); in updatePreferenceIntents_shouldRunRecursively()
110 Preference pref22 = mock(Preference.class); in updatePreferenceIntents_shouldRunRecursively()
115 Preference pref42 = mock(Preference.class); in updatePreferenceIntents_shouldRunRecursively()
120 Preference pref411 = mock(Preference.class); in updatePreferenceIntents_shouldRunRecursively()
121 Preference pref412 = mock(Preference.class); in updatePreferenceIntents_shouldRunRecursively()
/packages/apps/TvSettings/Settings/tests/robotests/src/com/android/tv/settings/
DMainFragmentTest.java36 import androidx.preference.Preference;
73 final Preference networkPref = mock(Preference.class); in testUpdateConnectivity_NoNetwork()
90 final Preference networkPref = mock(Preference.class); in testUpdateConnectivity_hasEthernet()
107 final Preference networkPref = mock(Preference.class); in testUpdateConnectivity_hasEthernetConnected()
124 final Preference networkPref = mock(Preference.class); in testUpdateConnectivity_wifiSignal()
173 final Preference networkPref = mock(Preference.class); in testUpdateConnectivity_notConnected()
190 final Preference networkPref = mock(Preference.class); in testUpdateConnectivity_cellSignal()
237 final Preference accountsPref = mock(Preference.class); in testUpdateAccountPrefInfo_hasOneAccount()
253 final Preference accountsPref = mock(Preference.class); in testUpdateAccountPrefInfo_hasNoAccount()
268 final Preference accountsPref = mock(Preference.class); in testUpdateAccountPrefInfo_hasMoreThanOneAccount()
[all …]
/packages/apps/EmergencyInfo/src/com/android/emergency/edit/
DEditInfoFragment.java26 import androidx.preference.Preference.OnPreferenceChangeListener;
28 import androidx.preference.Preference;
55 private final Map<String, Preference> mMedicalInfoPreferences =
56 new HashMap<String, Preference>();
68 Preference preference = findPreference(preferenceKey); in onCreatePreferences()
85 Preference addEmergencyContact = findPreference(PreferenceKeys.KEY_ADD_EMERGENCY_CONTACT); in onCreatePreferences()
86 addEmergencyContact.setOnPreferenceClickListener(new Preference in onCreatePreferences()
89 public boolean onPreferenceClick(Preference preference) { in onCreatePreferences()
118 for (Preference preference : mMedicalInfoPreferences.values()) { in reloadFromPreference()
133 public void onDisplayPreferenceDialog(Preference preference) { in onDisplayPreferenceDialog()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/network/
DMobileNetworkListControllerTest.java56 import androidx.preference.Preference;
76 private Preference mAddMorePreference;
87 mAddMorePreference = new Preference(mContext); in setUp()
136 final ArgumentCaptor<Preference> preferenceCaptor = ArgumentCaptor.forClass( in displayPreference_twoSubscriptions_correctlySetup()
137 Preference.class); in displayPreference_twoSubscriptions_correctlySetup()
139 final Preference pref1 = preferenceCaptor.getAllValues().get(0); in displayPreference_twoSubscriptions_correctlySetup()
140 final Preference pref2 = preferenceCaptor.getAllValues().get(1); in displayPreference_twoSubscriptions_correctlySetup()
172 final ArgumentCaptor<Preference> preferenceCaptor = ArgumentCaptor.forClass( in displayPreference_oneActiveESimOneInactivePSim_correctlySetup()
173 Preference.class); in displayPreference_oneActiveESimOneInactivePSim_correctlySetup()
175 Preference pref1 = preferenceCaptor.getAllValues().get(0); in displayPreference_oneActiveESimOneInactivePSim_correctlySetup()
[all …]
/packages/apps/TvSettings/Settings/tests/robotests/src/com/android/tv/settings/device/
DDevicePrefFragmentTest.java37 import androidx.preference.Preference;
72 final Preference developerPref = mock(Preference.class); in testUpdateDeveloperOptions_developerDisabled()
86 final Preference developerPref = mock(Preference.class); in testUpdateDeveloperOptions_notAdmin()
98 final Preference developerPref = mock(Preference.class); in testUpdateDeveloperOptions_developerEnabled()
108 final Preference castPref = mock(Preference.class); in testUpdateCastSettings()
144 final Preference autofillPref = mock(Preference.class); in testUpdateAutofillSettings_noCandiate()
159 final Preference autofillPref = mock(Preference.class); in testUpdateAutofillSettings_selected()
182 final Preference autofillPref = mock(Preference.class); in testUpdateAutofillSettings_selectedNone()
/packages/apps/PermissionController/src/com/android/permissioncontroller/role/ui/
DDefaultAppListChildFragment.java33 import androidx.preference.Preference;
56 implements Preference.OnPreferenceClickListener {
108 ArrayMap<String, Preference> oldPreferences = new ArrayMap<>(); in onRoleListChanged()
110 ArrayMap<String, Preference> oldWorkPreferences = new ArrayMap<>(); in onRoleListChanged()
120 oldWorkPreferenceCategory.setOrder(Preference.DEFAULT_ORDER); in onRoleListChanged()
145 @NonNull ArrayMap<String, Preference> oldPreferences) { in clearPreferences()
147 Preference preference = preferenceGroup.getPreference(i); in clearPreferences()
150 preference.setOrder(Preference.DEFAULT_ORDER); in clearPreferences()
156 @NonNull List<RoleItem> roleItems, @NonNull ArrayMap<String, Preference> oldPreferences, in addPreferences()
157 @NonNull Preference.OnPreferenceClickListener listener, @NonNull UserHandle user, in addPreferences()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/deviceinfo/storage/
DUserProfileControllerTest.java35 import androidx.preference.Preference;
79 final ArgumentCaptor<Preference> argumentCaptor = ArgumentCaptor.forClass(Preference.class); in controllerAddsPrimaryProfilePreference()
81 final Preference preference = argumentCaptor.getValue(); in controllerAddsPrimaryProfilePreference()
90 final ArgumentCaptor<Preference> argumentCaptor = ArgumentCaptor.forClass(Preference.class); in tappingProfilePreferenceSendsToStorageProfileFragment()
92 final Preference preference = argumentCaptor.getValue(); in tappingProfilePreferenceSendsToStorageProfileFragment()
117 final ArgumentCaptor<Preference> argumentCaptor = ArgumentCaptor.forClass(Preference.class); in acceptingResultUpdatesPreferenceSize()
119 final Preference preference = argumentCaptor.getValue(); in acceptingResultUpdatesPreferenceSize()
133 final ArgumentCaptor<Preference> argumentCaptor = ArgumentCaptor.forClass(Preference.class); in iconCallbackChangesPreferenceIcon()
135 final Preference preference = argumentCaptor.getValue(); in iconCallbackChangesPreferenceIcon()
/packages/apps/Car/Settings/src/com/android/car/settings/inputmethod/
DEnabledKeyboardPreferenceController.java29 import androidx.preference.Preference;
51 private final Map<String, Preference> mPreferences = new ArrayMap<>();
73 List<Preference> preferencesToDisplay = new ArrayList<>(); in updateState()
82 Preference preference = createPreference(inputMethodInfo); in updateState()
84 Preference displayedPreference = mPreferences.get(preference.getKey()); in updateState()
98 PreferenceGroup preferenceGroup, List<Preference> preferencesToDisplay, in updatePreferenceGroup()
101 (Preference a) -> a.getTitle().toString()) in updatePreferenceGroup()
102 .thenComparing((Preference a) -> a.getSummary().toString())); in updatePreferenceGroup()
110 Preference pref = preferencesToDisplay.get(i); in updatePreferenceGroup()
120 private Preference createPreference(InputMethodInfo inputMethodInfo) { in createPreference()
[all …]
/packages/apps/CellBroadcastReceiver/legacy/src/com/android/cellbroadcastreceiver/
DLegacyCellBroadcastContentProvider.java29 CellBroadcasts.Preference.ENABLE_CMAS_AMBER_PREF,
30 CellBroadcasts.Preference.ENABLE_AREA_UPDATE_INFO_PREF,
31 CellBroadcasts.Preference.ENABLE_TEST_ALERT_PREF,
32 CellBroadcasts.Preference.ENABLE_STATE_LOCAL_TEST_PREF,
33 CellBroadcasts.Preference.ENABLE_PUBLIC_SAFETY_PREF,
34 CellBroadcasts.Preference.ENABLE_CMAS_SEVERE_THREAT_PREF,
35 CellBroadcasts.Preference.ENABLE_CMAS_EXTREME_THREAT_PREF,
36 CellBroadcasts.Preference.ENABLE_CMAS_PRESIDENTIAL_PREF,
37 CellBroadcasts.Preference.ENABLE_EMERGENCY_PERF,
38 CellBroadcasts.Preference.ENABLE_ALERT_VIBRATION_PREF,
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/notification/zen/
DZenModeButtonPreferenceControllerTest.java37 import androidx.preference.Preference;
64 private Preference mockPref;
98 final Preference mockPref = mock(Preference.class); in updateState_TotalSilence()
108 final Preference mockPref = mock(Preference.class); in updateState_AlarmsOnly()
118 final Preference mockPref = mock(Preference.class); in updateState_Priority()
128 final Preference mockPref = mock(Preference.class); in updateState_ZenOff()
137 final Preference mockPref = mock(Preference.class); in updateState_otherUserChangedZen()
/packages/apps/Settings/src/com/android/settings/wifi/
DWifiAPITest.java29 import androidx.preference.Preference;
40 Preference.OnPreferenceClickListener {
53 private Preference mWifiDisconnect;
54 private Preference mWifiDisableNetwork;
55 private Preference mWifiEnableNetwork;
77 mWifiDisconnect = (Preference) preferenceScreen.findPreference(KEY_DISCONNECT); in onCreatePreferences()
80 mWifiDisableNetwork = (Preference) preferenceScreen.findPreference(KEY_DISABLE_NETWORK); in onCreatePreferences()
83 mWifiEnableNetwork = (Preference) preferenceScreen.findPreference(KEY_ENABLE_NETWORK); in onCreatePreferences()
98 public boolean onPreferenceTreeClick(Preference preference) { in onPreferenceTreeClick()
106 public boolean onPreferenceClick(Preference pref) { in onPreferenceClick()
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/settings/
DAccountsSettingsFragment.java31 import android.preference.Preference;
32 import android.preference.Preference.OnPreferenceClickListener;
69 private final Preference.OnPreferenceClickListener mSyncNowListener =
74 private final Preference.OnPreferenceClickListener mDeleteSyncDataListener =
80 private final Preference.OnPreferenceClickListener mEnableSyncClickListener =
91 private Preference mSyncNowPreference;
96 private Preference mClearSyncDataPreference;
101 private Preference mAccountSwitcher;
124 final Preference enableMetricsLogging = in onCreate()
192 public boolean onPreferenceClick(final Preference preference) { in enableSyncPreferences()
[all …]
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/wifi/
DWifiAPITest.java29 import androidx.preference.Preference;
40 Preference.OnPreferenceClickListener {
53 private Preference mWifiDisconnect;
54 private Preference mWifiDisableNetwork;
55 private Preference mWifiEnableNetwork;
77 mWifiDisconnect = (Preference) preferenceScreen.findPreference(KEY_DISCONNECT); in onCreatePreferences()
80 mWifiDisableNetwork = (Preference) preferenceScreen.findPreference(KEY_DISABLE_NETWORK); in onCreatePreferences()
83 mWifiEnableNetwork = (Preference) preferenceScreen.findPreference(KEY_ENABLE_NETWORK); in onCreatePreferences()
98 public boolean onPreferenceTreeClick(Preference preference) { in onPreferenceTreeClick()
106 public boolean onPreferenceClick(Preference pref) { in onPreferenceClick()
/packages/apps/PermissionController/src/com/android/permissioncontroller/permission/ui/television/
DAllAppPermissionsFragment.java39 import androidx.preference.Preference;
40 import androidx.preference.Preference.OnPreferenceChangeListener;
41 import androidx.preference.Preference.OnPreferenceClickListener;
131 ArrayList<Preference> prefs = new ArrayList<>(); // Used for sorting. in updateUi()
187 Collections.sort(prefs, new Comparator<Preference>() { in updateUi()
189 public int compare(Preference lhs, Preference rhs) { in updateUi()
217 ArrayList<Preference> prefs) { in findOrCreate()
230 private Preference getPreference(final PermissionInfo perm, final PermissionGroupInfo group) { in getPreference()
238 private Preference getMutablePreference(final PermissionInfo perm, PermissionGroupInfo group) { in getMutablePreference()
252 public boolean onPreferenceChange(Preference preference, Object value) { in getMutablePreference()
[all …]
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/notification/
DZenCustomRuleConfigSettings.java25 import androidx.preference.Preference;
45 private Preference mCallsPreference;
46 private Preference mMessagesPreference;
47 private Preference mNotificationsPreference;
57 new Preference.OnPreferenceClickListener() { in onCreate()
59 public boolean onPreferenceClick(Preference preference) { in onCreate()
71 new Preference.OnPreferenceClickListener() { in onCreate()
73 public boolean onPreferenceClick(Preference preference) { in onCreate()
85 new Preference.OnPreferenceClickListener() { in onCreate()
87 public boolean onPreferenceClick(Preference preference) { in onCreate()
/packages/apps/Settings/src/com/android/settings/notification/zen/
DZenCustomRuleConfigSettings.java25 import androidx.preference.Preference;
45 private Preference mCallsPreference;
46 private Preference mMessagesPreference;
47 private Preference mNotificationsPreference;
57 new Preference.OnPreferenceClickListener() { in onCreate()
59 public boolean onPreferenceClick(Preference preference) { in onCreate()
71 new Preference.OnPreferenceClickListener() { in onCreate()
73 public boolean onPreferenceClick(Preference preference) { in onCreate()
85 new Preference.OnPreferenceClickListener() { in onCreate()
87 public boolean onPreferenceClick(Preference preference) { in onCreate()
/packages/apps/Settings/tests/robotests/src/com/android/settings/applications/specialaccess/
DMoreSpecialAccessPreferenceControllerTest.java33 import androidx.preference.Preference;
118 Preference preference = mock(Preference.class); in handlePreferenceTreeClick_differentKey_shouldReturnFalse()
130 Preference preference = mock(Preference.class); in handlePreferenceTreeClick_sameKey_shouldReturnTrue()
141 Preference preference = mock(Preference.class); in handlePreferenceTreeClick_noPermissionController_shouldNotStartActivity()
154 Preference preference = mock(Preference.class); in handlePreferenceTreeClick_canNotResolveActivity_shouldNotStartActivity()
169 Preference preference = mock(Preference.class); in handlePreferenceTreeClick_canResolveActivity_shouldStartActivityWithIntent()

12345678910>>...70