OSDN Git Service

Fix screenshots.
authorDan Sandler <dsandler@android.com>
Thu, 7 Aug 2014 13:21:06 +0000 (09:21 -0400)
committerThe Android Automerger <android-build@android.com>
Thu, 7 Aug 2014 18:51:03 +0000 (11:51 -0700)
Bug: 16861182
Change-Id: I9433cb4a5cc100d85f06eeed18ade3ead5ba8188

packages/SystemUI/src/com/android/systemui/screenshot/GlobalScreenshot.java

index c559253..d4c8ce3 100644 (file)
@@ -429,6 +429,9 @@ class GlobalScreenshot {
         try {
             panelWidth = r.getDimensionPixelSize(R.dimen.notification_panel_width);
         } catch (Resources.NotFoundException e) {
+        }
+        if (panelWidth <= 0) {
+            // includes notification_panel_width==match_parent (-1)
             panelWidth = mDisplayMetrics.widthPixels;
         }
         mPreviewWidth = panelWidth;