diff options
| author | 2016-04-11 11:00:46 -0400 | |
|---|---|---|
| committer | 2016-04-11 11:00:46 -0400 | |
| commit | 339df0742c134f48495ac9feec168d58870a942f (patch) | |
| tree | 9f35bc5b73a521e7f7f41f7f67a05c6eaa19948e | |
| parent | 726959bf765b5aa4a43c5b62149a72fba7ffac57 (diff) | |
Guard against crash in RTL.
Change-Id: Id692360cc66600a06a4353a8029440be422cc79f
Fixes: 27927374
| -rw-r--r-- | packages/SystemUI/src/com/android/systemui/qs/PageIndicator.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/qs/PageIndicator.java b/packages/SystemUI/src/com/android/systemui/qs/PageIndicator.java index ba07bf4414c1..5cb46ac22889 100644 --- a/packages/SystemUI/src/com/android/systemui/qs/PageIndicator.java +++ b/packages/SystemUI/src/com/android/systemui/qs/PageIndicator.java @@ -118,6 +118,10 @@ public class PageIndicator extends ViewGroup { } ImageView first = (ImageView) getChildAt(firstIndex); ImageView second = (ImageView) getChildAt(secondIndex); + if (second == null) { + // Weird state where number of pages must not have propagated yet. + return; + } // Lay the two views on top of each other. second.setTranslationX(first.getX() - second.getX()); |