summaryrefslogtreecommitdiff
path: root/platform/android
diff options
context:
space:
mode:
authorFredia Huya-Kouadio <fhuyakou@gmail.com>2023-04-26 00:43:13 -0700
committerYuri Sizov <yuris@humnom.net>2023-04-26 14:51:00 +0200
commitd327bb7a45212662254ba03e494c637603dadfda (patch)
treef77a6cb3e61ded35cf294d8ad08116db191185bc /platform/android
parent5120afc236c9d6425bc77ea03c93a7a5d5169a08 (diff)
Fix issue with resizing the display on Android when using the compatibility renderer.
(cherry picked from commit b438b4a490f81e06c4d850ddd19884b554307018)
Diffstat (limited to 'platform/android')
-rw-r--r--platform/android/java_godot_lib_jni.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/platform/android/java_godot_lib_jni.cpp b/platform/android/java_godot_lib_jni.cpp
index 1a0087e18d..6b94e75a2c 100644
--- a/platform/android/java_godot_lib_jni.cpp
+++ b/platform/android/java_godot_lib_jni.cpp
@@ -199,10 +199,9 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_resize(JNIEnv *env, j
if (p_surface) {
ANativeWindow *native_window = ANativeWindow_fromSurface(env, p_surface);
os_android->set_native_window(native_window);
-
- DisplayServerAndroid::get_singleton()->reset_window();
- DisplayServerAndroid::get_singleton()->notify_surface_changed(p_width, p_height);
}
+ DisplayServerAndroid::get_singleton()->reset_window();
+ DisplayServerAndroid::get_singleton()->notify_surface_changed(p_width, p_height);
}
}
}