From: Ingo Ruhnke Date: Thu, 15 May 2008 07:08:19 +0000 (+0000) Subject: Do not change video mode when changing fullscreen-res setting X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=07ed4c2b80f0bff52fe86cd62acf718b12455962;p=supertux.git Do not change video mode when changing fullscreen-res setting SVN-Revision: 5481 --- diff --git a/src/options_menu.cpp b/src/options_menu.cpp index d94402ef3..9c73bb1f2 100644 --- a/src/options_menu.cpp +++ b/src/options_menu.cpp @@ -247,8 +247,7 @@ OptionsMenu::menu_action(MenuItem* item) case MNID_FULLSCREEN_RESOLUTION: if(sscanf(item->list[item->selected].c_str(), "%dx%d", &config->fullscreen_width, &config->fullscreen_height) == 2) { - Renderer::instance()->apply_config(); - Menu::recalc_pos(); + // do nothing, changes are only applied when toggling fullscreen mode } break; diff --git a/src/video/gl_renderer.cpp b/src/video/gl_renderer.cpp index 79c6a6c39..764f061c4 100644 --- a/src/video/gl_renderer.cpp +++ b/src/video/gl_renderer.cpp @@ -509,6 +509,8 @@ Renderer::flip() void Renderer::resize(int w, int h) { + // This causes the screen to go black, which is annoying, but seems + // unavoidable with SDL at the moment SDL_SetVideoMode(w, h, 0, SDL_OPENGL | SDL_RESIZABLE); config->window_width = w;