COMMON: Remove the EventRecorder dependency from OSystem

EventRecorder is in the gui lib which is not linked in the cxxtest suite.
This commit is contained in:
Bastien Bouclet 2015-10-16 20:26:34 +02:00
parent 823c2f899b
commit ad3ab61241
4 changed files with 10 additions and 8 deletions

View file

@ -492,6 +492,14 @@ AudioCDManager *OSystem_SDL::createAudioCDManager() {
#endif #endif
} }
Common::SaveFileManager *OSystem_SDL::getSavefileManager() {
#ifdef ENABLE_EVENTRECORDER
return g_eventRec.getSaveManager(_savefileManager);
#else
return _savefileManager;
#endif
}
#ifdef USE_OPENGL #ifdef USE_OPENGL
const OSystem::GraphicsMode *OSystem_SDL::getSupportedGraphicsModes() const { const OSystem::GraphicsMode *OSystem_SDL::getSupportedGraphicsModes() const {

View file

@ -76,6 +76,7 @@ public:
virtual void getTimeAndDate(TimeDate &td) const; virtual void getTimeAndDate(TimeDate &td) const;
virtual Audio::Mixer *getMixer(); virtual Audio::Mixer *getMixer();
virtual Common::TimerManager *getTimerManager(); virtual Common::TimerManager *getTimerManager();
virtual Common::SaveFileManager *getSavefileManager();
protected: protected:
bool _inited; bool _inited;

View file

@ -30,9 +30,6 @@
#include "common/taskbar.h" #include "common/taskbar.h"
#include "common/updates.h" #include "common/updates.h"
#include "common/textconsole.h" #include "common/textconsole.h"
#ifdef ENABLE_EVENTRECORDER
#include "gui/EventRecorder.h"
#endif
#include "backends/audiocd/default/default-audiocd.h" #include "backends/audiocd/default/default-audiocd.h"
#include "backends/fs/fs-factory.h" #include "backends/fs/fs-factory.h"
@ -161,9 +158,5 @@ Common::TimerManager *OSystem::getTimerManager() {
} }
Common::SaveFileManager *OSystem::getSavefileManager() { Common::SaveFileManager *OSystem::getSavefileManager() {
#ifdef ENABLE_EVENTRECORDER
return g_eventRec.getSaveManager(_savefileManager);
#else
return _savefileManager; return _savefileManager;
#endif
} }

View file

@ -1090,7 +1090,7 @@ public:
* and other modifiable persistent game data. For more information, * and other modifiable persistent game data. For more information,
* refer to the SaveFileManager documentation. * refer to the SaveFileManager documentation.
*/ */
Common::SaveFileManager *getSavefileManager(); virtual Common::SaveFileManager *getSavefileManager();
#if defined(USE_TASKBAR) #if defined(USE_TASKBAR)
/** /**