diff options
author | Fabio Battaglia | 2010-10-23 09:30:26 +0000 |
---|---|---|
committer | Fabio Battaglia | 2010-10-23 09:30:26 +0000 |
commit | 74a53df11b51fa4956745c086b2e6351b8383568 (patch) | |
tree | 2ec2ce66310986e6bebdc21582e7e9c5ad3b014c /backends/platform/dingux/dingux.cpp | |
parent | b713beed189b439853be50fa330d06b3275f9713 (diff) | |
download | scummvm-rg350-74a53df11b51fa4956745c086b2e6351b8383568.tar.gz scummvm-rg350-74a53df11b51fa4956745c086b2e6351b8383568.tar.bz2 scummvm-rg350-74a53df11b51fa4956745c086b2e6351b8383568.zip |
DINGUX: fix compilation for the opengl branch
Moved events related code to backends/events/dinguxsdl/*
and move graphics related code to backends/graphics/dinguxsdl/*
Subclass OSystem_POSIX instead of OSystem_SDL
svn-id: r53730
Diffstat (limited to 'backends/platform/dingux/dingux.cpp')
-rw-r--r-- | backends/platform/dingux/dingux.cpp | 40 |
1 files changed, 15 insertions, 25 deletions
diff --git a/backends/platform/dingux/dingux.cpp b/backends/platform/dingux/dingux.cpp index cdf10600ce..98bf51f49c 100644 --- a/backends/platform/dingux/dingux.cpp +++ b/backends/platform/dingux/dingux.cpp @@ -23,35 +23,25 @@ * */ -#include "backends/platform/dingux/dingux.h" - #if defined(DINGUX) -bool OSystem_SDL_Dingux::hasFeature(Feature f) { - return - (f == kFeatureAspectRatioCorrection) || - (f == kFeatureCursorHasPalette); -} - -void OSystem_SDL_Dingux::setFeatureState(Feature f, bool enable) { - switch (f) { - case kFeatureAspectRatioCorrection: - setAspectRatioCorrection(enable); - break; - default: - break; +#include "backends/platform/dingux/dingux.h" +#include "backends/events/dinguxsdl/dinguxsdl-events.h" +#include "backends/graphics/dinguxsdl/dinguxsdl-graphics.h" + +void OSystem_SDL_Dingux::initBackend() { + // Create the events manager + if (_eventSource == 0) + _eventSource = new DINGUXSdlEventSource(); + + // Create the graphics manager + if (_graphicsManager == 0) { + _graphicsManager = new DINGUXSdlGraphicsManager(_eventSource); + ((DINGUXSdlEventSource*)_eventSource)->setCurrentGraphMan((DINGUXSdlGraphicsManager*)_graphicsManager); } -} -bool OSystem_SDL_Dingux::getFeatureState(Feature f) { - assert(_transactionMode == kTransactionNone); - - switch (f) { - case kFeatureAspectRatioCorrection: - return _videoMode.aspectRatioCorrection; - default: - return false; - } + // Call parent implementation of this method + OSystem_POSIX::initBackend(); } #endif |