Ensure we wait on the surface resize before returning from setting fullscreen mode.
This commit is contained in:
parent
c9fd1e0c97
commit
6911c8ca79
4 changed files with 30 additions and 1 deletions
|
@ -19,6 +19,7 @@
|
|||
3. This notice may not be removed or altered from any source distribution.
|
||||
*/
|
||||
#include "../../SDL_internal.h"
|
||||
#include "SDL_system.h"
|
||||
|
||||
/* Set up for C function definitions, even when using C++ */
|
||||
#ifdef __cplusplus
|
||||
|
@ -53,6 +54,10 @@ extern int Android_JNI_CaptureAudioBuffer(void *buffer, int buflen);
|
|||
extern void Android_JNI_FlushCapturedAudio(void);
|
||||
extern void Android_JNI_CloseAudioDevice(const int iscapture);
|
||||
|
||||
/* Detecting device type */
|
||||
extern SDL_bool Android_IsDeXMode();
|
||||
extern SDL_bool Android_IsChromebook();
|
||||
|
||||
#include "SDL_rwops.h"
|
||||
|
||||
int Android_JNI_FileOpen(SDL_RWops* ctx, const char* fileName, const char* mode);
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include "../../events/SDL_keyboard_c.h"
|
||||
#include "../../events/SDL_mouse_c.h"
|
||||
#include "../../events/SDL_windowevents_c.h"
|
||||
#include "../../core/android/SDL_android.h"
|
||||
|
||||
#include "SDL_androidvideo.h"
|
||||
#include "SDL_androidwindow.h"
|
||||
|
@ -109,6 +110,10 @@ Android_SetWindowFullscreen(_THIS, SDL_Window * window, SDL_VideoDisplay * displ
|
|||
// Samsung DeX or Chromebooks or other windowed Android environemtns, our window may
|
||||
// still not be the full display size.
|
||||
//
|
||||
if (!SDL_IsDeXMode() && !SDL_IsChromebook()) {
|
||||
return;
|
||||
}
|
||||
|
||||
SDL_WindowData * data = (SDL_WindowData *)window->driverdata;
|
||||
|
||||
if (!data || !data->native_window) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue