Skip to content

Commit 720698d

Browse files
committed
Align fullscreen feature implementation
1 parent 3f43fab commit 720698d

4 files changed

Lines changed: 7 additions & 4 deletions

File tree

platforms/shared/desktop/application.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,14 +218,17 @@ void application_trigger_fullscreen(bool fullscreen)
218218
}
219219
else
220220
{
221-
// Desktop fullscreen: no display mode
221+
// Borderless fullscreen (default): pass NULL for desktop fullscreen
222222
SDL_SetWindowFullscreenMode(application_sdl_window, NULL);
223223
}
224+
224225
SDL_SetWindowFullscreen(application_sdl_window, true);
226+
SDL_ERROR("SDL_SetWindowFullscreen");
225227
}
226228
else
227229
{
228230
SDL_SetWindowFullscreen(application_sdl_window, false);
231+
SDL_ERROR("SDL_SetWindowFullscreen");
229232
}
230233
config_emulator.fullscreen = fullscreen;
231234
#endif

platforms/shared/desktop/config.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ void config_read(void)
258258

259259
config_emulator.maximized = read_bool("Emulator", "Maximized", false);
260260
config_emulator.fullscreen = read_bool("Emulator", "FullScreen", false);
261-
config_emulator.fullscreen_mode = read_int("Emulator", "FullScreenMode", 1);
261+
config_emulator.fullscreen_mode = read_int("Emulator", "FullScreenMode", 0);
262262
config_emulator.always_show_menu = read_bool("Emulator", "AlwaysShowMenu", false);
263263
config_emulator.theme = read_int("Emulator", "Theme", config_Theme_Dark);
264264
config_emulator.theme = CLAMP(config_emulator.theme, config_Theme_Light, config_Theme_Dark);

platforms/shared/desktop/config.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ struct config_Emulator
5454
{
5555
bool maximized = false;
5656
bool fullscreen = false;
57-
int fullscreen_mode = 1;
57+
int fullscreen_mode = 0;
5858
bool always_show_menu = false;
5959
int theme = config_Theme_Dark;
6060
bool paused = false;

platforms/shared/desktop/gui_menus.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -683,7 +683,7 @@ static void menu_video(void)
683683
if (ImGui::BeginMenu("Fullscreen Mode"))
684684
{
685685
ImGui::PushItemWidth(130.0f);
686-
ImGui::Combo("##fullscreen_mode", &config_emulator.fullscreen_mode, "Full Screen Desktop\0Full Screen\0\0");
686+
ImGui::Combo("##fullscreen_mode", &config_emulator.fullscreen_mode, "Borderless\0Exclusive\0\0");
687687
ImGui::PopItemWidth();
688688
ImGui::EndMenu();
689689
}

0 commit comments

Comments
 (0)