aboutsummaryrefslogtreecommitdiff
path: root/backends
diff options
context:
space:
mode:
authorMax Horn2004-03-15 00:45:45 +0000
committerMax Horn2004-03-15 00:45:45 +0000
commite46ba2f29ff20a317e708d15dc5be904cdf005eb (patch)
tree994a9ccd5999a054ba285d2c63e549df03036b27 /backends
parentb585b9ac4b2772ed7cddb12cc4435b40f0ddf21f (diff)
downloadscummvm-rg350-e46ba2f29ff20a317e708d15dc5be904cdf005eb.tar.gz
scummvm-rg350-e46ba2f29ff20a317e708d15dc5be904cdf005eb.tar.bz2
scummvm-rg350-e46ba2f29ff20a317e708d15dc5be904cdf005eb.zip
Added OSystem::getDefaultGraphicsMode(); renamed OSystem::get_height() and get_width() to getHeight and getWidth(); augmented some doxygen comments in common/system.h
svn-id: r13284
Diffstat (limited to 'backends')
-rw-r--r--backends/PalmOS/Src/palm.cpp16
-rw-r--r--backends/PalmOS/Src/palm.h4
-rw-r--r--backends/dc/dc.h4
-rw-r--r--backends/gp32/gp32.h4
-rw-r--r--backends/morphos/morphos.cpp4
-rw-r--r--backends/morphos/morphos.h4
-rw-r--r--backends/sdl/events.cpp2
-rw-r--r--backends/sdl/graphics.cpp8
-rw-r--r--backends/sdl/sdl-common.h5
-rw-r--r--backends/x11/x11.cpp8
10 files changed, 32 insertions, 27 deletions
diff --git a/backends/PalmOS/Src/palm.cpp b/backends/PalmOS/Src/palm.cpp
index d61c7d6dee..1c4948ad9c 100644
--- a/backends/PalmOS/Src/palm.cpp
+++ b/backends/PalmOS/Src/palm.cpp
@@ -649,10 +649,10 @@ void OSystem_PALMOS::updateScreen() {
if (oldCol != gVars->indicator.on) {
// redraw if needed
if (_lastKeyModifier)
- draw1BitGfx((kDrawKeyState + _lastKeyModifier - 1), 2, get_height() + 2, true);
+ draw1BitGfx((kDrawKeyState + _lastKeyModifier - 1), 2, getHeight() + 2, true);
if(_useNumPad)
- draw1BitGfx(kDrawNumPad, (get_width() >> 1) - 32, get_height() + 2, true);
+ draw1BitGfx(kDrawNumPad, (getWidth() >> 1) - 32, getHeight() + 2, true);
}
}
@@ -1058,9 +1058,9 @@ bool OSystem_PALMOS::poll_event(Event *event) {
_lastKeyModifier %= 4;
if (_lastKeyModifier)
- draw1BitGfx((kDrawKeyState + _lastKeyModifier - 1), 2, get_height() + 2, true);
+ draw1BitGfx((kDrawKeyState + _lastKeyModifier - 1), 2, getHeight() + 2, true);
else
- draw1BitGfx(kDrawKeyState, 2, get_height() + 2, false);
+ draw1BitGfx(kDrawKeyState, 2, getHeight() + 2, false);
} else {
byte b = 0;
@@ -1075,7 +1075,7 @@ bool OSystem_PALMOS::poll_event(Event *event) {
} else if (ev.data.keyDown.chr == 'n' && b == KBD_CTRL) {
UInt8 *scr = _screenP + _screenWidth * (_screenHeight + 2);
_useNumPad = !_useNumPad;
- draw1BitGfx(kDrawNumPad, (get_width() >> 1) - 32, get_height() + 2, _useNumPad);
+ draw1BitGfx(kDrawNumPad, (getWidth() >> 1) - 32, getHeight() + 2, _useNumPad);
} else if (ev.data.keyDown.chr == 'a' && b == (KBD_CTRL|KBD_ALT)) {
property(PROP_TOGGLE_ASPECT_RATIO, NULL);
@@ -1089,7 +1089,7 @@ bool OSystem_PALMOS::poll_event(Event *event) {
if (_lastKeyModifier) {
_lastKeyModifier = MD_NONE;
- draw1BitGfx(kDrawKeyState, 2, get_height() + 2, false);
+ draw1BitGfx(kDrawKeyState, 2, getHeight() + 2, false);
}
}
return true;
@@ -1773,11 +1773,11 @@ void OSystem_PALMOS::copy_rect_overlay(const byte *buf, int pitch, int x, int y,
}
-int16 OSystem_PALMOS::get_height() {
+int16 OSystem_PALMOS::getHeight() {
return _screenHeight;
}
-int16 OSystem_PALMOS::get_width() {
+int16 OSystem_PALMOS::getWidth() {
return _screenWidth;
}
diff --git a/backends/PalmOS/Src/palm.h b/backends/PalmOS/Src/palm.h
index baee772065..7e39b43862 100644
--- a/backends/PalmOS/Src/palm.h
+++ b/backends/PalmOS/Src/palm.h
@@ -146,8 +146,8 @@ public:
void grab_overlay(byte *buf, int pitch);
void copy_rect_overlay(const byte *buf, int pitch, int x, int y, int w, int h);
- int16 get_width();
- int16 get_height();
+ int16 getWidth();
+ int16 getHeight();
byte RGBToColor(uint8 r, uint8 g, uint8 b);
void ColorToRGB(byte color, uint8 &r, uint8 &g, uint8 &b);
// Set a parameter
diff --git a/backends/dc/dc.h b/backends/dc/dc.h
index d18c722f32..8fa314baf5 100644
--- a/backends/dc/dc.h
+++ b/backends/dc/dc.h
@@ -64,8 +64,8 @@ class OSystem_Dreamcast : public OSystem {
// Set the size of the video bitmap.
// Typically, 320x200
void initSize(uint w, uint h);
- int16 get_height() { return _screen_h; }
- int16 get_width() { return _screen_w; }
+ int16 getHeight() { return _screen_h; }
+ int16 getWidth() { return _screen_w; }
// Draw a bitmap to screen.
// The screen will not be updated to reflect the new bitmap
diff --git a/backends/gp32/gp32.h b/backends/gp32/gp32.h
index 435072626d..6fddf3fcfd 100644
--- a/backends/gp32/gp32.h
+++ b/backends/gp32/gp32.h
@@ -40,8 +40,8 @@ public:
// Set the size of the video bitmap.
// Typically, 320x200
void initSize(uint w, uint h);
- int16 get_height() { return _screenHeight; }
- int16 get_width() { return _screenWidth; }
+ int16 getHeight() { return _screenHeight; }
+ int16 getWidth() { return _screenWidth; }
// Draw a bitmap to screen.
// The screen will not be updated to reflect the new bitmap
diff --git a/backends/morphos/morphos.cpp b/backends/morphos/morphos.cpp
index 8b48e542dc..d8c00e3d4e 100644
--- a/backends/morphos/morphos.cpp
+++ b/backends/morphos/morphos.cpp
@@ -1567,12 +1567,12 @@ void OSystem_MorphOS::initSize(uint w, uint h)
CreateScreen(CSDSPTYPE_KEEP);
}
-int16 OSystem_MorphOS::get_width()
+int16 OSystem_MorphOS::getWidth()
{
return ScummScrWidth;
}
-int16 OSystem_MorphOS::get_height()
+int16 OSystem_MorphOS::getHeight()
{
return ScummScrHeight;
}
diff --git a/backends/morphos/morphos.h b/backends/morphos/morphos.h
index 6ce4413641..6e606c61ff 100644
--- a/backends/morphos/morphos.h
+++ b/backends/morphos/morphos.h
@@ -75,8 +75,8 @@ class OSystem_MorphOS : public OSystem
virtual void clear_overlay();
virtual void grab_overlay(int16 *buf, int pitch);
virtual void copy_rect_overlay(const int16 *buf, int pitch, int x, int y, int w, int h);
- virtual int16 get_height();
- virtual int16 get_width();
+ virtual int16 getHeight();
+ virtual int16 getWidth();
// Get the number of milliseconds since the program was started.
virtual uint32 get_msecs();
diff --git a/backends/sdl/events.cpp b/backends/sdl/events.cpp
index dae18ae51d..b351db9524 100644
--- a/backends/sdl/events.cpp
+++ b/backends/sdl/events.cpp
@@ -192,7 +192,7 @@ bool OSystem_SDL::poll_event(Event *event) {
// Alt-Return toggles full screen mode
if (b == KBD_ALT && ev.key.keysym.sym == SDLK_RETURN) {
- setFeatureState(kFeatureFullscreenMode, !_full_screen);
+ setFullscreenMode(!_full_screen);
break;
}
diff --git a/backends/sdl/graphics.cpp b/backends/sdl/graphics.cpp
index 0c9e603220..09040f5c63 100644
--- a/backends/sdl/graphics.cpp
+++ b/backends/sdl/graphics.cpp
@@ -45,6 +45,10 @@ const OSystem::GraphicsMode *OSystem_SDL::getSupportedGraphicsModes() const {
return s_supportedGraphicsModes;
}
+int OSystem_SDL::getDefaultGraphicsMode() const {
+ return GFX_DOUBLESIZE;
+}
+
bool OSystem_SDL::setGraphicsMode(int mode) {
Common::StackLock lock(_graphicsMutex, this);
@@ -715,11 +719,11 @@ void OSystem_SDL::add_dirty_rgn_auto(const byte *buf) {
}
}
-int16 OSystem_SDL::get_height() {
+int16 OSystem_SDL::getHeight() {
return _screenHeight;
}
-int16 OSystem_SDL::get_width() {
+int16 OSystem_SDL::getWidth() {
return _screenWidth;
}
diff --git a/backends/sdl/sdl-common.h b/backends/sdl/sdl-common.h
index c82ddb17c2..18ad04aabf 100644
--- a/backends/sdl/sdl-common.h
+++ b/backends/sdl/sdl-common.h
@@ -116,8 +116,8 @@ public:
virtual void clear_overlay();
virtual void grab_overlay(OverlayColor *buf, int pitch);
virtual void copy_rect_overlay(const OverlayColor *buf, int pitch, int x, int y, int w, int h);
- virtual int16 get_height();
- virtual int16 get_width();
+ virtual int16 getHeight();
+ virtual int16 getWidth();
// Methods that convert RGB to/from colors suitable for the overlay.
virtual OverlayColor RGBToColor(uint8 r, uint8 g, uint8 b);
@@ -125,6 +125,7 @@ public:
virtual const GraphicsMode *getSupportedGraphicsModes() const;
+ virtual int getDefaultGraphicsMode() const;
virtual bool setGraphicsMode(int mode);
virtual int getGraphicsMode() const;
diff --git a/backends/x11/x11.cpp b/backends/x11/x11.cpp
index 73b0e2cce8..b48d4244eb 100644
--- a/backends/x11/x11.cpp
+++ b/backends/x11/x11.cpp
@@ -137,8 +137,8 @@ public:
void clear_overlay();
void grab_overlay(int16 *, int);
void copy_rect_overlay(const int16 *, int, int, int, int, int);
- virtual int16 get_height();
- virtual int16 get_width();
+ virtual int16 getHeight();
+ virtual int16 getWidth();
static OSystem *create(int gfx_mode, bool full_screen);
@@ -1106,11 +1106,11 @@ void OSystem_X11::copy_rect_overlay(const int16 *src, int pitch, int x, int y, i
}
}
-int16 OSystem_X11::get_height() {
+int16 OSystem_X11::getHeight() {
return fb_height;
}
-int16 OSystem_X11::get_width() {
+int16 OSystem_X11::getWidth() {
return fb_width;
}