Skip to content
Commit 5a7e9e63 authored by Caitlin Shkuratov's avatar Caitlin Shkuratov
Browse files

[Media TTT] Use a listener pattern to notify about view removals.

In order to handle the swipe-to-dismiss gesture correctly, we need to
notify MediaTttSenderCoordinator about both a view timing out, and a
view being removed due to swipe. So, having the `onViewTimeout` Runnable
will no longer work.

This CL instead uses a listener interface to notify
`MediaTttSenderCoordinator` whenever the view has timed out / been
removed. A future CL will add the swipe-to-dismiss gesture. That gesture
will also trigger this new listener method, so that
MediaTttSenderCoordinator always stays up-to-date.

Bug: 262584940
Test: manual: verify media ttt chipbars with different IDs still works
(id1=triggered, then id2=almostClose. When id2 times out, id1 is
redisplayed, then also times out)
Test: atest MediaTttSenderCoordinatorTest
TemporaryViewDisplayControllerTest

Change-Id: I73c6235718f3b660ea416ca459ae777d8624a7be
parent a2d811ed
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment