Skip to content

Commit f82bf35

Browse files
authored
Merge pull request #85457 from m4gr3d/fix_android_editor_restart_loop
Fix an issue causing the running project window to loop-restart when closed
2 parents a008a85 + 7cd6041 commit f82bf35

File tree

1 file changed

+3
-10
lines changed
  • platform/android/java/editor/src/main/java/org/godotengine/editor

1 file changed

+3
-10
lines changed

platform/android/java/editor/src/main/java/org/godotengine/editor/GodotEditor.kt

+3-10
Original file line numberDiff line numberDiff line change
@@ -221,16 +221,9 @@ open class GodotEditor : GodotActivity() {
221221
val runningProcesses = activityManager.runningAppProcesses
222222
for (runningProcess in runningProcesses) {
223223
if (runningProcess.processName.endsWith(processNameSuffix)) {
224-
if (targetClass == null) {
225-
// Killing process directly
226-
Log.v(TAG, "Killing Godot process ${runningProcess.processName}")
227-
Process.killProcess(runningProcess.pid)
228-
} else {
229-
// Activity is running; sending a request for self termination.
230-
Log.v(TAG, "Sending force quit request to $targetClass running on process ${runningProcess.processName}")
231-
val forceQuitIntent = Intent(this, targetClass).putExtra(EXTRA_FORCE_QUIT, true)
232-
startActivity(forceQuitIntent)
233-
}
224+
// Killing process directly
225+
Log.v(TAG, "Killing Godot process ${runningProcess.processName}")
226+
Process.killProcess(runningProcess.pid)
234227
return true
235228
}
236229
}

0 commit comments

Comments
 (0)