diff options
author | Max Horn | 2011-06-04 00:14:09 +0200 |
---|---|---|
committer | Max Horn | 2011-06-04 11:55:56 +0200 |
commit | ce32745d9c26a0b97dce6a137a46ff2004c7be02 (patch) | |
tree | bbf618410aa42cd69b0a140de7fb225a9f769ada /backends/graphics/sdl | |
parent | 6575cd195bef842697ea0b0ec80c3c1aa91f58e5 (diff) | |
download | scummvm-rg350-ce32745d9c26a0b97dce6a137a46ff2004c7be02.tar.gz scummvm-rg350-ce32745d9c26a0b97dce6a137a46ff2004c7be02.tar.bz2 scummvm-rg350-ce32745d9c26a0b97dce6a137a46ff2004c7be02.zip |
BACKENDS: Replace OSystem::disableCursorPalette by setFeatureState calls
Diffstat (limited to 'backends/graphics/sdl')
-rw-r--r-- | backends/graphics/sdl/sdl-graphics.cpp | 13 | ||||
-rw-r--r-- | backends/graphics/sdl/sdl-graphics.h | 1 |
2 files changed, 7 insertions, 7 deletions
diff --git a/backends/graphics/sdl/sdl-graphics.cpp b/backends/graphics/sdl/sdl-graphics.cpp index 8bc59a9200..ab09c3e44e 100644 --- a/backends/graphics/sdl/sdl-graphics.cpp +++ b/backends/graphics/sdl/sdl-graphics.cpp @@ -235,6 +235,10 @@ void SdlGraphicsManager::setFeatureState(OSystem::Feature f, bool enable) { case OSystem::kFeatureAspectRatioCorrection: setAspectRatioCorrection(enable); break; + case OSystem::kFeatureCursorPalette: + _cursorPaletteDisabled = !enable; + blitCursor(); + break; case OSystem::kFeatureIconifyWindow: if (enable) SDL_WM_IconifyWindow(); @@ -245,13 +249,15 @@ void SdlGraphicsManager::setFeatureState(OSystem::Feature f, bool enable) { } bool SdlGraphicsManager::getFeatureState(OSystem::Feature f) { - assert (_transactionMode == kTransactionNone); + assert(_transactionMode == kTransactionNone); switch (f) { case OSystem::kFeatureFullscreenMode: return _videoMode.fullscreen; case OSystem::kFeatureAspectRatioCorrection: return _videoMode.aspectRatioCorrection; + case OSystem::kFeatureCursorPalette: + return !_cursorPaletteDisabled; default: return false; } @@ -1458,11 +1464,6 @@ void SdlGraphicsManager::setCursorPalette(const byte *colors, uint start, uint n blitCursor(); } -void SdlGraphicsManager::disableCursorPalette(bool disable) { - _cursorPaletteDisabled = disable; - blitCursor(); -} - void SdlGraphicsManager::setShakePos(int shake_pos) { assert (_transactionMode == kTransactionNone); diff --git a/backends/graphics/sdl/sdl-graphics.h b/backends/graphics/sdl/sdl-graphics.h index 86e52a0bf6..9627ab23a3 100644 --- a/backends/graphics/sdl/sdl-graphics.h +++ b/backends/graphics/sdl/sdl-graphics.h @@ -132,7 +132,6 @@ public: virtual void warpMouse(int x, int y); virtual void setMouseCursor(const byte *buf, uint w, uint h, int hotspotX, int hotspotY, uint32 keycolor, int cursorTargetScale = 1, const Graphics::PixelFormat *format = NULL); virtual void setCursorPalette(const byte *colors, uint start, uint num); - virtual void disableCursorPalette(bool disable); #ifdef USE_OSD virtual void displayMessageOnOSD(const char *msg); |