Fix cropping by allowing layerType to be reset regardless of height.

Fixes: 187948073
Test: Open a reply, begin collapsing the shade, then let spring back, notice that bottom of notification is longer truncated.
Change-Id: I126dee8f1e7b422d6a43d49c1a8c4e052e9f009b
This commit is contained in:
Jeff DeCew
2021-06-09 14:54:22 -04:00
parent 6c9c6cb626
commit 46961cd90a

View File

@@ -488,7 +488,8 @@ public abstract class ExpandableView extends FrameLayout implements Dumpable {
@Override
public void setLayerType(int layerType, Paint paint) {
if (hasOverlappingRendering()) {
// Allow resetting the layerType to NONE regardless of overlappingRendering
if (layerType == LAYER_TYPE_NONE || hasOverlappingRendering()) {
super.setLayerType(layerType, paint);
}
}