aboutsummaryrefslogtreecommitdiff
path: root/backends/platform
diff options
context:
space:
mode:
authorMax Horn2011-06-07 10:52:04 +0200
committerMax Horn2011-06-07 14:57:56 +0200
commit886c4e54175317e57880e59eafbbe835ea77f754 (patch)
tree4d95a7d1b3915dad3f6500d922e32d948b6e425e /backends/platform
parent896e7e23b44e5c21e98772c6c193bfe150f8499b (diff)
downloadscummvm-rg350-886c4e54175317e57880e59eafbbe835ea77f754.tar.gz
scummvm-rg350-886c4e54175317e57880e59eafbbe835ea77f754.tar.bz2
scummvm-rg350-886c4e54175317e57880e59eafbbe835ea77f754.zip
DS: Use OSystem's 'slot' for timer manager
Diffstat (limited to 'backends/platform')
-rw-r--r--backends/platform/ds/arm9/source/osystem_ds.cpp7
-rw-r--r--backends/platform/ds/arm9/source/osystem_ds.h3
2 files changed, 3 insertions, 7 deletions
diff --git a/backends/platform/ds/arm9/source/osystem_ds.cpp b/backends/platform/ds/arm9/source/osystem_ds.cpp
index eab9fd6a33..6cc76f51a5 100644
--- a/backends/platform/ds/arm9/source/osystem_ds.cpp
+++ b/backends/platform/ds/arm9/source/osystem_ds.cpp
@@ -42,6 +42,7 @@
#include "backends/fs/ds/ds-fs-factory.h"
#include "backends/audiocd/default/default-audiocd.h"
+#include "backends/timer/default/default-timer.h"
#ifdef ENABLE_AGI
#include "wordcompletion.h"
@@ -81,7 +82,7 @@
OSystem_DS *OSystem_DS::_instance = NULL;
OSystem_DS::OSystem_DS()
- : eventNum(0), lastPenFrame(0), queuePos(0), _mixer(NULL), _timer(NULL), _frameBufferExists(false),
+ : eventNum(0), lastPenFrame(0), queuePos(0), _mixer(NULL), _frameBufferExists(false),
_disableCursorPalette(true), _graphicsEnable(true), _gammaValue(0)
{
// eventNum = 0;
@@ -89,13 +90,11 @@ OSystem_DS::OSystem_DS()
// queuePos = 0;
_instance = this;
// _mixer = NULL;
- // _timer = NULL;
//_frameBufferExists = false;
}
OSystem_DS::~OSystem_DS() {
delete _mixer;
- delete _timer;
}
int OSystem_DS::timerHandler(int t) {
@@ -108,7 +107,7 @@ void OSystem_DS::initBackend() {
ConfMan.setInt("autosave_period", 0);
ConfMan.setBool("FM_medium_quality", true);
- _timer = new DefaultTimerManager();
+ _timerManager = new DefaultTimerManager();
DS::setTimerCallback(&OSystem_DS::timerHandler, 10);
if (ConfMan.hasKey("22khzaudio", "ds") && ConfMan.getBool("22khzaudio", "ds")) {
diff --git a/backends/platform/ds/arm9/source/osystem_ds.h b/backends/platform/ds/arm9/source/osystem_ds.h
index 1e032ba2cf..ad306b5e3b 100644
--- a/backends/platform/ds/arm9/source/osystem_ds.h
+++ b/backends/platform/ds/arm9/source/osystem_ds.h
@@ -29,7 +29,6 @@
#include "nds.h"
#include "gbampsave.h"
#include "backends/saves/default/default-saves.h"
-#include "backends/timer/default/default-timer.h"
#include "audio/mixer_intern.h"
#include "graphics/surface.h"
#include "graphics/colormasks.h"
@@ -46,7 +45,6 @@ protected:
GBAMPSaveFileManager mpSaveManager;
Audio::MixerImpl *_mixer;
- DefaultTimerManager *_timer;
Graphics::Surface _framebuffer;
bool _frameBufferExists;
bool _graphicsEnable;
@@ -159,7 +157,6 @@ public:
virtual Audio::Mixer *getMixer() { return _mixer; }
Audio::MixerImpl *getMixerImpl() { return _mixer; }
- virtual Common::TimerManager *getTimerManager() { return _timer; }
static int timerHandler(int t);