List of usage examples for android.preference PreferenceManager getDefaultSharedPreferences
public static SharedPreferences getDefaultSharedPreferences(Context context)
From source file:Main.java
public static int getInt(String key, Context context) { return PreferenceManager.getDefaultSharedPreferences(context).getInt(key, -1); }
From source file:Main.java
public static boolean isAutoTransparent(Context context) { return PreferenceManager.getDefaultSharedPreferences(context).getBoolean("autoTrans", true); }
From source file:Main.java
private static String getStr(Context context, String key) { return PreferenceManager.getDefaultSharedPreferences(context).getString(key, ""); }
From source file:Main.java
public static void setIconTransparency(Context context, int alpha) { PreferenceManager.getDefaultSharedPreferences(context).edit().putInt("icon_alpha", alpha).apply(); }
From source file:Main.java
public static boolean isStatusBarIconHidden(Context context) { return PreferenceManager.getDefaultSharedPreferences(context).getBoolean("status_bar_hidden", false); }
From source file:Main.java
public static int readIntPreference(String s, Context context) { return PreferenceManager.getDefaultSharedPreferences(context).getInt(s, 0); }
From source file:Main.java
public static boolean hasKey(Context context, final String key) { return PreferenceManager.getDefaultSharedPreferences(context).contains(key); }
From source file:Main.java
public static String getPreference(Context context, String key) { return PreferenceManager.getDefaultSharedPreferences(context).getString(key, ""); }
From source file:Main.java
public static String readStringPreference(String s, Context context) { return PreferenceManager.getDefaultSharedPreferences(context).getString(s, ""); }
From source file:Main.java
public static String GetPref(Context c, String name, String defaultValue) { return PreferenceManager.getDefaultSharedPreferences(c).getString(name, defaultValue); }