From 48a7651823030ed3c0f4c084b423430044425fea Mon Sep 17 00:00:00 2001 From: Dianne Hackborn Date: Wed, 8 Jun 2011 21:51:44 -0700 Subject: Fix for not reporting correct "sw" in compat mode. Change-Id: Ia225c94b36ccc3589d417aafd5680247678eddfd --- .../src/com/android/systemui/statusbar/policy/CompatModeButton.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'packages/SystemUI/src/com/android/systemui/statusbar/policy') diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/CompatModeButton.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/CompatModeButton.java index 9b44f78..c3052e8 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/CompatModeButton.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/CompatModeButton.java @@ -54,8 +54,9 @@ public class CompatModeButton extends ImageView implements View.OnClickListener } public void refresh() { - setVisibility( - (mAM.getFrontActivityScreenCompatMode() == ActivityManager.COMPAT_MODE_NEVER) + int mode = mAM.getFrontActivityScreenCompatMode(); + setVisibility((mode == ActivityManager.COMPAT_MODE_NEVER + || mode == ActivityManager.COMPAT_MODE_ALWAYS) ? View.GONE : View.VISIBLE ); -- cgit v1.1