Improved the messaging transformation
The messaging layout now transforms smoothly between
the different views.
Test: manual, send messages really fast, expand, collapse
Bug: 63708826
Change-Id: I79da4092eb03fb41a1963b566602386b25141192
diff --git a/core/java/com/android/internal/widget/MessagingLinearLayout.java b/core/java/com/android/internal/widget/MessagingLinearLayout.java
index 7a7447a..f33efff 100644
--- a/core/java/com/android/internal/widget/MessagingLinearLayout.java
+++ b/core/java/com/android/internal/widget/MessagingLinearLayout.java
@@ -53,6 +53,7 @@
* {@link #NOT_MEASURED_BEFORE} if this is the first layout pass.
*/
private int mLastMeasuredWidth = NOT_MEASURED_BEFORE;
+ private MessagingLayout mMessagingLayout;
public MessagingLinearLayout(Context context, @Nullable AttributeSet attrs) {
super(context, attrs);
@@ -258,6 +259,14 @@
mMaxDisplayedLines = numberLines;
}
+ public void setMessagingLayout(MessagingLayout layout) {
+ mMessagingLayout = layout;
+ }
+
+ public MessagingLayout getMessagingLayout() {
+ return mMessagingLayout;
+ }
+
public interface MessagingChild {
int MEASURED_NORMAL = 0;
int MEASURED_SHORTENED = 1;