Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit a07fa827 authored by William Xiao's avatar William Xiao
Browse files

Fix UMO not showing on glanceable hub

The UMO is only shown in the hub if our MediaHost visible state is
true. The visible state reflects many factors, including whether or not
media is playing and the state of the "Show media on lock screen"
setting.

MediaHost listens for updates to media play/pause state upon creation
or when the glanceable hub UMO view is attached, but stops listeneing
when the view is detached, ie. the hub is closed. This means that if
the user opens the hub while the UMO is playing then dismisses the
media session, the hub UMO visibility will be stuck as false. Other UMO
locations do not have this issue as they do not ever detach the UMO
view.

This change forces a visibility state update whenever the value is
requested for the hub so that the value is fresh when the hub opens.

Bug: 354731260
Bug: 339085881
Fix: 354731260
Test: atest CommunalViewModelTest
      also manually verified on device, see bug for repro steps
Flag: com.android.systemui.communal_hub
Change-Id: I22ef39a99678acda87d52d6f62ea950982eb3171
parent ec6079d5
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