summaryrefslogtreecommitdiffstats
path: root/src/app/app.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/app/app.cpp')
-rw-r--r--src/app/app.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/app/app.cpp b/src/app/app.cpp
index d6fc2dd..c703d7f 100644
--- a/src/app/app.cpp
+++ b/src/app/app.cpp
@@ -873,6 +873,13 @@ Event CApplication::ProcessSystemEvent()
{
event.type = EVENT_QUIT;
}
+ else if ( m_private->currentEvent.type == SDL_VIDEORESIZE ) {
+ m_deviceConfig.size.x = m_private->currentEvent.resize.w;
+ m_deviceConfig.size.y = m_private->currentEvent.resize.h;
+ CreateVideoSurface();
+ // FIXME: dirty hack, will fail with device other than OpenGL
+ dynamic_cast<Gfx::CGLDevice*>(m_device)->ResizeViewport(m_deviceConfig.size.x, m_deviceConfig.size.y);
+ }
else if ( (m_private->currentEvent.type == SDL_KEYDOWN) ||
(m_private->currentEvent.type == SDL_KEYUP) )
{