commit | 922c1182e0c3526fa9617c7ab68302b8ecdf131e | [log] [tgz] |
---|---|---|
author | Tony Wickham <twickham@google.com> | Tue Sep 21 15:56:38 2021 +0000 |
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | Tue Sep 21 15:56:38 2021 +0000 |
tree | 378c437287682daeab4f26e1f6052e8c77783f69 | |
parent | 407587b721740dfedbcd0497330675b8116ab3df [diff] | |
parent | be34ef61a350ec7beebda84cf8630a80fbe8725b [diff] |
Merge "Take panel count into account for page indicator size" into sc-v2-dev am: be34ef61a3 Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15873888 Change-Id: I68382a61ec6e2524c012391b6c8c903cd6b36dfb
diff --git a/src/com/android/launcher3/PagedView.java b/src/com/android/launcher3/PagedView.java index a7198a8..d534c5d 100644 --- a/src/com/android/launcher3/PagedView.java +++ b/src/com/android/launcher3/PagedView.java
@@ -208,7 +208,7 @@ public void initParentViews(View parent) { if (mPageIndicatorViewId > -1) { mPageIndicator = parent.findViewById(mPageIndicatorViewId); - mPageIndicator.setMarkersCount(getChildCount()); + mPageIndicator.setMarkersCount(getChildCount() / getPanelCount()); } } @@ -830,7 +830,7 @@ private void dispatchPageCountChanged() { if (mPageIndicator != null) { - mPageIndicator.setMarkersCount(getChildCount()); + mPageIndicator.setMarkersCount(getChildCount() / getPanelCount()); } // This ensures that when children are added, they get the correct transforms / alphas // in accordance with any scroll effects.