Ensure page scrolls are initialized even for 0 children.
Bug: 233713180 Test: Walk through CtsVerifier Lock Task UI flow as described in the bug Change-Id: I49cb942a37a202b3e1b7ee00479d68402fcaf8b0
This commit is contained in:
1 parent
5ba5c76c76
commit
359cb5d1b6
1 file changed
+5
-4
@@ -727,15 +727,16 @@ public abstract class PagedView<T extends View & PageIndicator> extends ViewGrou
|
||||
pageScrollChanged = true;
|
||||
}
|
||||
|
||||
if (childCount == 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (DEBUG) Log.d(TAG, "PagedView.onLayout()");
|
||||
|
||||
pageScrollChanged |= getPageScrolls(pageScrolls, true, SIMPLE_SCROLL_LOGIC);
|
||||
mPageScrolls = pageScrolls;
|
||||
|
||||
if (childCount == 0) {
|
||||
onPageScrollsInitialized();
|
||||
return;
|
||||
}
|
||||
|
||||
final LayoutTransition transition = getLayoutTransition();
|
||||
// If the transition is running defer updating max scroll, as some empty pages could
|
||||
// still be present, and a max scroll change could cause sudden jumps in scroll.
|
||||
|
||||
Reference in new issue
Block a user