From b64ff1d09e19263dff758573276f9cb575a6653a Mon Sep 17 00:00:00 2001 From: Kavish Devar Date: Tue, 28 Apr 2026 12:04:59 +0530 Subject: [PATCH] android: catch exceptions when closing IslandWindow --- .../librepods/presentation/overlays/IslandWindow.kt | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/android/app/src/main/java/me/kavishdevar/librepods/presentation/overlays/IslandWindow.kt b/android/app/src/main/java/me/kavishdevar/librepods/presentation/overlays/IslandWindow.kt index 90ad166..bb68876 100644 --- a/android/app/src/main/java/me/kavishdevar/librepods/presentation/overlays/IslandWindow.kt +++ b/android/app/src/main/java/me/kavishdevar/librepods/presentation/overlays/IslandWindow.kt @@ -712,8 +712,16 @@ class IslandWindow(private val context: Context) { } isClosing = false // Make sure all animations are canceled - springAnimation.cancel() - flingAnimator.cancel() + try { + springAnimation.cancel() + } catch (e: Exception) { + e("IslandWindow", "Error cancelling spring animation $e") + } + try { + flingAnimator.cancel() + } catch (e: Exception) { + e("IslandWindow", "Error cancelling fling animation $e") + } } fun forceClose() {