Home
last modified time | relevance | path

Searched refs:mPrefs (Results 1 – 3 of 3) sorted by relevance

/developers/samples/android/input/autofill/AutofillFramework/afservice/src/main/java/com/example/android/autofill/service/settings/
DMyPreferences.java34 private final SharedPreferences mPrefs; field in MyPreferences
37 mPrefs = context.getApplicationContext().getSharedPreferences("my-settings", in MyPreferences()
52 return mPrefs.getBoolean(RESPONSE_AUTH_KEY, false); in isResponseAuth()
59 mPrefs.edit().putBoolean(RESPONSE_AUTH_KEY, responseAuth).apply(); in setResponseAuth()
66 return mPrefs.getBoolean(DATASET_AUTH_KEY, false); in isDatasetAuth()
73 mPrefs.edit().putBoolean(DATASET_AUTH_KEY, datasetAuth).apply(); in setDatasetAuth()
80 return mPrefs.getString(MAIN_PASSWORD_KEY, null); in getMainPassword()
87 mPrefs.edit().putString(MAIN_PASSWORD_KEY, mainPassword).apply(); in setMainPassword()
91 mPrefs.edit().remove(MAIN_PASSWORD_KEY).apply(); in clearCredentials()
95 return Util.LogLevel.values()[mPrefs.getInt(LOGGING_LEVEL, Util.LogLevel.Off.ordinal())]; in getLoggingLevel()
[all …]
/developers/samples/android/deprecated/wearable/wear/Geofencing/Application/src/main/java/com/example/android/wearable/geofencing/
DSimpleGeofenceStore.java38 private final SharedPreferences mPrefs; field in SimpleGeofenceStore
46 mPrefs = context.getSharedPreferences(SHARED_PREFERENCES, Context.MODE_PRIVATE); in SimpleGeofenceStore()
57 double lat = mPrefs.getFloat(getGeofenceFieldKey(id, KEY_LATITUDE), in getGeofence()
59 double lng = mPrefs.getFloat(getGeofenceFieldKey(id, KEY_LONGITUDE), in getGeofence()
61 float radius = mPrefs.getFloat(getGeofenceFieldKey(id, KEY_RADIUS), in getGeofence()
64 mPrefs.getLong(getGeofenceFieldKey(id, KEY_EXPIRATION_DURATION), in getGeofence()
66 int transitionType = mPrefs.getInt(getGeofenceFieldKey(id, KEY_TRANSITION_TYPE), in getGeofence()
87 SharedPreferences.Editor prefs = mPrefs.edit(); in setGeofence()
104 SharedPreferences.Editor prefs = mPrefs.edit(); in clearGeofence()
/developers/samples/android/testing/ActivityInstrumentation/Application/src/main/java/com/example/android/activityinstrumentation/
DMainActivity.java56 private SharedPreferences mPrefs; field in MainActivity
73 mPrefs = PreferenceManager.getDefaultSharedPreferences(MainActivity.this); in onCreate()
85 int selection = mPrefs.getInt(PREF_SPINNER_POS, PREF_SPINNER_VALUE_ISNULL); in onCreate()
101 mPrefs.edit().putInt(PREF_SPINNER_POS, position).commit(); in onCreate()
106 mPrefs.edit().remove(PREF_SPINNER_POS).commit(); in onCreate()