Home
last modified time | relevance | path

Searched refs:application (Results 1 – 25 of 1248) sorted by relevance

12345678910>>...50

/packages/apps/Car/libs/car-media-common/src/com/android/car/media/common/source/
DMediaSourceViewModel.java73 MediaBrowserConnector createMediaBrowserConnector(@NonNull Application application, in createMediaBrowserConnector() argument
86 public static MediaSourceViewModel get(@NonNull Application application) { in get() argument
88 sInstance = new MediaSourceViewModel(application); in get()
98 private MediaSourceViewModel(@NonNull Application application) { in MediaSourceViewModel() argument
99 this(application, new InputFactory() { in MediaSourceViewModel()
102 @NonNull Application application, in MediaSourceViewModel()
104 return new MediaBrowserConnector(application, connectedBrowserCallback); in MediaSourceViewModel()
112 return new MediaControllerCompat(application, token); in MediaSourceViewModel()
121 return Car.createCar(application); in MediaSourceViewModel()
131 return packageName == null ? null : new MediaSource(application, packageName); in MediaSourceViewModel()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/biometrics/fingerprint/
DSetupFingerprintEnrollFinishTest.java23 import static org.robolectric.RuntimeEnvironment.application;
58 Shadows.shadowOf(application.getPackageManager()) in setUp()
61 mFingerprintManager = (FingerprintManager) application.getSystemService( in setUp()
66 application, FINGERPRINT_SUGGESTION_ACTIVITY); in setUp()
72 application, in clickAddAnother_shouldLaunchEnrolling()
87 application, in clickAddAnother_shouldPropagateResults()
112 assertThat(application.getPackageManager().getComponentEnabledSetting( in onActivityResult_fingerprintCountIsNotOne_fingerprintSuggestionActivityDisabled()
122 assertThat(application.getPackageManager().getComponentEnabledSetting( in onActivityResult_fingerprintCountIsOne_fingerprintSuggestionActivityEnabled()
132 assertThat(application.getPackageManager().getComponentEnabledSetting( in clickNext_fingerprintCountIsNotOne_fingerprintSuggestionActivityDisabled()
142 assertThat(application.getPackageManager().getComponentEnabledSetting( in clickNext_fingerprintCountIsOne_fngerprintSuggestionActivityEnabled()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/dashboard/
DDashboardFeatureProviderImplTest.java105 mContext = spy(RuntimeEnvironment.application); in setUp()
106 doReturn(RuntimeEnvironment.application).when(mActivity).getApplicationContext(); in setUp()
129 final Preference preference = new Preference(RuntimeEnvironment.application); in bindPreference_shouldBindAllData()
149 final Preference preference = new Preference(RuntimeEnvironment.application); in bindPreference_noFragmentMetadata_shouldBindIntent()
163 final Preference preference = new Preference(RuntimeEnvironment.application); in bindPreference_noFragmentMetadata_shouldBindToProfileSelector()
178 final Preference preference = new Preference(RuntimeEnvironment.application); in bindPreference_noFragmentMetadataSingleUser_shouldBindToDirectLaunchIntent()
200 final Preference preference = new Preference(RuntimeEnvironment.application); in bindPreference_toInternalSettingActivity_shouldBindToDirectLaunchIntentAndNotLog()
201 mActivityInfo.packageName = RuntimeEnvironment.application.getPackageName(); in bindPreference_toInternalSettingActivity_shouldBindToDirectLaunchIntentAndNotLog()
228 final Preference preference = new Preference(RuntimeEnvironment.application); in bindPreference_withNullKeyNullPriority_shouldGenerateKeyAndPriority()
239 final Preference preference = new Preference(RuntimeEnvironment.application); in bindPreference_noSummary_shouldSetSummaryToPlaceholder()
[all …]
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/accounts/
DAccountSyncPreferenceControllerTest.java23 import static org.robolectric.RuntimeEnvironment.application;
67 new PreferenceControllerTestHelper<>(application, in setUp()
75 mPreference = new Preference(application); in setUp()
100 .isEqualTo(application.getString(R.string.account_sync_summary_all_off)); in refreshUi_notSameAccountType_shouldNotCount()
118 .isEqualTo(application.getString(R.string.account_sync_summary_all_off)); in refreshUi_adapterInvisible_shouldNotCount()
134 .isEqualTo(application.getString(R.string.account_sync_summary_all_off)); in refreshUi_notSyncable_shouldNotCount()
153 .isEqualTo(application.getString(R.string.account_sync_summary_all_off)); in refreshUi_masterAutomaticSyncIgnoredAndAccountSyncDisabled_shouldNotCount()
170 .isEqualTo(application.getString(R.string.account_sync_summary_all_on)); in refreshUi_masterAutomaticSyncUsed_shouldCount()
188 .isEqualTo(application.getString(R.string.account_sync_summary_all_on)); in refreshUi_automaticSyncEnabled_shouldCount()
224 .isEqualTo(application.getString(R.string.account_sync_summary_some_on, 3, 4)); in refreshUi_someEnabled_shouldSetSummary()
DAccountDetailsPreferenceControllerTest.java21 import static org.robolectric.RuntimeEnvironment.application;
63 new PreferenceControllerTestHelper<>(application, in setUp()
69 mPreference = new Preference(application); in setUp()
81 mController = new PreferenceControllerTestHelper<>(application, in checkInitialized_accountSetAndUserHandleSet_doesNothing()
91 mController = new PreferenceControllerTestHelper<>(application, in checkInitialized_nullAccount_throwsIllegalStateException()
100 mController = new PreferenceControllerTestHelper<>(application, in checkInitialized_nullUserHandle_throwsIllegalStateException()
135 return Shadow.extract(AccountManager.get(application)); in getShadowAccountManager()
/packages/apps/Gallery2/src/com/android/gallery3d/data/
DLocalAlbum.java61 public LocalAlbum(Path path, GalleryApp application, int bucketId, in LocalAlbum() argument
64 mApplication = application; in LocalAlbum()
65 mResolver = application.getContentResolver(); in LocalAlbum()
86 mNotifier = new ChangeNotifier(this, mBaseUri, application); in LocalAlbum()
89 public LocalAlbum(Path path, GalleryApp application, int bucketId, in LocalAlbum() argument
91 this(path, application, bucketId, isImage, in LocalAlbum()
93 application.getContentResolver(), bucketId)); in LocalAlbum()
163 GalleryApp application, boolean isImage, ArrayList<Integer> ids) { in getMediaItemById() argument
184 ContentResolver resolver = application.getContentResolver(); in getMediaItemById()
185 DataManager dataManager = application.getDataManager(); in getMediaItemById()
[all …]
/packages/apps/Car/Launcher/src/com/android/car/carlauncher/
DContextualViewModel.java54 public ContextualViewModel(Application application) { in ContextualViewModel() argument
55 this(application, getCarProjectionManager(application)); in ContextualViewModel()
64 ContextualViewModel(Application application, CarProjectionManager carProjectionManager) { in ContextualViewModel() argument
65 super(application); in ContextualViewModel()
70 new ProjectionContextualInfoLiveData(application, carProjectionManager), in ContextualViewModel()
71 new WeatherContextualInfoLiveData(application) in ContextualViewModel()
/packages/apps/Settings/tests/robotests/src/com/android/settings/widget/
DValidatedEditTextPreferenceTest.java60 new View(RuntimeEnvironment.application))); in setUp()
61 mPreference = new ValidatedEditTextPreference(RuntimeEnvironment.application); in setUp()
74 final EditText editText = spy(new EditText(RuntimeEnvironment.application)); in bindDialogView_emptyEditText_shouldNotSetSelection()
87 final EditText editText = spy(new EditText(RuntimeEnvironment.application)); in bindDialogView_nonemptyEditText_shouldSetSelection()
99 final EditText editText = spy(new EditText(RuntimeEnvironment.application)); in bindDialogView_hasValidator_shouldBindToEditText()
110 final EditText editText = spy(new EditText(RuntimeEnvironment.application)); in bindDialogView_isPassword_shouldSetInputType()
124 final TextView textView = spy(new TextView(RuntimeEnvironment.application)); in bindViewHolder_isPassword_shouldSetInputType()
137 final TextView textView = spy(new TextView(RuntimeEnvironment.application)); in bindViewHolder_isNotPassword_shouldNotAutoCorrectText()
/packages/apps/Settings/tests/robotests/src/com/android/settings/fuelgauge/batterytip/
DAnomalyConfigJobServiceTest.java31 import static org.robolectric.RuntimeEnvironment.application;
68 mContext = spy(RuntimeEnvironment.application); in setUp()
73 doReturn(application.getSharedPreferences(AnomalyConfigJobService.PREF_DB, in setUp()
76 doReturn(application.getContentResolver()).when(mJobService).getContentResolver(); in setUp()
105 Settings.Global.putInt(application.getContentResolver(), in checkAnomalyConfig_newConfigExist_removeOldConfig()
107 Settings.Global.putString(application.getContentResolver(), Settings.Global.ANOMALY_CONFIG, in checkAnomalyConfig_newConfigExist_removeOldConfig()
118 Settings.Global.putInt(application.getContentResolver(), in checkAnomalyConfig_newConfigExist_uploadNewConfig()
120 Settings.Global.putString(application.getContentResolver(), Settings.Global.ANOMALY_CONFIG, in checkAnomalyConfig_newConfigExist_uploadNewConfig()
/packages/apps/PermissionController/src/com/android/packageinstaller/role/ui/
DSpecialAppAccessViewModel.java57 public SpecialAppAccessViewModel(@NonNull Role role, @NonNull Application application) { in SpecialAppAccessViewModel() argument
58 super(application); in SpecialAppAccessViewModel()
63 RoleLiveData roleLiveData = new RoleLiveData(role, user, application); in SpecialAppAccessViewModel()
64 UserHandle workProfile = UserUtils.getWorkProfile(application); in SpecialAppAccessViewModel()
65 RoleSortFunction sortFunction = new RoleSortFunction(application); in SpecialAppAccessViewModel()
69 RoleLiveData workRoleLiveData = new RoleLiveData(role, workProfile, application); in SpecialAppAccessViewModel()
169 public Factory(@NonNull Role role, @NonNull Application application) { in Factory() argument
171 mApplication = application; in Factory()
DSpecialAppAccessListViewModel.java41 public SpecialAppAccessListViewModel(@NonNull Application application) { in SpecialAppAccessListViewModel() argument
42 super(application); in SpecialAppAccessListViewModel()
45 RoleListLiveData liveData = new RoleListLiveData(false, user, application); in SpecialAppAccessListViewModel()
46 UserHandle workProfile = UserUtils.getWorkProfile(application); in SpecialAppAccessListViewModel()
47 RoleListSortFunction sortFunction = new RoleListSortFunction(application); in SpecialAppAccessListViewModel()
51 RoleListLiveData workLiveData = new RoleListLiveData(false, workProfile, application); in SpecialAppAccessListViewModel()
DDefaultAppListViewModel.java48 public DefaultAppListViewModel(@NonNull Application application) { in DefaultAppListViewModel() argument
49 super(application); in DefaultAppListViewModel()
52 RoleListSortFunction sortFunction = new RoleListSortFunction(application); in DefaultAppListViewModel()
53 mLiveData = Transformations.map(new RoleListLiveData(true, mUser, application), in DefaultAppListViewModel()
55 mWorkProfile = UserUtils.getWorkProfile(application); in DefaultAppListViewModel()
57 mWorkProfile, application), sortFunction) : null; in DefaultAppListViewModel()
DDefaultAppViewModel.java57 @NonNull Application application) { in DefaultAppViewModel() argument
58 super(application); in DefaultAppViewModel()
63 mRoleLiveData = Transformations.map(new RoleLiveData(mRole, mUser, application), in DefaultAppViewModel()
64 new RoleSortFunction(application)); in DefaultAppViewModel()
119 @NonNull Application application) { in Factory() argument
122 mApplication = application; in Factory()
/packages/apps/Settings/tests/robotests/src/com/android/settings/password/
DSetupChooseLockPatternTest.java21 import static org.robolectric.RuntimeEnvironment.application;
68 application.getPackageManager().setComponentEnabledSetting( in setUp()
69 new ComponentName(application, SetupRedactionInterstitial.class), in setUp()
75 application, in setUp()
76 new IntentBuilder(application) in setUp()
86 ShadowPackageManager spm = Shadows.shadowOf(application.getPackageManager()); in chooseLockSaved_shouldEnableRedactionInterstitial()
87 ComponentName cname = new ComponentName(application, SetupRedactionInterstitial.class); in chooseLockSaved_shouldEnableRedactionInterstitial()
185 .isEqualTo(application.getString(R.string.skip_label)); in createActivity_enterPattern_clearButtonShouldBeShown()
191 .isEqualTo(application.getString(R.string.lockpattern_retry_button_text)); in createActivity_enterPattern_clearButtonShouldBeShown()
DSetupChooseLockPasswordTest.java21 import static org.robolectric.RuntimeEnvironment.application;
86 application, in createActivity_shouldNotCrash()
87 new IntentBuilder(application).build()); in createActivity_shouldNotCrash()
124 Intent intent = new IntentBuilder(application).build(); in createActivity_clickDifferentOption_extrasShouldBePropagated()
126 intent = SetupChooseLockPassword.modifyIntentForSetup(application, intent); in createActivity_clickDifferentOption_extrasShouldBePropagated()
183 .isEqualTo(application.getString(R.string.lockpassword_clear_label)); in createActivity_inputPasswordInConfirmStage_clearButtonShouldBeShown()
189 application, in createSetupChooseLockPassword()
190 new IntentBuilder(application).build()); in createSetupChooseLockPassword()
DSetNewPasswordActivityTest.java80 mProvisioned = Settings.Global.getInt(RuntimeEnvironment.application.getContentResolver(), in setUp()
86 Settings.Global.putInt(RuntimeEnvironment.application.getContentResolver(), in tearDown()
93 Settings.Global.putInt(RuntimeEnvironment.application.getContentResolver(), in testChooseLockGeneric()
107 Settings.Global.putInt(RuntimeEnvironment.application.getContentResolver(), in testSetupChooseLockGeneric()
124 Settings.Global.putInt(RuntimeEnvironment.application.getContentResolver(), in testLaunchChooseLock_setNewPasswordExtraWithoutPermission()
148 Settings.Global.putInt(RuntimeEnvironment.application.getContentResolver(), in testLaunchChooseLock_setNewPasswordExtraWithPermission()
178 Settings.Global.putInt(RuntimeEnvironment.application.getContentResolver(), in testLaunchChooseLock_setNewPasswordExtraInvalidValue()
206 Settings.Global.putInt(RuntimeEnvironment.application.getContentResolver(), in testLaunchChooseLock_setNewPasswordExtraNoneComplexity()
234 Settings.Global.putInt(RuntimeEnvironment.application.getContentResolver(), in testLaunchChooseLock_setNewPasswordWithoutExtra()
261 Settings.Global.putInt(RuntimeEnvironment.application.getContentResolver(), in testLaunchChooseLock_setNewParentProfilePasswordExtraWithPermission()
[all …]
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/common/
DPreferenceUtilTest.java39 Preference preference = new SwitchPreference(RuntimeEnvironment.application); in testCheckPreferenceType_true()
45 Preference preference = new SwitchPreference(RuntimeEnvironment.application); in testCheckPreferenceType_superclass_true()
52 Preference preference = new ListPreference(RuntimeEnvironment.application); in testCheckPreferenceType_false()
60 Preference preference = new SwitchPreference(RuntimeEnvironment.application); in testRequirePreferenceType_true()
67 Preference preference = new SwitchPreference(RuntimeEnvironment.application); in testRequirePreferenceType_superclass_true()
73 Preference preference = new ListPreference(RuntimeEnvironment.application); in testRequirePreferenceType_false()
/packages/apps/Dialer/java/com/android/dialer/strictmode/
DStrictModeUtils.java103 public static void warmupSharedPrefs(Application application) { in warmupSharedPrefs() argument
107 if (UserManagerCompat.isUserUnlocked(application)) { in warmupSharedPrefs()
109 PreferenceManager.getDefaultSharedPreferences(application); in warmupSharedPrefs()
112 application.getSharedPreferences(application.getPackageName(), Context.MODE_PRIVATE); in warmupSharedPrefs()
119 StorageComponent.get(application).unencryptedSharedPrefs(); in warmupSharedPrefs()
/packages/apps/Settings/tests/robotests/src/com/android/settings/notification/
DDndPreferenceControllerTest.java77 mContext = RuntimeEnvironment.application; in setUp()
106 Preference pref = new RestrictedSwitchPreference(RuntimeEnvironment.application); in testUpdateState_disabledByAdmin()
119 Preference pref = new RestrictedSwitchPreference(RuntimeEnvironment.application); in testUpdateState_notBlockable()
132 Preference pref = new RestrictedSwitchPreference(RuntimeEnvironment.application); in testUpdateState_configurable()
145 new RestrictedSwitchPreference(RuntimeEnvironment.application); in testUpdateState_bypassDnd()
157 new RestrictedSwitchPreference(RuntimeEnvironment.application); in testUpdateState_noBypassDnd()
169 new RestrictedSwitchPreference(RuntimeEnvironment.application); in testOnPreferenceChange_on()
187 new RestrictedSwitchPreference(RuntimeEnvironment.application); in testOnPreferenceChange_off()
DVibrationPreferenceControllerTest.java81 mContext = RuntimeEnvironment.application; in setUp()
136 Preference pref = new RestrictedSwitchPreference(RuntimeEnvironment.application); in testUpdateState_disabledByAdmin()
149 Preference pref = new RestrictedSwitchPreference(RuntimeEnvironment.application); in testUpdateState_notBlockable()
162 Preference pref = new RestrictedSwitchPreference(RuntimeEnvironment.application); in testUpdateState_configurable()
175 new RestrictedSwitchPreference(RuntimeEnvironment.application); in testUpdateState_vibrateOn()
187 new RestrictedSwitchPreference(RuntimeEnvironment.application); in testUpdateState_vibrateOff()
199 new RestrictedSwitchPreference(RuntimeEnvironment.application); in testOnPreferenceChange_on()
215 new RestrictedSwitchPreference(RuntimeEnvironment.application); in testOnPreferenceChange_off()
/packages/apps/Settings/tests/robotests/src/com/android/settings/wallpaper/
DWallpaperSuggestionActivityTest.java55 final Application application = RuntimeEnvironment.application; in setUp() local
56 WallpaperManager wallpaperManager = WallpaperManager.getInstance(application); in setUp()
57 ShadowApplication shadowApplication = Shadows.shadowOf(application); in setUp()
80 assertThat(WallpaperSuggestionActivity.isSuggestionComplete(RuntimeEnvironment.application)) in hasWallpaperSet_no_shouldReturnFalse()
89 assertThat(WallpaperSuggestionActivity.isSuggestionComplete(RuntimeEnvironment.application)) in hasWallpaperSet_yes_shouldReturnTrue()
/packages/apps/PermissionController/src/com/android/packageinstaller/permission/ui/handheld/
DAdjustUserSensitiveFragment.java260 UserSensitiveOverrideViewModel(@NonNull Application application) { in UserSensitiveOverrideViewModel() argument
261 super(application); in UserSensitiveOverrideViewModel()
263 mPrefs = getParentUserContext(application).getSharedPreferences(PREFERENCES_FILE, in UserSensitiveOverrideViewModel()
266 mNonSensitivePackages = NonSensitivePackagesLiveData.get(application); in UserSensitiveOverrideViewModel()
268 ALLOW_OVERRIDE_USER_SENSITIVE_KEY, application); in UserSensitiveOverrideViewModel()
269 mForcedUserSensitiveUids = ForcedUserSensitiveUidsLiveData.get(application); in UserSensitiveOverrideViewModel()
271 ASSISTANT_RECORD_AUDIO_IS_USER_SENSITIVE_KEY, application); in UserSensitiveOverrideViewModel()
412 Factory(@NonNull Application application) { in Factory() argument
413 mApplication = application; in Factory()
/packages/apps/KeyChain/robotests/src/com/android/keychain/internal/
DGrantsDatabaseTest.java72 mGrantsDB = new GrantsDatabase(RuntimeEnvironment.application, mKeysProvider);
265 Context context = RuntimeEnvironment.application;
277 … RuntimeEnvironment.application, createExistingKeysProvider(aliases, EXISTING_ALIAS));
288 Context context = RuntimeEnvironment.application;
305 RuntimeEnvironment.application,
319 Context context = RuntimeEnvironment.application;
344 RuntimeEnvironment.application,
360 Context context = RuntimeEnvironment.application;
366 RuntimeEnvironment.application,
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/bluetooth/
DBluetoothPreferenceControllerTest.java80 Context context = RuntimeEnvironment.application; in setUp()
99 Shadows.shadowOf(RuntimeEnvironment.application.getPackageManager()).setSystemFeature( in getAvailabilityStatus_bluetoothNotAvailable_unsupportedOnDevice()
107 Shadows.shadowOf(RuntimeEnvironment.application.getPackageManager()).setSystemFeature( in getAvailabilityStatus_disallowBluetoothUserRestriction_disabledForUser()
117 Shadows.shadowOf(RuntimeEnvironment.application.getPackageManager()).setSystemFeature( in getAvailabilityStatus_adapterDisabled_conditionallyUnavailable()
127 Shadows.shadowOf(RuntimeEnvironment.application.getPackageManager()).setSystemFeature( in getAvailabilityStatus_available()
138 Shadows.shadowOf(RuntimeEnvironment.application.getPackageManager()).setSystemFeature( in onStart_registersEventListener()
149 Shadows.shadowOf(RuntimeEnvironment.application.getPackageManager()).setSystemFeature( in onStop_unregistersEventListener()
/packages/apps/EmergencyInfo/tests/robolectric/src/com/android/emergency/preferences/
DEmergencyListPreferenceTest.java57 Context context = RuntimeEnvironment.application; in setUp()
60 new EmergencyListPreference(RuntimeEnvironment.application, null /* attrs */)); in setUp()
70 RuntimeEnvironment.application.getResources().getStringArray( in testReloadFromPreference()
87 RuntimeEnvironment.application.getResources().getStringArray( in testSetValue()
90 RuntimeEnvironment.application.getResources().getStringArray( in testSetValue()
107 RuntimeEnvironment.application.getResources().getString( in testSetValue()

12345678910>>...50