Merge "Merge "Fix clipping of an app badge on bubbles in overflow" into tm-qpr-dev am: a6e03b009c" into tm-qpr-dev-plus-aosp am: c27b541c09

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18456418

Change-Id: I98fe4f72842e79c278b8f403916a9d987455a47a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Automerger Merge Worker
2022-05-19 16:16:46 +00:00
3 changed files with 9 additions and 3 deletions

View File

@@ -30,7 +30,8 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center_horizontal"
android:gravity="center"/>
android:gravity="center"
android:clipChildren="false"/>
<LinearLayout
android:id="@+id/bubble_overflow_empty_state"

View File

@@ -887,7 +887,9 @@ public class BubbleExpandedView extends LinearLayout {
mTaskView.onLocationChanged();
}
if (mIsOverflow) {
mOverflowView.show();
post(() -> {
mOverflowView.show();
});
}
}

View File

@@ -167,7 +167,10 @@ public class BubbleOverflowContainerView extends LinearLayout {
void updateOverflow() {
Resources res = getResources();
final int columns = res.getInteger(R.integer.bubbles_overflow_columns);
int columns = (int) Math.round(getWidth()
/ (res.getDimension(R.dimen.bubble_name_width)));
columns = columns > 0 ? columns : res.getInteger(R.integer.bubbles_overflow_columns);
mRecyclerView.setLayoutManager(
new OverflowGridLayoutManager(getContext(), columns));
if (mRecyclerView.getItemDecorationCount() == 0) {