Browse Source

Enable fullscreen

Window mode can be set by providing -x at the command line
pull/25/head
Anders Jenbo 7 years ago
parent
commit
46ec65bcb2
  1. 6
      Stub/DiabloUI/sdlrender.cpp

6
Stub/DiabloUI/sdlrender.cpp

@ -190,7 +190,11 @@ void SdlDiabloMainWindow()
atexit(TTF_Quit);
SDL_Init(SDL_INIT_EVERYTHING);
window = SDL_CreateWindow("Diablo", SDL_WINDOWPOS_UNDEFINED, SDL_WINDOWPOS_UNDEFINED, SCREEN_WIDTH, SCREEN_HEIGHT, SDL_WINDOW_RESIZABLE);
int flags = SDL_WINDOW_FULLSCREEN_DESKTOP;
if (!fullscreen) {
flags = SDL_WINDOW_RESIZABLE;
}
window = SDL_CreateWindow("Diablo", SDL_WINDOWPOS_UNDEFINED, SDL_WINDOWPOS_UNDEFINED, SCREEN_WIDTH, SCREEN_HEIGHT, flags);
renderer = SDL_CreateRenderer(window, -1, SDL_RENDERER_PRESENTVSYNC);
printf("Window And Renderer Created!\n");

Loading…
Cancel
Save