Skip to content

Commit

Permalink
force set minimum size for fullscreen mode
Browse files Browse the repository at this point in the history
  • Loading branch information
mariotaku committed Mar 17, 2024
1 parent 4d9a621 commit d08e2f0
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/app/ui/root.c
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,11 @@ SDL_Window *app_ui_create_window(app_ui_t *ui) {
(int) lv_sdl_img_data_logo_96.data_len), SDL_TRUE);
SDL_SetWindowIcon(win, winicon);
SDL_FreeSurface(winicon);
SDL_SetWindowMinimumSize(win, 640, 480);
if (app_configuration->fullscreen) {
SDL_SetWindowMinimumSize(win, win_width, win_height);
} else {
SDL_SetWindowMinimumSize(win, 640, 480);
}
int w = 0, h = 0;
SDL_GetWindowSize(win, &w, &h);
SDL_assert_release(w > 0 && h > 0);
Expand Down

0 comments on commit d08e2f0

Please sign in to comment.