diff --git a/quickstep/src/com/android/quickstep/util/GestureExclusionManager.kt b/quickstep/src/com/android/quickstep/util/GestureExclusionManager.kt index 5fec62228c..8e97f8f39d 100644 --- a/quickstep/src/com/android/quickstep/util/GestureExclusionManager.kt +++ b/quickstep/src/com/android/quickstep/util/GestureExclusionManager.kt @@ -36,24 +36,30 @@ class GestureExclusionManager(private val windowManager: IWindowManager) { @VisibleForTesting val exclusionListener = object : ISystemGestureExclusionListener.Stub() { - @BinderThread - override fun onSystemGestureExclusionChanged( - displayId: Int, - exclusionRegion: Region?, - unrestrictedOrNull: Region? - ) { - if (displayId != DEFAULT_DISPLAY) { - return - } - Executors.MAIN_EXECUTOR.execute { - lastExclusionRegion = exclusionRegion - lastUnrestrictedOrNull = unrestrictedOrNull - listeners.forEach { - it.onGestureExclusionChanged(exclusionRegion, unrestrictedOrNull) - } + @BinderThread + override fun onSystemGestureExclusionChanged( + displayId: Int, + exclusionRegion: Region?, + unrestrictedOrNull: Region? + ) { + if (displayId != DEFAULT_DISPLAY) { + return + } + Executors.MAIN_EXECUTOR.execute { + lastExclusionRegion = exclusionRegion + lastUnrestrictedOrNull = unrestrictedOrNull + listeners.forEach { + it.onGestureExclusionChanged(exclusionRegion, unrestrictedOrNull) } } } + fun onSystemGestureExclusionChanged( + displayId: Int, + exclusionRegion: Region? + ) { + onSystemGestureExclusionChanged(displayId, exclusionRegion, null) + } + } /** Adds a listener for receiving gesture exclusion regions */ fun addListener(listener: ExclusionListener) {