Fix media switch slice doesn't display in panel

Fixes: 140396725
Test: manual
Change-Id: Idf0b766ce5f4316ff90a23faf3083cdee9854562
This commit is contained in:
Raff Tsai
2019-09-03 18:40:42 +08:00
parent d8a94e751e
commit ad004e9beb
3 changed files with 18 additions and 5 deletions

View File

@@ -117,7 +117,7 @@ public class PanelSlicesAdapter
// Do not show the divider above media devices switcher slice per request
final Slice slice = sliceLiveData.getValue();
if (slice != null && slice.getUri().equals(MEDIA_OUTPUT_INDICATOR_SLICE_URI)) {
if (slice == null || slice.getUri().equals(MEDIA_OUTPUT_INDICATOR_SLICE_URI)) {
mDividerAllowedAbove = false;
}