summaryrefslogtreecommitdiff
path: root/src/graphics.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-08-22 11:59:38 +0300
committerAndrei Karas <akaras@inbox.ru>2013-08-24 21:08:15 +0300
commit2480ea4cc668ff99007dd6fb8b44911eea5d5287 (patch)
treec8fc22a9612d30474cddd6d40da5269ffd7f55a5 /src/graphics.cpp
parent07390a4c8dcde85602c1a91d3773061d67d169ab (diff)
downloadmv-2480ea4cc668ff99007dd6fb8b44911eea5d5287.tar.gz
mv-2480ea4cc668ff99007dd6fb8b44911eea5d5287.tar.bz2
mv-2480ea4cc668ff99007dd6fb8b44911eea5d5287.tar.xz
mv-2480ea4cc668ff99007dd6fb8b44911eea5d5287.zip
store window size into rectangle.
Diffstat (limited to 'src/graphics.cpp')
-rw-r--r--src/graphics.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/graphics.cpp b/src/graphics.cpp
index ac219bc9a..d1d5a9590 100644
--- a/src/graphics.cpp
+++ b/src/graphics.cpp
@@ -148,9 +148,14 @@ bool Graphics::setOpenGLMode()
if (!(mWindow = graphicsManager.createWindow(mWidth, mHeight,
mBpp, getOpenGLFlags())))
{
+ mRect.w = 0;
+ mRect.h = 0;
return false;
}
+ mRect.w = static_cast<uint16_t>(mWindow->w);
+ mRect.h = static_cast<uint16_t>(mWindow->h);
+
#ifdef __APPLE__
if (mSync)
{