Fixed an issue where the result wasn't set properly

Bug: 154137987
Test: add media notificaiton, observe right measuring from the start
Change-Id: Ia7cf7675c3b41e113811284b622a40967ed59238
This commit is contained in:
Selim Cinek
2020-05-14 21:15:04 -07:00
parent 8ae0cfe36b
commit 67867790f3

View File

@@ -289,7 +289,7 @@ class MediaViewManager @Inject constructor(
firstPlayer.measure(input)
// Relayouting is necessary in motionlayout to obtain its size properly ....
it.layout(0, 0, it.measuredWidth, it.measuredHeight)
val result = MeasurementOutput(it.measuredWidth, it.measuredHeight)
result = MeasurementOutput(it.measuredWidth, it.measuredHeight)
it.progress = previousProgress
if (desiredState != null) {
// remeasure it to the old size again!