diff options
author | Jason Monk <jmonk@google.com> | 2015-07-13 10:42:23 -0400 |
---|---|---|
committer | Jason Monk <jmonk@google.com> | 2015-07-13 10:42:23 -0400 |
commit | 33b60bb45ff45540c4bd4f5d74f3ca5489f02088 (patch) | |
tree | 3149b65e11cabd11033a84b2f8df1627179231f3 /packages/SystemUI/src/com/android/systemui/tuner | |
parent | 0ec43f89d2fc7064e7b42b40b318bef15fb040b5 (diff) | |
download | frameworks_base-33b60bb45ff45540c4bd4f5d74f3ca5489f02088.zip frameworks_base-33b60bb45ff45540c4bd4f5d74f3ca5489f02088.tar.gz frameworks_base-33b60bb45ff45540c4bd4f5d74f3ca5489f02088.tar.bz2 |
Fix demo mode issues
Bug: 22387423
Change-Id: I7b0b4ca75bae12a9fb3a90ab804b263e8d982b46
Diffstat (limited to 'packages/SystemUI/src/com/android/systemui/tuner')
-rw-r--r-- | packages/SystemUI/src/com/android/systemui/tuner/DemoModeFragment.java | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/tuner/DemoModeFragment.java b/packages/SystemUI/src/com/android/systemui/tuner/DemoModeFragment.java index ca6aaeb..3f5ca58 100644 --- a/packages/SystemUI/src/com/android/systemui/tuner/DemoModeFragment.java +++ b/packages/SystemUI/src/com/android/systemui/tuner/DemoModeFragment.java @@ -103,6 +103,11 @@ public class DemoModeFragment extends PreferenceFragment implements OnPreference @Override public boolean onPreferenceChange(Preference preference, Object newValue) { if (preference == mEnabledSwitch) { + if (newValue != Boolean.TRUE) { + // Make sure we aren't in demo mode when disabling it. + mOnSwitch.setChecked(false); + stopDemoMode(); + } setGlobal(DEMO_MODE_ALLOWED, newValue == Boolean.TRUE ? 1 : 0); } else if (preference == mOnSwitch) { if (newValue == Boolean.TRUE) { @@ -123,7 +128,7 @@ public class DemoModeFragment extends PreferenceFragment implements OnPreference getContext().sendBroadcast(intent); intent.putExtra(DemoMode.EXTRA_COMMAND, DemoMode.COMMAND_CLOCK); - intent.putExtra("hhmm", "0520"); + intent.putExtra("hhmm", "0600"); getContext().sendBroadcast(intent); intent.putExtra(DemoMode.EXTRA_COMMAND, DemoMode.COMMAND_NETWORK); |