Home
last modified time | relevance | path

Searched refs:prefs (Results 1 – 25 of 205) sorted by relevance

123456789

/packages/apps/DeskClock/src/com/android/deskclock/data/
DSettingsDAO.kt62 fun getGlobalIntentId(prefs: SharedPreferences): Int { in getGlobalIntentId()
63 return prefs.getInt(KEY_ALARM_GLOBAL_ID, -1) in getGlobalIntentId()
69 fun updateGlobalIntentId(prefs: SharedPreferences) { in updateGlobalIntentId()
70 val globalId: Int = prefs.getInt(KEY_ALARM_GLOBAL_ID, -1) + 1 in updateGlobalIntentId()
71 prefs.edit().putInt(KEY_ALARM_GLOBAL_ID, globalId).apply() in updateGlobalIntentId()
77 fun getCitySort(prefs: SharedPreferences): CitySort { in getCitySort()
79 val citySortOrdinal: Int = prefs.getInt(KEY_SORT_PREFERENCE, defaultSortOrdinal) in getCitySort()
86 fun toggleCitySort(prefs: SharedPreferences) { in toggleCitySort()
87 val oldSort = getCitySort(prefs) in toggleCitySort()
89 prefs.edit().putInt(KEY_SORT_PREFERENCE, newSort.ordinal).apply() in toggleCitySort()
[all …]
DTimerDAO.kt60 fun getTimers(prefs: SharedPreferences): MutableList<Timer> { in getTimers()
62 val timerIds: Set<String> = prefs.getStringSet(TIMER_IDS, emptySet<String>())!! in getTimers()
68 val stateValue: Int = prefs.getInt(STATE + id, Timer.State.RESET.value) in getTimers()
74 val length: Long = prefs.getLong(LENGTH + id, Long.MIN_VALUE) in getTimers()
75 val totalLength: Long = prefs.getLong(TOTAL_LENGTH + id, Long.MIN_VALUE) in getTimers()
76 val lastStartTime: Long = prefs.getLong(LAST_START_TIME + id, Timer.UNUSED) in getTimers()
77 val lastWallClockTime: Long = prefs.getLong(LAST_WALL_CLOCK_TIME + id, Timer.UNUSED) in getTimers()
78 val remainingTime: Long = prefs.getLong(REMAINING_TIME + id, totalLength) in getTimers()
79 val label: String? = prefs.getString(LABEL + id, null) in getTimers()
80 val deleteAfterUse: Boolean = prefs.getBoolean(DELETE_AFTER_USE + id, false) in getTimers()
[all …]
DStopwatchDAO.kt47 fun getStopwatch(prefs: SharedPreferences): Stopwatch { in getStopwatch()
48 val stateIndex: Int = prefs.getInt(STATE, Stopwatch.State.RESET.ordinal) in getStopwatch()
50 val lastStartTime: Long = prefs.getLong(LAST_START_TIME, Stopwatch.UNUSED) in getStopwatch()
51 val lastWallClockTime: Long = prefs.getLong(LAST_WALL_CLOCK_TIME, Stopwatch.UNUSED) in getStopwatch()
52 val accumulatedTime: Long = prefs.getLong(ACCUMULATED_TIME, 0) in getStopwatch()
58 setStopwatch(prefs, s) in getStopwatch()
66 fun setStopwatch(prefs: SharedPreferences, stopwatch: Stopwatch) { in setStopwatch()
67 val editor: SharedPreferences.Editor = prefs.edit() in setStopwatch()
87 fun getLaps(prefs: SharedPreferences): MutableList<Lap> { in getLaps()
89 val lapCount: Int = prefs.getInt(LAP_COUNT, 0) in getLaps()
[all …]
DCustomRingtoneDAO.kt44 fun addCustomRingtone(prefs: SharedPreferences, uri: Uri, title: String?): CustomRingtone { in addCustomRingtone()
45 val id: Long = prefs.getLong(NEXT_RINGTONE_ID, 0) in addCustomRingtone()
46 val ids = getRingtoneIds(prefs) in addCustomRingtone()
49 prefs.edit() in addCustomRingtone()
62 fun removeCustomRingtone(prefs: SharedPreferences, id: Long) { in removeCustomRingtone()
63 val ids = getRingtoneIds(prefs) in removeCustomRingtone()
66 val editor: SharedPreferences.Editor = prefs.edit() in removeCustomRingtone()
83 fun getCustomRingtones(prefs: SharedPreferences): MutableList<CustomRingtone> { in getCustomRingtones()
84 val ids: Set<String> = prefs.getStringSet(RINGTONE_IDS, emptySet<String>())!! in getCustomRingtones()
89 val uri: Uri = Uri.parse(prefs.getString(RINGTONE_URI + id, null)) in getCustomRingtones()
[all …]
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/settings/
DSettings.java156 public void onSharedPreferenceChanged(final SharedPreferences prefs, final String key) { in onSharedPreferenceChanged() argument
177 final SharedPreferences prefs = mPrefs; in loadSettings() local
181 return new SettingsValues(context, prefs, res, inputAttributes); in loadSettings()
204 public static boolean readKeypressSoundEnabled(final SharedPreferences prefs, in readKeypressSoundEnabled() argument
206 return prefs.getBoolean(PREF_SOUND_ON, in readKeypressSoundEnabled()
210 public static boolean readVibrationEnabled(final SharedPreferences prefs, in readVibrationEnabled() argument
213 return hasVibrator && prefs.getBoolean(PREF_VIBRATE_ON, in readVibrationEnabled()
217 public static boolean readAutoCorrectEnabled(final SharedPreferences prefs, in readAutoCorrectEnabled() argument
219 return prefs.getBoolean(PREF_AUTO_CORRECTION, true); in readAutoCorrectEnabled()
226 public static boolean readBlockPotentiallyOffensive(final SharedPreferences prefs, in readBlockPotentiallyOffensive() argument
[all …]
DSettingsValues.java122 public SettingsValues(final Context context, final SharedPreferences prefs, final Resources res, in SettingsValues() argument
134 mAutoCap = prefs.getBoolean(Settings.PREF_AUTO_CAP, true); in SettingsValues()
135 mVibrateOn = Settings.readVibrationEnabled(prefs, res); in SettingsValues()
136 mSoundOn = Settings.readKeypressSoundEnabled(prefs, res); in SettingsValues()
137 mKeyPreviewPopupOn = Settings.readKeyPreviewPopupEnabled(prefs, res); in SettingsValues()
138 mSlidingKeyInputPreviewEnabled = prefs.getBoolean( in SettingsValues()
140 mShowsVoiceInputKey = needsToShowVoiceInputKey(prefs, res) in SettingsValues()
144 ? prefs.getBoolean(Settings.PREF_INCLUDE_OTHER_IMES_IN_LANGUAGE_SWITCH_LIST, false) in SettingsValues()
147 ? Settings.readShowsLanguageSwitchKey(prefs) : true /* forcibly */; in SettingsValues()
148 mUseContactsDict = prefs.getBoolean(Settings.PREF_KEY_USE_CONTACTS_DICT, true); in SettingsValues()
[all …]
DAdvancedSettingsFragment.java57 final SharedPreferences prefs = getPreferenceManager().getSharedPreferences(); in onCreate() local
59 if (!Settings.isInternal(prefs)) { in onCreate()
88 Settings.readKeyPreviewPopupEnabled(prefs, res)); in onCreate()
100 final SharedPreferences prefs = getPreferenceManager().getSharedPreferences(); in onResume() local
105 public void onSharedPreferenceChanged(final SharedPreferences prefs, final String key) { in onSharedPreferenceChanged() argument
109 Settings.readKeyPreviewPopupEnabled(prefs, res)); in onSharedPreferenceChanged()
118 final SharedPreferences prefs = getSharedPreferences(); in refreshEnablingsOfKeypressSoundAndVibrationSettings() local
121 Settings.readVibrationEnabled(prefs, res)); in refreshEnablingsOfKeypressSoundAndVibrationSettings()
123 Settings.readKeypressSoundEnabled(prefs, res)); in refreshEnablingsOfKeypressSoundAndVibrationSettings()
132 final SharedPreferences prefs = getSharedPreferences(); in setupKeypressVibrationDurationSettings() local
[all …]
DDebugSettingsFragment.java127 public void onSharedPreferenceChanged(final SharedPreferences prefs, final String key) { in onSharedPreferenceChanged() argument
129 mDebugMode.setChecked(prefs.getBoolean(DebugSettings.PREF_DEBUG_MODE, false)); in onSharedPreferenceChanged()
154 final SharedPreferences prefs = getSharedPreferences(); in setupKeyPreviewAnimationScale() local
173 prefs.edit().putFloat(key, getValueFromPercentage(value)).apply(); in setupKeyPreviewAnimationScale()
178 prefs.edit().remove(key).apply(); in setupKeyPreviewAnimationScale()
184 Settings.readKeyPreviewAnimationScale(prefs, key, defaultValue)); in setupKeyPreviewAnimationScale()
206 final SharedPreferences prefs = getSharedPreferences(); in setupKeyPreviewAnimationDuration() local
215 prefs.edit().putInt(key, value).apply(); in setupKeyPreviewAnimationDuration()
220 prefs.edit().remove(key).apply(); in setupKeyPreviewAnimationDuration()
225 return Settings.readKeyPreviewAnimationDuration(prefs, key, defaultValue); in setupKeyPreviewAnimationDuration()
[all …]
/packages/apps/WallpaperPicker2/tests/src/com/android/wallpaper/testing/
DTestWallpaperRefresher.java46 WallpaperPreferences prefs = InjectorProvider.getInjector().getPreferences(mAppContext); in refresh() local
48 if (BuildCompat.isAtLeastN() && prefs.getLockWallpaperId() > 0) { in refresh()
51 prefs.getHomeWallpaperAttributions(), in refresh()
52 prefs.getHomeWallpaperActionUrl(), in refresh()
53 prefs.getHomeWallpaperActionLabelRes(), in refresh()
54 prefs.getHomeWallpaperActionIconRes(), in refresh()
55 prefs.getHomeWallpaperCollectionId(), in refresh()
56 prefs.getHomeWallpaperBackingFileName(), in refresh()
59 prefs.getLockWallpaperAttributions(), in refresh()
60 prefs.getLockWallpaperActionUrl(), in refresh()
[all …]
/packages/apps/Messaging/src/com/android/messaging/util/
DBuglePrefsImpl.java45 final SharedPreferences prefs = mContext.getSharedPreferences( in getInt() local
47 return prefs.getInt(key, defaultValue); in getInt()
53 final SharedPreferences prefs = mContext.getSharedPreferences( in getLong() local
55 return prefs.getLong(key, defaultValue); in getLong()
61 final SharedPreferences prefs = mContext.getSharedPreferences( in getBoolean() local
63 return prefs.getBoolean(key, defaultValue); in getBoolean()
69 final SharedPreferences prefs = mContext.getSharedPreferences( in getString() local
71 return prefs.getString(key, defaultValue); in getString()
83 final SharedPreferences prefs = mContext.getSharedPreferences( in putInt() local
85 final SharedPreferences.Editor editor = prefs.edit(); in putInt()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/connecteddevice/usb/
DUsbDetailsFunctionsControllerTest.java112 List<RadioButtonPreference> prefs = getRadioPreferences(); in displayRefresh_allAllowed_shouldCreatePrefs() local
115 for (RadioButtonPreference pref : prefs) { in displayRefresh_allAllowed_shouldCreatePrefs()
138 List<RadioButtonPreference> prefs = getRadioPreferences(); in displayRefresh_onlyMidiAllowed_shouldCreateOnlyMidiPref() local
139 assertThat(prefs.size()).isEqualTo(1); in displayRefresh_onlyMidiAllowed_shouldCreateOnlyMidiPref()
140 assertThat(prefs.get(0).getKey()) in displayRefresh_onlyMidiAllowed_shouldCreateOnlyMidiPref()
150 List<RadioButtonPreference> prefs = getRadioPreferences(); in displayRefresh_mtpEnabled_shouldCheckSwitches() local
152 assertThat(prefs.get(0).getKey()) in displayRefresh_mtpEnabled_shouldCheckSwitches()
154 assertThat(prefs.get(0).isChecked()).isTrue(); in displayRefresh_mtpEnabled_shouldCheckSwitches()
163 List<RadioButtonPreference> prefs = getRadioPreferences(); in displayRefresh_accessoryEnabled_shouldCheckSwitches() local
165 assertThat(prefs.get(0).getKey()) in displayRefresh_accessoryEnabled_shouldCheckSwitches()
[all …]
/packages/apps/MusicFX/src/com/android/musicfx/
DControlPanelEffect.java159 final SharedPreferences prefs = context.getSharedPreferences(packageName, in initEffectsPreferences() local
161 final SharedPreferences.Editor editor = prefs.edit(); in initEffectsPreferences()
167 final boolean isGlobalEnabled = prefs.getBoolean(Key.global_enabled.toString(), in initEffectsPreferences()
173 final boolean isVIEnabled = prefs.getBoolean(Key.virt_enabled.toString(), in initEffectsPreferences()
176 final int vIStrength = prefs.getInt(Key.virt_strength.toString(), in initEffectsPreferences()
199 final boolean isBBEnabled = prefs.getBoolean(Key.bb_enabled.toString(), in initEffectsPreferences()
201 final int bBStrength = prefs.getInt(Key.bb_strength.toString(), in initEffectsPreferences()
259 mEQPresetNames[preset] = prefs.getString( in initEffectsPreferences()
279 final short eQPreset = (short) prefs.getInt(Key.eq_current_preset.toString(), in initEffectsPreferences()
293 bandLevel[band] = (short) prefs.getInt( in initEffectsPreferences()
[all …]
/packages/apps/Traceur/src/com/android/traceur/
DReceiver.java79 SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context); in onReceive() local
89 prefs.edit().putBoolean( in onReceive()
100 if (prefs.getBoolean(context.getString(R.string.pref_key_stop_on_bugreport), false) && in onReceive()
101 !prefs.getBoolean(context.getString( in onReceive()
104prefs.edit().putBoolean(context.getString(R.string.pref_key_tracing_on), false).commit(); in onReceive()
118 SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context); in updateTracing() local
120 prefs.getBoolean(context.getString(R.string.pref_key_tracing_on), false); in updateTracing()
127 Set<String> activeAvailableTags = getActiveTags(context, prefs, true); in updateTracing()
128 Set<String> activeTags = getActiveTags(context, prefs, false); in updateTracing()
131 postCategoryNotification(context, prefs); in updateTracing()
[all …]
/packages/services/Telecomm/src/com/android/server/telecom/
DQuickResponseUtils.java64 final SharedPreferences prefs = context.getSharedPreferences( in maybeMigrateLegacyQuickResponses() local
68 final boolean responsesExist = prefs.contains(KEY_CANNED_RESPONSE_PREF_1) in maybeMigrateLegacyQuickResponses()
69 || prefs.contains(KEY_CANNED_RESPONSE_PREF_2) in maybeMigrateLegacyQuickResponses()
70 || prefs.contains(KEY_CANNED_RESPONSE_PREF_3) in maybeMigrateLegacyQuickResponses()
71 || prefs.contains(KEY_CANNED_RESPONSE_PREF_4); in maybeMigrateLegacyQuickResponses()
109 final SharedPreferences.Editor editor = prefs.edit(); in maybeMigrateLegacyQuickResponses()
129 public static void maybeResetQuickResponses(Context context, SharedPreferences prefs) { in maybeResetQuickResponses() argument
133 String currentValue1 = prefs.getString(QuickResponseUtils.KEY_CANNED_RESPONSE_PREF_1, ""); in maybeResetQuickResponses()
135 prefs.edit().remove(QuickResponseUtils.KEY_CANNED_RESPONSE_PREF_1).apply(); in maybeResetQuickResponses()
141 String currentValue2 = prefs.getString(QuickResponseUtils.KEY_CANNED_RESPONSE_PREF_2, ""); in maybeResetQuickResponses()
[all …]
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/keyboard/
DKeyboardTheme.java115 static KeyboardTheme getDefaultKeyboardTheme(final SharedPreferences prefs, in getDefaultKeyboardTheme() argument
117 final String klpThemeIdString = prefs.getString(KLP_KEYBOARD_THEME_KEY, null); in getDefaultKeyboardTheme()
134 prefs.edit().remove(KLP_KEYBOARD_THEME_KEY).apply(); in getDefaultKeyboardTheme()
150 public static void saveKeyboardThemeId(final int themeId, final SharedPreferences prefs) { in saveKeyboardThemeId() argument
151 saveKeyboardThemeId(themeId, prefs, BuildCompatUtils.EFFECTIVE_SDK_INT); in saveKeyboardThemeId()
163 static void saveKeyboardThemeId(final int themeId, final SharedPreferences prefs, in saveKeyboardThemeId() argument
166 prefs.edit().putString(prefKey, Integer.toString(themeId)).apply(); in saveKeyboardThemeId()
170 final SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context); in getKeyboardTheme() local
172 return getKeyboardTheme(prefs, BuildCompatUtils.EFFECTIVE_SDK_INT, availableThemeArray); in getKeyboardTheme()
195 static KeyboardTheme getKeyboardTheme(final SharedPreferences prefs, final int sdkVersion, in getKeyboardTheme() argument
[all …]
/packages/apps/Car/tests/TestMediaApp/src/com/android/car/media/testmediaapp/prefs/
DTmaPrefsFragment.java17 package com.android.car.media.testmediaapp.prefs;
31 import com.android.car.media.testmediaapp.prefs.TmaEnumPrefs.TmaAccountType;
32 import com.android.car.media.testmediaapp.prefs.TmaEnumPrefs.TmaBrowseNodeType;
33 import com.android.car.media.testmediaapp.prefs.TmaEnumPrefs.TmaLoginEventOrder;
34 import com.android.car.media.testmediaapp.prefs.TmaEnumPrefs.TmaReplyDelay;
35 import com.android.car.media.testmediaapp.prefs.TmaPrefs.PrefEntry;
45 TmaPrefs prefs = TmaPrefs.getInstance(context); in onCreatePreferences() local
48 screen.addPreference(createEnumPref(context, "Account Type", prefs.mAccountType, in onCreatePreferences()
50 screen.addPreference(createEnumPref(context, "Root node type", prefs.mRootNodeType, in onCreatePreferences()
52 screen.addPreference(createEnumPref(context, "Root reply delay", prefs.mRootReplyDelay, in onCreatePreferences()
[all …]
/packages/services/Telephony/src/com/android/phone/settings/
DVoicemailProviderSettingsUtil.java55 SharedPreferences prefs = getPrefs(context); in load() local
57 String vmNumberSetting = prefs.getString(key + VM_NUMBER_TAG, null); in load()
66 int fwdLen = prefs.getInt(fwdKey + FWD_SETTINGS_LENGTH_TAG, 0); in load()
72 cfi[i].status = prefs.getInt(settingKey + FWD_SETTING_STATUS, 0); in load()
73 cfi[i].reason = prefs.getInt( in load()
78 cfi[i].number = prefs.getString(settingKey + FWD_SETTING_NUMBER, ""); in load()
79 cfi[i].timeSeconds = prefs.getInt(settingKey + FWD_SETTING_TIME, 20); in load()
103 SharedPreferences prefs = getPrefs(context); in save() local
104 SharedPreferences.Editor editor = prefs.edit(); in save()
136 SharedPreferences prefs = getPrefs(context); in delete() local
[all …]
/packages/apps/Calendar/src/com/android/calendar/
DCalendarUtils.java126 SharedPreferences prefs = getSharedPreferences((Context)cookie, mPrefsName); in onQueryComplete() local
128 setSharedPreference(prefs, KEY_HOME_TZ_ENABLED, mUseHomeTZ); in onQueryComplete()
129 setSharedPreference(prefs, KEY_HOME_TZ, mHomeTZ); in onQueryComplete()
223 SharedPreferences prefs = getSharedPreferences(context, mPrefsName); in setTimeZone() local
224 setSharedPreference(prefs, KEY_HOME_TZ_ENABLED, mUseHomeTZ); in setTimeZone()
225 setSharedPreference(prefs, KEY_HOME_TZ, mHomeTZ); in setTimeZone()
273 SharedPreferences prefs = getSharedPreferences(context, mPrefsName); in getTimeZone() local
274 mUseHomeTZ = prefs.getBoolean(KEY_HOME_TZ_ENABLED, false); in getTimeZone()
275 mHomeTZ = prefs.getString(KEY_HOME_TZ, Time.getCurrentTimezone()); in getTimeZone()
330 public static void setSharedPreference(SharedPreferences prefs, String key, String value) { in setSharedPreference() argument
[all …]
DUtils.java219 SharedPreferences prefs = GeneralPreferences.getSharedPreferences(activity); in getViewTypeFromIntentAndSharedPref() local
227 return prefs.getInt(GeneralPreferences.KEY_DETAILED_VIEW, in getViewTypeFromIntentAndSharedPref()
236 return prefs.getInt( in getViewTypeFromIntentAndSharedPref()
301 public static boolean getDefaultVibrate(Context context, SharedPreferences prefs) { in getDefaultVibrate() argument
303 if (prefs.contains(KEY_ALERTS_VIBRATE_WHEN)) { in getDefaultVibrate()
308 String vibrateWhen = prefs.getString(KEY_ALERTS_VIBRATE_WHEN, null); in getDefaultVibrate()
311 prefs.edit().remove(KEY_ALERTS_VIBRATE_WHEN).commit(); in getDefaultVibrate()
315 vibrate = prefs.getBoolean(GeneralPreferences.KEY_ALERTS_VIBRATE, in getDefaultVibrate()
322 SharedPreferences prefs = GeneralPreferences.getSharedPreferences(context); in getSharedPreference() local
323 Set<String> ss = prefs.getStringSet(key, null); in getSharedPreference()
[all …]
DOtherPreferences.java94 SharedPreferences prefs = manager.getSharedPreferences(); in onCreate() local
108 int startHour = prefs.getInt(KEY_OTHER_QUIET_HOURS_START_HOUR, in onCreate()
110 int startMinute = prefs.getInt(KEY_OTHER_QUIET_HOURS_START_MINUTE, in onCreate()
119 int endHour = prefs.getInt(KEY_OTHER_QUIET_HOURS_END_HOUR, in onCreate()
121 int endMinute = prefs.getInt(KEY_OTHER_QUIET_HOURS_END_MINUTE, in onCreate()
174 SharedPreferences prefs = getPreferenceManager().getSharedPreferences(); in onTimeSet() local
175 SharedPreferences.Editor editor = prefs.edit(); in onTimeSet()
/packages/apps/Dialer/java/com/android/voicemail/impl/settings/
DVisualVoicemailSettingsUtil.java139 VisualVoicemailPreferences prefs = new VisualVoicemailPreferences(context, phoneAccount); in isEnabled() local
140 if (prefs.contains(IS_ENABLED_KEY)) { in isEnabled()
143 return prefs.getBoolean(IS_ENABLED_KEY, false); in isEnabled()
151 VisualVoicemailPreferences prefs = new VisualVoicemailPreferences(context, phoneAccount); in isArchiveEnabled() local
152 return prefs.getBoolean(ARCHIVE_ENABLED_KEY, false); in isArchiveEnabled()
159 VisualVoicemailPreferences prefs = new VisualVoicemailPreferences(context, phoneAccount); in isVoicemailTranscriptionEnabled() local
160 return prefs.getBoolean(TRANSCRIBE_VOICEMAILS_KEY, false); in isVoicemailTranscriptionEnabled()
167 VisualVoicemailPreferences prefs = new VisualVoicemailPreferences(context, phoneAccount); in isVoicemailDonationEnabled() local
168 return prefs.getBoolean(DONATE_VOICEMAILS_KEY, false); in isVoicemailDonationEnabled()
181 VisualVoicemailPreferences prefs = new VisualVoicemailPreferences(context, phoneAccount); in isEnabledUserSet() local
[all …]
/packages/apps/CellBroadcastReceiver/src/com/android/cellbroadcastreceiver/
DCellBroadcastConfigService.java166 SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(this); in enableCellBroadcastChannels() local
173 boolean enableAlertsMasterToggle = prefs.getBoolean( in enableCellBroadcastChannels()
182 boolean enableCmasExtremeAlerts = enableAlertsMasterToggle && prefs.getBoolean( in enableCellBroadcastChannels()
185 boolean enableCmasSevereAlerts = enableAlertsMasterToggle && prefs.getBoolean( in enableCellBroadcastChannels()
188 boolean enableCmasAmberAlerts = enableAlertsMasterToggle && prefs.getBoolean( in enableCellBroadcastChannels()
193 && prefs.getBoolean(CellBroadcastSettings.KEY_ENABLE_TEST_ALERTS, false); in enableCellBroadcastChannels()
197 && prefs.getBoolean(CellBroadcastSettings.KEY_ENABLE_EXERCISE_ALERTS, false); in enableCellBroadcastChannels()
201 && prefs.getBoolean(CellBroadcastSettings.KEY_OPERATOR_DEFINED_ALERTS, false); in enableCellBroadcastChannels()
205 && prefs.getBoolean(CellBroadcastSettings.KEY_ENABLE_AREA_UPDATE_INFO_ALERTS, in enableCellBroadcastChannels()
209 && prefs.getBoolean(CellBroadcastSettings.KEY_ENABLE_PUBLIC_SAFETY_MESSAGES, in enableCellBroadcastChannels()
[all …]
/packages/services/Car/tests/GarageModeTestApp/src/com/google/android/car/garagemode/testapp/
DWatchdog.java47 public Watchdog(Context context, TextView view, SharedPreferences prefs) { in Watchdog() argument
49 mSharedPrefs = prefs; in Watchdog()
50 mEvents = getEventsFromSharedPrefs(prefs); in Watchdog()
88 private LinkedList<String> getEventsFromSharedPrefs(SharedPreferences prefs) { in getEventsFromSharedPrefs() argument
90 String file = prefs.getString(PREFS_EVENTS_LIST, ""); in getEventsFromSharedPrefs()
97 private void saveEventsToSharedPrefs(SharedPreferences prefs, LinkedList<String> list) { in saveEventsToSharedPrefs() argument
106 SharedPreferences.Editor editor = prefs.edit(); in saveEventsToSharedPrefs()
/packages/apps/Dialer/java/com/android/contacts/common/list/
DContactListFilter.java97 public static void storeToPreferences(SharedPreferences prefs, ContactListFilter filter) { in storeToPreferences() argument
101 prefs in storeToPreferences()
114 public static ContactListFilter restoreDefaultPreferences(SharedPreferences prefs) { in restoreDefaultPreferences() argument
115 ContactListFilter filter = restoreFromPreferences(prefs); in restoreDefaultPreferences()
127 private static ContactListFilter restoreFromPreferences(SharedPreferences prefs) { in restoreFromPreferences() argument
128 int filterType = prefs.getInt(KEY_FILTER_TYPE, FILTER_TYPE_DEFAULT); in restoreFromPreferences()
133 String accountName = prefs.getString(KEY_ACCOUNT_NAME, null); in restoreFromPreferences()
134 String accountType = prefs.getString(KEY_ACCOUNT_TYPE, null); in restoreFromPreferences()
135 String dataSet = prefs.getString(KEY_DATA_SET, null); in restoreFromPreferences()
/packages/apps/Messaging/src/com/android/messaging/ui/
DWidgetPickConversationActivity.java98 final BuglePrefs prefs = Factory.get().getWidgetPrefs(); in saveConversationidPref() local
99 prefs.putString(UIIntents.UI_INTENT_EXTRA_CONVERSATION_ID + appWidgetId, conversationId); in saveConversationidPref()
104 final BuglePrefs prefs = Factory.get().getWidgetPrefs(); in getConversationIdPref() local
105 return prefs.getString(UIIntents.UI_INTENT_EXTRA_CONVERSATION_ID + appWidgetId, null); in getConversationIdPref()
110 final BuglePrefs prefs = Factory.get().getWidgetPrefs(); in deleteConversationIdPref() local
111 prefs.remove(UIIntents.UI_INTENT_EXTRA_CONVERSATION_ID + appWidgetId); in deleteConversationIdPref()

123456789