mirror of
https://github.com/isledecomp/isle-portable.git
synced 2026-02-03 12:31:15 +00:00
Different default full screen behavior for Emscripten
This commit is contained in:
parent
eb84da0476
commit
d48ed3749d
@ -94,7 +94,11 @@ IsleApp::IsleApp()
|
||||
m_cdPath = NULL;
|
||||
m_deviceId = NULL;
|
||||
m_savePath = NULL;
|
||||
#ifdef __EMSCRIPTEN__
|
||||
m_fullScreen = FALSE;
|
||||
#else
|
||||
m_fullScreen = TRUE;
|
||||
#endif
|
||||
m_flipSurfaces = FALSE;
|
||||
m_backBuffersInVram = TRUE;
|
||||
m_using8bit = FALSE;
|
||||
|
||||
@ -284,11 +284,6 @@ HRESULT DirectDrawImpl::SetCooperativeLevel(HWND hWnd, DDSCLFlags dwFlags)
|
||||
{
|
||||
SDL_Window* sdlWindow = reinterpret_cast<SDL_Window*>(hWnd);
|
||||
|
||||
#ifdef __EMSCRIPTEN__
|
||||
DDWindow = sdlWindow;
|
||||
return DD_OK;
|
||||
#endif
|
||||
|
||||
if (sdlWindow) {
|
||||
bool fullscreen;
|
||||
if ((dwFlags & DDSCL_NORMAL) == DDSCL_NORMAL) {
|
||||
@ -302,7 +297,9 @@ HRESULT DirectDrawImpl::SetCooperativeLevel(HWND hWnd, DDSCLFlags dwFlags)
|
||||
}
|
||||
|
||||
if (!SDL_SetWindowFullscreen(sdlWindow, fullscreen)) {
|
||||
#ifndef __EMSCRIPTEN__
|
||||
return DDERR_GENERIC;
|
||||
#endif
|
||||
}
|
||||
DDWindow = sdlWindow;
|
||||
DDRenderer = SDL_CreateRenderer(DDWindow, NULL);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user