Home
last modified time | relevance | path

Searched refs:getSharedPreferences (Results 1 – 25 of 112) sorted by relevance

12345

/aosp14/frameworks/base/packages/SettingsLib/src/com/android/settingslib/media/
H A DConnectionRecordManager.java45 private SharedPreferences getSharedPreferences(Context context) { in getSharedPreferences() method in ConnectionRecordManager
46 return context.getSharedPreferences(SHARED_PREFERENCES_NAME, Context.MODE_PRIVATE); in getSharedPreferences()
56 return getSharedPreferences(context).getInt(id, 0); in fetchConnectionRecord()
63 mLastSelectedDevice = getSharedPreferences(context).getString(KEY_LAST_SELECTED_DEVICE, in fetchLastSelectedDevice()
74 final SharedPreferences.Editor editor = getSharedPreferences(context).edit(); in setConnectionRecord()
/aosp14/frameworks/base/packages/SystemUI/shared/src/com/android/systemui/shared/plugins/
H A DPluginPrefs.java40 mSharedPrefs = context.getSharedPreferences(PREFS, 0); in PluginPrefs()
55 return context.getSharedPreferences(PREFS, 0).getBoolean(HAS_PLUGINS, false); in hasPlugins()
59 context.getSharedPreferences(PREFS, 0).edit().putBoolean(HAS_PLUGINS, true).apply(); in setHasPlugins()
/aosp14/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/people/
H A DSharedPreferencesHelperTest.java50 SharedPreferences widgetSp = mContext.getSharedPreferences( in setStorageForTile()
64 SharedPreferences sp = mContext.getSharedPreferences( in testGetPeopleTileKey()
76 SharedPreferences sp = mContext.getSharedPreferences( in testSetPeopleTileKey()
90 SharedPreferences sp = mContext.getSharedPreferences( in testClear()
H A DPeopleBackupFollowUpJobTest.java87 private final SharedPreferences mFollowUpSp = mContext.getSharedPreferences(
90 private final SharedPreferences mWidgetIdSp = mContext.getSharedPreferences(
92 private final SharedPreferences mSecondWidgetIdSp = mContext.getSharedPreferences(
/aosp14/frameworks/base/packages/Shell/src/com/android/shell/
H A DBugreportPrefs.java37 final SharedPreferences prefs = context.getSharedPreferences( in getWarningState()
43 final SharedPreferences prefs = context.getSharedPreferences( in setWarningState()
/aosp14/frameworks/base/samples/training/network-usage/src/com/example/android/networkusage/
H A DSettingsActivity.java45 getPreferenceScreen().getSharedPreferences().registerOnSharedPreferenceChangeListener(this); in onResume()
56 .getSharedPreferences().unregisterOnSharedPreferenceChangeListener(this); in onPause()
/aosp14/frameworks/base/apct-tests/perftests/core/src/android/os/
H A DSharedPreferencesTest.java43 SharedPreferences prefs = context.getSharedPreferences("test", Context.MODE_PRIVATE); in timeCachedGetSharedPreferences()
45 prefs = context.getSharedPreferences("test", Context.MODE_PRIVATE); in timeCachedGetSharedPreferences()
/aosp14/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/settings/
H A DUserFileManagerImplTest.kt76 val primarySharedPref = userFileManager.getSharedPreferences(TEST_FILE_NAME, 0, 0)
77 val secondarySharedPref = userFileManager.getSharedPreferences(TEST_FILE_NAME, 0, 11)
130 val tmpPrefs = context.getSharedPreferences("tmp", Context.MODE_PRIVATE)
139 val prefs = userFileManager.getSharedPreferences(fileName, Context.MODE_PRIVATE, userId)
/aosp14/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/pipeline/data/repository/
H A DCustomTileAddedRepository.kt50 .getSharedPreferences(TILES, 0, userId)
56 .getSharedPreferences(TILES, 0, userId)
/aosp14/frameworks/base/packages/SystemUI/docs/
H A Duser-file-manager.md19 ### fun getSharedPreferences(fileName: String, mode: Int, userId: Int): SharedPreferences
23 …](https://developer.android.com/reference/android/content/Context#getSharedPreferences(java.lang.S…
26 i.e. `fileManager.getSharedPreferences("prefs.xml", userTracker.userId, 0)`
/aosp14/frameworks/base/packages/WallpaperBackup/test/src/com/android/wallpaperbackup/utils/
H A DContextWithServiceOverrides.java59 public SharedPreferences getSharedPreferences(String name, int mode) { in getSharedPreferences() method in ContextWithServiceOverrides
61 ? super.getSharedPreferences(name, mode) in getSharedPreferences()
/aosp14/frameworks/base/core/java/android/preference/
H A DPreferenceManager.java510 public SharedPreferences getSharedPreferences() { in getSharedPreferences() method in PreferenceManager
529 mSharedPreferences = storageContext.getSharedPreferences(mSharedPreferencesName, in getSharedPreferences()
545 return context.getSharedPreferences(getDefaultSharedPreferencesName(context), in getDefaultSharedPreferences()
663 final SharedPreferences defaultValueSp = context.getSharedPreferences( in setDefaultValues()
702 mEditor = getSharedPreferences().edit(); in getEditor()
707 return getSharedPreferences().edit(); in getEditor()
H A DPreference.java1228 public SharedPreferences getSharedPreferences() { in getSharedPreferences() method in Preference
1233 return mPreferenceManager.getSharedPreferences(); in getSharedPreferences()
1586 if (!shouldPersist || !getSharedPreferences().contains(mKey)) { in dispatchSetInitialValue()
1681 return mPreferenceManager.getSharedPreferences().getString(mKey, defaultReturnValue); in getPersistedString()
1734 return mPreferenceManager.getSharedPreferences().getStringSet(mKey, defaultReturnValue); in getPersistedStringSet()
1788 return mPreferenceManager.getSharedPreferences().getInt(mKey, defaultReturnValue); in getPersistedInt()
1842 return mPreferenceManager.getSharedPreferences().getFloat(mKey, defaultReturnValue); in getPersistedFloat()
1896 return mPreferenceManager.getSharedPreferences().getLong(mKey, defaultReturnValue); in getPersistedLong()
1950 return mPreferenceManager.getSharedPreferences().getBoolean(mKey, defaultReturnValue); in getPersistedBoolean()
/aosp14/frameworks/base/packages/StatementService/src/com/android/statementservice/domain/worker/
H A DSingleV1RequestWorker.kt76 val sp = deContext?.getSharedPreferences(packageName, Context.MODE_PRIVATE)
82 val sp = deContext?.getSharedPreferences(packageName, Context.MODE_PRIVATE)
H A DCollectV1Worker.kt57 val sp = deContext?.getSharedPreferences(packageName, Context.MODE_PRIVATE)
74 val sp = deContext?.getSharedPreferences(packageName, Context.MODE_PRIVATE)
/aosp14/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/controls/panels/
H A DSelectedComponentRepositoryTest.kt69 whenever(userFileManager.getSharedPreferences(any(), any(), any()))
120 userFileManager.getSharedPreferences(
/aosp14/frameworks/base/packages/SystemUI/src/com/android/systemui/settings/
H A DUserFileManager.kt34 fun getSharedPreferences( regex
H A DUserFileManagerImpl.kt124 override fun getSharedPreferences(
134 return context.getSharedPreferences(file.path, mode)
/aosp14/frameworks/base/services/net/java/android/net/
H A DConnectivityModuleConnector.java309 final SharedPreferences prefs = getSharedPreferences(); in maybeCrashWithTerribleFailure()
352 private SharedPreferences getSharedPreferences() {
357 .getSharedPreferences(prefsFile, Context.MODE_PRIVATE);
/aosp14/frameworks/base/packages/CredentialManager/src/com/android/credentialmanager/
H A DUserConfigRepo.kt23 val sharedPreferences: SharedPreferences = context.getSharedPreferences(
/aosp14/frameworks/base/packages/SystemUI/src/com/android/systemui/people/widget/
H A DPeopleBackupHelper.java132 SharedPreferences backupSp = mContext.getSharedPreferences( in performBackup()
162 SharedPreferences backupSp = mContext.getSharedPreferences( in restoreEntity()
168 SharedPreferences followUp = mContext.getSharedPreferences( in restoreEntity()
400 SharedPreferences dest = context.getSharedPreferences(id, Context.MODE_PRIVATE); in restoreWidgetIdFiles()
411 SharedPreferences sp = mContext.getSharedPreferences(idString, Context.MODE_PRIVATE); in getExistingWidgetsForUser()
/aosp14/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/people/widget/
H A DPeopleSpaceWidgetManagerTest.java992 SharedPreferences widgetSp = mContext.getSharedPreferences( in testAddThenReconfigureWidgetsUpdatesStorageCacheAndListeners()
1043 SharedPreferences widgetSp = mContext.getSharedPreferences( in testDeleteAllWidgetsForConversationsUncachesShortcutAndRemovesListeners()
1107 SharedPreferences widgetSp = mContext.getSharedPreferences( in testOnAppWidgetOptionsChangedNoWidgetAdded()
1462 SharedPreferences sp1 = mContext.getSharedPreferences( in testRemapWidgetFiles()
1468 SharedPreferences sp4 = mContext.getSharedPreferences( in testRemapWidgetFiles()
1474 SharedPreferences sp8 = mContext.getSharedPreferences( in testRemapWidgetFiles()
1480 SharedPreferences sp11 = mContext.getSharedPreferences( in testRemapWidgetFiles()
1495 SharedPreferences sp1 = mContext.getSharedPreferences( in testRemapWidgetFiles_crossMapping()
1501 SharedPreferences sp2 = mContext.getSharedPreferences( in testRemapWidgetFiles_crossMapping()
1507 SharedPreferences sp4 = mContext.getSharedPreferences( in testRemapWidgetFiles_crossMapping()
[all …]
/aosp14/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/keyguard/data/quickaffordance/
H A DMuteQuickAffordanceConfigTest.kt74 whenever(userFileManager.getSharedPreferences(any(), any(), any()))
75 … .thenReturn(context.getSharedPreferences("mutequickaffordancetest", Context.MODE_PRIVATE))
/aosp14/frameworks/base/libs/WindowManager/Shell/src/com/android/wm/shell/compatui/
H A DCompatUIConfiguration.java117 mCompatUISharedPreferences = context.getSharedPreferences(getCompatUISharedPreferenceName(), in CompatUIConfiguration()
119 mLetterboxEduSharedPreferences = context.getSharedPreferences( in CompatUIConfiguration()
/aosp14/frameworks/base/test-mock/api/
H A Dremoved.txt5 method public android.content.SharedPreferences getSharedPreferences(java.io.File, int);

12345