diff --git a/ISLE/isleapp.cpp b/ISLE/isleapp.cpp index a5edd95b..591b1e2e 100644 --- a/ISLE/isleapp.cpp +++ b/ISLE/isleapp.cpp @@ -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; diff --git a/miniwin/src/ddraw/ddraw.cpp b/miniwin/src/ddraw/ddraw.cpp index 6842c7ac..fc81ddd3 100644 --- a/miniwin/src/ddraw/ddraw.cpp +++ b/miniwin/src/ddraw/ddraw.cpp @@ -284,11 +284,6 @@ HRESULT DirectDrawImpl::SetCooperativeLevel(HWND hWnd, DDSCLFlags dwFlags) { SDL_Window* sdlWindow = reinterpret_cast(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);