diff options
Diffstat (limited to 'common')
-rw-r--r-- | common/keyboard.h | 2 | ||||
-rw-r--r-- | common/scummsys.h | 7 | ||||
-rw-r--r-- | common/system.cpp | 8 | ||||
-rw-r--r-- | common/system.h | 49 | ||||
-rw-r--r-- | common/timer.h | 1 |
5 files changed, 22 insertions, 45 deletions
diff --git a/common/keyboard.h b/common/keyboard.h index 0a336c3ca5..8f93fed91c 100644 --- a/common/keyboard.h +++ b/common/keyboard.h @@ -281,7 +281,7 @@ struct KeyState { * you can write * if (keystate.flags & KBD_CTRL) { ... } */ - bool hasFlags(byte f) { + bool hasFlags(byte f) const { return f == (flags & ~(KBD_NUM|KBD_CAPS|KBD_SCRL)); } diff --git a/common/scummsys.h b/common/scummsys.h index 3acf3b4b3b..71873ee4e6 100644 --- a/common/scummsys.h +++ b/common/scummsys.h @@ -334,6 +334,13 @@ #define SCUMM_BIG_ENDIAN #define SCUMM_NEED_ALIGNMENT +#ifdef KEYCODE_LESS + #undef KEYCODE_LESS +#endif +#ifdef KEYCODE_GREATER + #undef KEYCODE_GREATER +#endif + #elif defined (__DS__) #define scumm_stricmp stricmp diff --git a/common/system.cpp b/common/system.cpp index 387e0dfa0f..816d444c89 100644 --- a/common/system.cpp +++ b/common/system.cpp @@ -53,11 +53,3 @@ bool OSystem::setGraphicsMode(const char *name) { return false; } - -bool OSystem::openCD(int drive) { - return false; -} - -bool OSystem::pollCD() { - return false; -} diff --git a/common/system.h b/common/system.h index 0ff841e441..a11adb4134 100644 --- a/common/system.h +++ b/common/system.h @@ -33,6 +33,8 @@ #include "graphics/pixelformat.h" +#include "backends/audiocd/audiocd.h" + namespace Audio { class Mixer; } @@ -354,6 +356,13 @@ public: */ virtual int getGraphicsMode() const = 0; + /** + * Sets the graphics scale factor to x1. Games with large screen sizes + * reset the scale to x1 so the screen will not be too big when starting + * the game. + */ + virtual void resetGraphicsScale() = 0; + #ifdef USE_RGB_COLOR /** * Determine the pixel format currently in use for screen rendering. @@ -926,46 +935,14 @@ public: - /** - * @name Audio CD - * The methods in this group deal with Audio CD playback. - * The default implementation simply does nothing. - * This is the lower level implementation as provided by the - * backends. The engines should use the Audio::AudioCDManager - * class instead of using it directly. - */ + /** @name Audio CD */ //@{ /** - * Initialise the specified CD drive for audio playback. - * @return true if the CD drive was inited succesfully - */ - virtual bool openCD(int drive); - - /** - * Poll CD status. - * @return true if CD audio is playing - */ - virtual bool pollCD(); - - /** - * Start audio CD playback. - * @param track the track to play. - * @param num_loops how often playback should be repeated (-1 = infinitely often). - * @param start_frame the frame at which playback should start (75 frames = 1 second). - * @param duration the number of frames to play. - */ - virtual void playCD(int track, int num_loops, int start_frame, int duration) {} - - /** - * Stop audio CD playback. - */ - virtual void stopCD() {} - - /** - * Update cdrom audio status. + * Return the audio cd manager. For more information, refer to the + * AudioCDManager documentation. */ - virtual void updateCD() {} + virtual AudioCDManager *getAudioCDManager() = 0; //@} diff --git a/common/timer.h b/common/timer.h index c87c2b3240..3a48875842 100644 --- a/common/timer.h +++ b/common/timer.h @@ -26,6 +26,7 @@ #define COMMON_TIMER_H #include "common/scummsys.h" +#include "common/system.h" #include "common/noncopyable.h" namespace Common { |