diff options
author | Alejandro Marzini | 2010-09-03 04:23:01 +0000 |
---|---|---|
committer | Alejandro Marzini | 2010-09-03 04:23:01 +0000 |
commit | 91367241102badf06c5955423d95aedf524ed864 (patch) | |
tree | bff602aac9479d0ff7e04e498a3970db228e78cd /backends/graphics/opengl | |
parent | 30cbd35e740b801313be83209eec6956feeb512d (diff) | |
download | scummvm-rg350-91367241102badf06c5955423d95aedf524ed864.tar.gz scummvm-rg350-91367241102badf06c5955423d95aedf524ed864.tar.bz2 scummvm-rg350-91367241102badf06c5955423d95aedf524ed864.zip |
SDL/OPENGL: Fix backend initialization when building with ENABLE_VKEYBD.
svn-id: r52503
Diffstat (limited to 'backends/graphics/opengl')
-rw-r--r-- | backends/graphics/opengl/opengl-graphics.cpp | 8 | ||||
-rw-r--r-- | backends/graphics/opengl/opengl-graphics.h | 2 |
2 files changed, 7 insertions, 3 deletions
diff --git a/backends/graphics/opengl/opengl-graphics.cpp b/backends/graphics/opengl/opengl-graphics.cpp index 187a7aec26..8682c54921 100644 --- a/backends/graphics/opengl/opengl-graphics.cpp +++ b/backends/graphics/opengl/opengl-graphics.cpp @@ -62,9 +62,6 @@ OpenGLGraphicsManager::OpenGLGraphicsManager() _gamePalette = (byte *)calloc(sizeof(byte) * 4, 256); _cursorPalette = (byte *)calloc(sizeof(byte) * 4, 256); - - // Register the graphics manager as a event observer - g_system->getEventManager()->getEventDispatcher()->registerObserver(this, 2, false); } OpenGLGraphicsManager::~OpenGLGraphicsManager() { @@ -83,6 +80,11 @@ OpenGLGraphicsManager::~OpenGLGraphicsManager() { delete _cursorTexture; } +void OpenGLGraphicsManager::initEventObserver() { + // Register the graphics manager as a event observer + g_system->getEventManager()->getEventDispatcher()->registerObserver(this, 10, false); +} + // // Feature // diff --git a/backends/graphics/opengl/opengl-graphics.h b/backends/graphics/opengl/opengl-graphics.h index 460b3806e8..9b3340aef2 100644 --- a/backends/graphics/opengl/opengl-graphics.h +++ b/backends/graphics/opengl/opengl-graphics.h @@ -57,6 +57,8 @@ public: OpenGLGraphicsManager(); virtual ~OpenGLGraphicsManager(); + virtual void initEventObserver(); + virtual bool hasFeature(OSystem::Feature f); virtual void setFeatureState(OSystem::Feature f, bool enable); virtual bool getFeatureState(OSystem::Feature f); |