mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-03-02 17:06:49 +00:00
Refactoring getPreferenceKey method
This method was returnning a constant and getting inlined by proguard. Change-Id: I87348e25b21483adc1b27d16f99dec4b73205701
This commit is contained in:
@@ -25,7 +25,6 @@ import android.graphics.drawable.Drawable;
|
||||
import android.os.Build;
|
||||
import android.os.UserHandle;
|
||||
|
||||
import com.android.launcher3.LauncherAppState;
|
||||
import com.android.launcher3.Utilities;
|
||||
import com.android.launcher3.util.LongArrayMap;
|
||||
|
||||
@@ -104,8 +103,7 @@ public class UserManagerCompatVL extends UserManagerCompatV17 {
|
||||
if (Utilities.ATLEAST_MARSHMALLOW) {
|
||||
return mUserManager.getUserCreationTime(user.getUser());
|
||||
}
|
||||
SharedPreferences prefs = mContext.getSharedPreferences(
|
||||
LauncherAppState.getSharedPreferencesKey(), Context.MODE_PRIVATE);
|
||||
SharedPreferences prefs = Utilities.getPrefs(mContext);
|
||||
String key = USER_CREATION_TIME_KEY + getSerialNumberForUser(user);
|
||||
if (!prefs.contains(key)) {
|
||||
prefs.edit().putLong(key, System.currentTimeMillis()).apply();
|
||||
|
||||
Reference in New Issue
Block a user