From c2d8a6fbeba27a125cf3e2581d762c8c58a8e6d1 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sat, 21 Apr 2012 15:34:30 +0300 Subject: Extract SDL video info to separate method. --- src/graphics.cpp | 5 +++++ src/graphics.h | 2 ++ 2 files changed, 7 insertions(+) diff --git a/src/graphics.cpp b/src/graphics.cpp index 3b2ec1fd8..3689aa0f9 100644 --- a/src/graphics.cpp +++ b/src/graphics.cpp @@ -105,6 +105,11 @@ bool Graphics::setVideoMode(int w, int h, int bpp, bool fs, mRect.w = mTarget->w; mRect.h = mTarget->h; + return videoInfo(); +} + +bool Graphics::videoInfo() +{ char videoDriverName[65]; if (SDL_VideoDriverName(videoDriverName, 64)) diff --git a/src/graphics.h b/src/graphics.h index 35316ab57..0955bf6d7 100644 --- a/src/graphics.h +++ b/src/graphics.h @@ -293,6 +293,8 @@ class Graphics : public gcn::SDLGraphics void setNoFrame(bool n) { mNoFrame = n; } + bool videoInfo(); + int mWidth; int mHeight; -- cgit v1.2.3-60-g2f50