Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6bf51d38 authored by Santiago Etchebehere's avatar Santiago Etchebehere
Browse files

Add a prefix to visited tab preferences keys

This makes it easy to identify and backup visited tab
preferences

Bug: 130304311
Change-Id: I22688a623286ae3ec605a4a3fa3f3e1c13a5e823
parent 57373045
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -20,6 +20,7 @@ import com.android.wallpaper.module.WallpaperPreferences;
public interface CustomizationPreferences extends WallpaperPreferences {

    String KEY_CUSTOM_THEME= "themepicker_custom_theme";
    String KEY_VISITED_PREFIX = "themepicker_visited_";

    String getSerializedCustomTheme();

+2 −2
Original line number Diff line number Diff line
@@ -39,11 +39,11 @@ public class DefaultCustomizationPreferences extends DefaultWallpaperPreferences

    @Override
    public boolean getTabVisited(String id) {
        return mSharedPrefs.getBoolean(id, false);
        return mSharedPrefs.getBoolean(KEY_VISITED_PREFIX + id, false);
    }

    @Override
    public void setTabVisited(String id) {
        mSharedPrefs.edit().putBoolean(id, true).apply();
        mSharedPrefs.edit().putBoolean(KEY_VISITED_PREFIX + id, true).apply();
    }
}