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
This commit is contained in:
parent
b713beed18
commit
74a53df11b
11 changed files with 241 additions and 109 deletions
|
@ -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);
|
||||
}
|
||||
#include "backends/platform/dingux/dingux.h"
|
||||
#include "backends/events/dinguxsdl/dinguxsdl-events.h"
|
||||
#include "backends/graphics/dinguxsdl/dinguxsdl-graphics.h"
|
||||
|
||||
void OSystem_SDL_Dingux::setFeatureState(Feature f, bool enable) {
|
||||
switch (f) {
|
||||
case kFeatureAspectRatioCorrection:
|
||||
setAspectRatioCorrection(enable);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
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
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue