Fix issue with resizing the display on Android when using the compatibility renderer.

(cherry picked from commit b438b4a490)
This commit is contained in:
Fredia Huya-Kouadio 2023-04-26 00:43:13 -07:00 committed by Yuri Sizov
parent 5120afc236
commit d327bb7a45

View File

@ -199,12 +199,11 @@ 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);
}
}
}
}
JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_newcontext(JNIEnv *env, jclass clazz, jobject p_surface) {