summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristopher Tate <ctate@google.com>2012-02-15 14:40:27 -0800
committerChristopher Tate <ctate@google.com>2012-02-15 15:38:43 -0800
commit8fead6615978d370a41a6f9417edb000ec441064 (patch)
tree2729fea52c834a309568647b19a32240509c5acd
parente08eaee3a0d4abdedd1e59dddab09f2fa88744cc (diff)
downloadframeworks_base-8fead6615978d370a41a6f9417edb000ec441064.zip
frameworks_base-8fead6615978d370a41a6f9417edb000ec441064.tar.gz
frameworks_base-8fead6615978d370a41a6f9417edb000ec441064.tar.bz2
DO NOT MERGE - Configuration resource to suppress tablet status bar contents
This is a grotesque hack to avoid showing status bar controls. The real solution will be coming via master but not extremely soon; stay tuned but this gives the right presentation for now without affecting normal products. Bug 5824373 Change-Id: Ib5348024853ad2e7715b824aba522d80b6a99048
-rwxr-xr-xcore/res/res/values/config.xml5
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletStatusBar.java11
2 files changed, 16 insertions, 0 deletions
diff --git a/core/res/res/values/config.xml b/core/res/res/values/config.xml
index db5e400..d73a75d 100755
--- a/core/res/res/values/config.xml
+++ b/core/res/res/values/config.xml
@@ -747,6 +747,11 @@
autodetected from the Configuration. -->
<bool name="config_showNavigationBar">false</bool>
+ <!-- Whether to suppress tablet status/nav bar contents. NOTE: this makes the
+ device essentially useless except for kiosk-type scenarios. This
+ configuration parameter will also go away soon. -->
+ <bool name="config_emptyTabletStatusBar">false</bool>
+
<!-- Whether action menu items should be displayed in ALLCAPS or not.
Defaults to true. If this is not appropriate for specific locales
it should be disabled in that locale's resources. -->
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletStatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletStatusBar.java
index 2b1c1ca..da9928a 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletStatusBar.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/tablet/TabletStatusBar.java
@@ -199,6 +199,17 @@ public class TabletStatusBar extends StatusBar implements
final Context context = mContext;
final Resources res = mContext.getResources();
+ // Product definitions can force the system bar to be empty. Note that
+ // this renders the device largely unusable except for kiosk-type
+ // scenarios.
+ try {
+ final boolean emptyBar = res.getBoolean(
+ com.android.internal.R.bool.config_emptyTabletStatusBar);
+ if (emptyBar) return;
+ } catch (Resources.NotFoundException e) {
+ // no override; ignore and use the default behavior
+ }
+
// Notification Panel
mNotificationPanel = (NotificationPanel)View.inflate(context,
R.layout.status_bar_notification_panel, null);