commit | 0164d7d346ba1bee54504529ae787508fdc260e2 | [log] [tgz] |
---|---|---|
author | Tony Wickham <twickham@google.com> | Thu Apr 05 16:00:09 2018 -0700 |
committer | Tony Wickham <twickham@google.com> | Thu Apr 05 16:00:09 2018 -0700 |
tree | dd52c77f22c8802990d52a37938c739bdce61287 | |
parent | b3ad0edc1476ae1562bb5e0b26f253b2e504285f [diff] |
Add null check for empty recents view Bug: 77533523 Change-Id: I8ba58d3ed35212b6c06e689281cb25b55ac79ae2
diff --git a/quickstep/src/com/android/quickstep/views/RecentsView.java b/quickstep/src/com/android/quickstep/views/RecentsView.java index d95619c..b2bf030 100644 --- a/quickstep/src/com/android/quickstep/views/RecentsView.java +++ b/quickstep/src/com/android/quickstep/views/RecentsView.java
@@ -1064,7 +1064,10 @@ @Override protected void notifyPageSwitchListener(int prevPage) { super.notifyPageSwitchListener(prevPage); - getChildAt(mCurrentPage).sendAccessibilityEvent(AccessibilityEvent.TYPE_VIEW_FOCUSED); + View currChild = getChildAt(mCurrentPage); + if (currChild != null) { + currChild.sendAccessibilityEvent(AccessibilityEvent.TYPE_VIEW_FOCUSED); + } } @Override