diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/tv/TvPipKeepClearAlgorithm.kt b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/tv/TvPipKeepClearAlgorithm.kt index 239ea38e1e9c3..4e8e71bd04c4c 100644 --- a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/tv/TvPipKeepClearAlgorithm.kt +++ b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/tv/TvPipKeepClearAlgorithm.kt @@ -416,7 +416,7 @@ class TvPipKeepClearAlgorithm(private val clock: () -> Long) { return stashCandidates.minByOrNull { val dx = abs(it.left - bounds.left) val dy = abs(it.top - bounds.top) - dx * bounds.height() + dy * bounds.width() + return@minByOrNull dx + dy }!! }