diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/render/MediaContainerController.kt b/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/render/MediaContainerController.kt index 560e277a9dc27..f949af0688be1 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/render/MediaContainerController.kt +++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/render/MediaContainerController.kt @@ -36,7 +36,7 @@ class MediaContainerController @Inject constructor( fun reinflateView(parent: ViewGroup) { var oldPos = -1 mediaContainerView?.let { _view -> - _view.transientContainer?.removeView(_view) + _view.removeFromTransientContainer() if (_view.parent === parent) { oldPos = parent.indexOfChild(_view) parent.removeView(_view) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/render/SectionHeaderController.kt b/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/render/SectionHeaderController.kt index 8c15647c50389..4e9017e05ecd5 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/render/SectionHeaderController.kt +++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/render/SectionHeaderController.kt @@ -60,7 +60,7 @@ internal class SectionHeaderNodeControllerImpl @Inject constructor( override fun reinflateView(parent: ViewGroup) { var oldPos = -1 _view?.let { _view -> - _view.transientContainer?.removeView(_view) + _view.removeFromTransientContainer() if (_view.parent === parent) { oldPos = parent.indexOfChild(_view) parent.removeView(_view)