mirror of
https://github.com/OpenMW/openmw.git
synced 2025-01-16 16:29:55 +00:00
Fixed endless message loop after trying to resize window on OS X
This commit is contained in:
parent
66608d5c92
commit
e552eccaa4
1 changed files with 7 additions and 7 deletions
14
extern/sdl4ogre/sdlinputwrapper.cpp
vendored
14
extern/sdl4ogre/sdlinputwrapper.cpp
vendored
|
@ -119,21 +119,21 @@ namespace SFO
|
||||||
int w,h;
|
int w,h;
|
||||||
SDL_GetWindowSize(mSDLWindow, &w, &h);
|
SDL_GetWindowSize(mSDLWindow, &w, &h);
|
||||||
// TODO: Fix Ogre to handle this more consistently
|
// TODO: Fix Ogre to handle this more consistently
|
||||||
#if OGRE_PLATFORM == OGRE_PLATFORM_WIN32
|
#if OGRE_PLATFORM == OGRE_PLATFORM_LINUX
|
||||||
mOgreWindow->windowMovedOrResized();
|
|
||||||
#else
|
|
||||||
mOgreWindow->resize(w, h);
|
mOgreWindow->resize(w, h);
|
||||||
|
#else
|
||||||
|
mOgreWindow->windowMovedOrResized();
|
||||||
#endif
|
#endif
|
||||||
if (mWindowListener)
|
if (mWindowListener)
|
||||||
mWindowListener->windowResized(evt.window.data1, evt.window.data2);
|
mWindowListener->windowResized(evt.window.data1, evt.window.data2);
|
||||||
|
|
||||||
case SDL_WINDOWEVENT_RESIZED:
|
case SDL_WINDOWEVENT_RESIZED:
|
||||||
// TODO: Fix Ogre to handle this more consistently
|
// TODO: Fix Ogre to handle this more consistently
|
||||||
#if OGRE_PLATFORM == OGRE_PLATFORM_WIN32
|
#if OGRE_PLATFORM == OGRE_PLATFORM_LINUX
|
||||||
mOgreWindow->windowMovedOrResized();
|
|
||||||
#else
|
|
||||||
mOgreWindow->resize(evt.window.data1, evt.window.data2);
|
mOgreWindow->resize(evt.window.data1, evt.window.data2);
|
||||||
#endif
|
#else
|
||||||
|
mOgreWindow->windowMovedOrResized();
|
||||||
|
#endif
|
||||||
if (mWindowListener)
|
if (mWindowListener)
|
||||||
mWindowListener->windowResized(evt.window.data1, evt.window.data2);
|
mWindowListener->windowResized(evt.window.data1, evt.window.data2);
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue