From c6e4d6a333c5c06f5db70ffefe92429ed2c31052 Mon Sep 17 00:00:00 2001 From: "alexey.lysiuk" Date: Mon, 18 Jun 2018 22:53:19 +0300 Subject: [PATCH] - implemented fullscreen toggle in SDL backend Made window resizable but its size and position are not saved yet --- src/posix/sdl/sdlglvideo.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/posix/sdl/sdlglvideo.cpp b/src/posix/sdl/sdlglvideo.cpp index ca3fe34d89..83f0b1baea 100644 --- a/src/posix/sdl/sdlglvideo.cpp +++ b/src/posix/sdl/sdlglvideo.cpp @@ -217,7 +217,7 @@ SystemFrameBuffer::SystemFrameBuffer (void *, bool fullscreen) Screen = SDL_CreateWindow (caption, SDL_WINDOWPOS_UNDEFINED_DISPLAY(vid_adapter), SDL_WINDOWPOS_UNDEFINED_DISPLAY(vid_adapter), - vid_defwidth, vid_defheight, (fullscreen ? SDL_WINDOW_FULLSCREEN_DESKTOP : 0)|SDL_WINDOW_OPENGL + vid_defwidth, vid_defheight, (fullscreen ? SDL_WINDOW_FULLSCREEN_DESKTOP : 0) | SDL_WINDOW_OPENGL | SDL_WINDOW_RESIZABLE ); if (Screen != NULL) { @@ -311,7 +311,7 @@ void SystemFrameBuffer::SwapBuffers() void SystemFrameBuffer::ToggleFullscreen(bool yes) { - ... // todo + SDL_SetWindowFullscreen(Screen, yes ? SDL_WINDOW_FULLSCREEN_DESKTOP : 0); } int SystemFrameBuffer::GetClientWidth()