Loading packages/SystemUI/src/com/android/systemui/keyguard/ui/preview/KeyguardPreviewRenderer.kt +7 −2 Original line number Diff line number Diff line Loading @@ -124,8 +124,9 @@ constructor( ) { private var host: SurfaceControlViewHost private var _surfacePackage: SurfaceControlViewHost.SurfacePackage? = null val surfacePackage: SurfaceControlViewHost.SurfacePackage get() = checkNotNull(host.surfacePackage) get() = _surfacePackage ?: checkNotNull(host.surfacePackage).also { _surfacePackage = it } private var smartSpaceView: View? = null private var largeDateView: View? = null Loading Loading @@ -155,7 +156,11 @@ constructor( previewViewModel.hostToken?.let { InputTransferToken(it) }, TAG, ) disposables += DisposableHandle { host.release() } disposables += DisposableHandle { _surfacePackage?.release() _surfacePackage = null host.release() } } } Loading Loading
packages/SystemUI/src/com/android/systemui/keyguard/ui/preview/KeyguardPreviewRenderer.kt +7 −2 Original line number Diff line number Diff line Loading @@ -124,8 +124,9 @@ constructor( ) { private var host: SurfaceControlViewHost private var _surfacePackage: SurfaceControlViewHost.SurfacePackage? = null val surfacePackage: SurfaceControlViewHost.SurfacePackage get() = checkNotNull(host.surfacePackage) get() = _surfacePackage ?: checkNotNull(host.surfacePackage).also { _surfacePackage = it } private var smartSpaceView: View? = null private var largeDateView: View? = null Loading Loading @@ -155,7 +156,11 @@ constructor( previewViewModel.hostToken?.let { InputTransferToken(it) }, TAG, ) disposables += DisposableHandle { host.release() } disposables += DisposableHandle { _surfacePackage?.release() _surfacePackage = null host.release() } } } Loading