Merge "Remove unused scaffolding for partial shelf overflow" into tm-qpr-dev am: 254acc56c1

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

Change-Id: I0b9c14b8da60fdbbff007cd7e8808f7d47be6db2
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Lyn Han
2022-10-26 18:00:19 +00:00
committed by Automerger Merge Worker

View File

@@ -649,37 +649,6 @@ public class NotificationIconContainer extends ViewGroup {
return mNumDots > 0;
}
/**
* If the overflow is in the range [1, max_dots - 1) (basically 1 or 2 dots), then
* extra padding will have to be accounted for
*
* This method has no meaning for non-static containers
*/
public boolean hasPartialOverflow() {
return mNumDots > 0 && mNumDots < MAX_DOTS;
}
/**
* Get padding that can account for extra dots up to the max. The only valid values for
* this method are for 1 or 2 dots.
* @return only extraDotPadding or extraDotPadding * 2
*/
public int getPartialOverflowExtraPadding() {
if (!hasPartialOverflow()) {
return 0;
}
int partialOverflowAmount = (MAX_DOTS - mNumDots) * (mStaticDotDiameter + mDotPadding);
int adjustedWidth = getFinalTranslationX() + partialOverflowAmount;
// In case we actually give too much padding...
if (adjustedWidth > getWidth()) {
partialOverflowAmount = getWidth() - getFinalTranslationX();
}
return partialOverflowAmount;
}
// Give some extra room for btw notifications if we can
public int getNoOverflowExtraPadding() {
if (mNumDots != 0) {