List of usage examples for android.content SharedPreferences getBoolean
boolean getBoolean(String key, boolean defValue);
From source file:Main.java
public static boolean getBooleanValue(Context context, String key, boolean default_value) { SharedPreferences data = context.getSharedPreferences("config", 0); return data.getBoolean(key, default_value); }
From source file:Main.java
private static boolean getCompletedFromPreferences(SharedPreferences preferences, String welcomeScreenKey) { return preferences.getBoolean(getKey(welcomeScreenKey), false); }
From source file:Main.java
public static boolean isDownloading(Context context) { SharedPreferences sp = context.getSharedPreferences(PREFS_CACHE_ONE, 0); return sp.getBoolean("isDownloading", false); }
From source file:Main.java
public static boolean isShowView(Context context) { SharedPreferences sp = context.getSharedPreferences(PREFS_CACHE_ONE, 0); return sp.getBoolean("isShowView", false); }
From source file:Main.java
public static boolean isEnableGprs(Context context) { SharedPreferences sp = context.getSharedPreferences(PREFS_CACHE_ONE, 0); return sp.getBoolean("isEnableGprs", false); }
From source file:Main.java
public static boolean getBooleanSharedPreferences(Context context, String name, String key, boolean defaultValue) { SharedPreferences preferences = context.getSharedPreferences(name, 0); return preferences.getBoolean(key, defaultValue); }
From source file:Main.java
public static boolean getBoolean(Context ctx, String key, Boolean defaultValue) { SharedPreferences sp = ctx.getSharedPreferences(PREF_NAME, ctx.MODE_PRIVATE); return sp.getBoolean(key, defaultValue); }
From source file:Main.java
public static boolean getBooleanFromDefault(Context context, String key, boolean defValue) { SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(context); return sp.getBoolean(key, defValue); }
From source file:Main.java
public static boolean getBoolean(Context ctx, String key, boolean defValue) { SharedPreferences sp = ctx.getSharedPreferences("config", Context.MODE_PRIVATE); return sp.getBoolean(key, defValue); }
From source file:Main.java
public static boolean getBoolean(String key, boolean defValue, Context ctx) { SharedPreferences sp = ctx.getSharedPreferences("config", Context.MODE_PRIVATE); return sp.getBoolean(key, defValue); }