summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRémi Verschelde <remi@verschelde.fr>2023-11-28 08:22:14 +0100
committerGitHub <noreply@github.com>2023-11-28 08:22:14 +0100
commitd6dd1de64409a74e27abc92d5756799c0b60b630 (patch)
tree1f3cb85b99976d600471d0da896db3f0960d896a
parenteda44bfe109d7f15c5a965db2d65c8a17ce4b7d0 (diff)
parent1e4af5269fd5d01188e88bd05116ffaf93ff89ad (diff)
downloadredot-engine-d6dd1de64409a74e27abc92d5756799c0b60b630.tar.gz
Merge pull request #85454 from m4gr3d/fix_android_freeze_on_close
Fix issue causing Godot Android apps / games to freeze on close
-rw-r--r--platform/android/java/lib/src/org/godotengine/godot/Godot.kt7
1 files changed, 5 insertions, 2 deletions
diff --git a/platform/android/java/lib/src/org/godotengine/godot/Godot.kt b/platform/android/java/lib/src/org/godotengine/godot/Godot.kt
index 38961bcda8..2278b46f6c 100644
--- a/platform/android/java/lib/src/org/godotengine/godot/Godot.kt
+++ b/platform/android/java/lib/src/org/godotengine/godot/Godot.kt
@@ -536,8 +536,11 @@ class Godot(private val context: Context) : SensorEventListener {
for (plugin in pluginRegistry.allPlugins) {
plugin.onMainDestroy()
}
- GodotLib.ondestroy()
- forceQuit()
+
+ runOnRenderThread {
+ GodotLib.ondestroy()
+ forceQuit()
+ }
}
/**