SetupWizard: Initialize the nav keys bundle boolean
Change-Id: I50f2ef0fb7226c8b58437b669ca71df436d68ee8
(cherry picked from commit 33683fc2ce
)
This commit is contained in:
@@ -203,7 +203,7 @@ public class CyanogenSettingsPage extends SetupPage {
|
|||||||
SetupWizardUtils.isSimMissing(context));
|
SetupWizardUtils.isSimMissing(context));
|
||||||
}
|
}
|
||||||
|
|
||||||
protected static boolean hideThemeSwitch(Context context) {
|
private static boolean hideThemeSwitch(Context context) {
|
||||||
return ThemeUtils.getDefaultThemePackageName(context).equals(ThemeConfig.SYSTEM_DEFAULT);
|
return ThemeUtils.getDefaultThemePackageName(context).equals(ThemeConfig.SYSTEM_DEFAULT);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -395,12 +395,14 @@ public class CyanogenSettingsPage extends SetupPage {
|
|||||||
|
|
||||||
private void updateDisableNavkeysOption() {
|
private void updateDisableNavkeysOption() {
|
||||||
if (!mHideNavKeysRow) {
|
if (!mHideNavKeysRow) {
|
||||||
|
final Bundle myPageBundle = mPage.getData();
|
||||||
boolean enabled = Settings.Secure.getInt(getActivity().getContentResolver(),
|
boolean enabled = Settings.Secure.getInt(getActivity().getContentResolver(),
|
||||||
Settings.Secure.DEV_FORCE_SHOW_NAVBAR, 0) != 0;
|
Settings.Secure.DEV_FORCE_SHOW_NAVBAR, 0) != 0;
|
||||||
boolean checked = mPage.getData().containsKey(KEY_ENABLE_NAV_KEYS) ?
|
boolean checked = myPageBundle.containsKey(KEY_ENABLE_NAV_KEYS) ?
|
||||||
mPage.getData().getBoolean(KEY_ENABLE_NAV_KEYS) :
|
myPageBundle.getBoolean(KEY_ENABLE_NAV_KEYS) :
|
||||||
enabled;
|
enabled;
|
||||||
mNavKeys.setChecked(checked);
|
mNavKeys.setChecked(checked);
|
||||||
|
myPageBundle.putBoolean(KEY_ENABLE_NAV_KEYS, checked);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user