diff options
Diffstat (limited to 'src/graphicsmanager.cpp')
-rw-r--r-- | src/graphicsmanager.cpp | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/src/graphicsmanager.cpp b/src/graphicsmanager.cpp index 30d50340a..0770332d9 100644 --- a/src/graphicsmanager.cpp +++ b/src/graphicsmanager.cpp @@ -408,18 +408,15 @@ void GraphicsManager::setVideoMode() } } +#ifdef USE_SDL2 SDL_Window *GraphicsManager::createWindow(const int w, const int h, - const int bpp, const int flags) + const int bpp A_UNUSED, + const int flags) { -#ifdef USE_SDL2 return SDL_CreateWindow("ManaPlus", SDL_WINDOWPOS_UNDEFINED, SDL_WINDOWPOS_UNDEFINED, w, h, flags); -#else - return SDL_SetVideoMode(w, h, bpp, flags); -#endif } -#ifdef USE_SDL2 SDL_Renderer *GraphicsManager::createRenderer(SDL_Window *const window, const int flags) { @@ -428,6 +425,12 @@ SDL_Renderer *GraphicsManager::createRenderer(SDL_Window *const window, SDL_SetRenderDrawBlendMode(renderer, SDL_BLENDMODE_BLEND); return renderer; } +#else +SDL_Window *GraphicsManager::createWindow(const int w, const int h, + const int bpp, const int flags) +{ + return SDL_SetVideoMode(w, h, bpp, flags); +} #endif #ifdef USE_OPENGL |