Don't scale textViews when transforming if their text isn't equal
Change-Id: I34f8299790da84edbfdb1e3679181d68023a24ff
Fixes: 79876736
Test: add group, observe normal scaling when dragging down
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/TextViewTransformState.java b/packages/SystemUI/src/com/android/systemui/statusbar/notification/TextViewTransformState.java
index 178c813..c1ffc22 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/TextViewTransformState.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/TextViewTransformState.java
@@ -35,9 +35,7 @@
@Override
public void initFrom(View view, TransformInfo transformInfo) {
super.initFrom(view, transformInfo);
- if (view instanceof TextView) {
- mText = (TextView) view;
- }
+ mText = (TextView) view;
}
@Override
@@ -94,6 +92,9 @@
return false;
}
TextViewTransformState otherTvs = (TextViewTransformState) otherState;
+ if (!TextUtils.equals(mText.getText(), otherTvs.mText.getText())) {
+ return false;
+ }
int lineCount = mText.getLineCount();
return lineCount == 1 && lineCount == otherTvs.mText.getLineCount()
&& getEllipsisCount() == otherTvs.getEllipsisCount()