aboutsummaryrefslogtreecommitdiff
path: root/backends/sdl
diff options
context:
space:
mode:
authorEugene Sandulenko2006-06-03 01:05:09 +0000
committerEugene Sandulenko2006-06-03 01:05:09 +0000
commita681ebad7d4cdb83e976d1afd383ad6c42a04221 (patch)
tree8f3b2899df51bee549a433caa4acbaa4411c5e43 /backends/sdl
parent48af506189f0629528444bb88ca7a6f8e957f6d4 (diff)
downloadscummvm-rg350-a681ebad7d4cdb83e976d1afd383ad6c42a04221.tar.gz
scummvm-rg350-a681ebad7d4cdb83e976d1afd383ad6c42a04221.tar.bz2
scummvm-rg350-a681ebad7d4cdb83e976d1afd383ad6c42a04221.zip
More maemo port development
svn-id: r22849
Diffstat (limited to 'backends/sdl')
-rw-r--r--backends/sdl/graphics.cpp14
-rw-r--r--backends/sdl/sdl.cpp2
2 files changed, 13 insertions, 3 deletions
diff --git a/backends/sdl/graphics.cpp b/backends/sdl/graphics.cpp
index 05bf1bc0e0..a14fa9e109 100644
--- a/backends/sdl/graphics.cpp
+++ b/backends/sdl/graphics.cpp
@@ -310,6 +310,9 @@ void OSystem_SDL::loadGFXMode() {
_forceFull = true;
_modeFlags |= DF_UPDATE_EXPAND_1_PIXEL;
+ int hwW, hwH;
+
+#ifndef __MAEMO__
_overlayWidth = _screenWidth * _scaleFactor;
_overlayHeight = _screenHeight * _scaleFactor;
@@ -319,6 +322,13 @@ void OSystem_SDL::loadGFXMode() {
if (_adjustAspectRatio)
_overlayHeight = real2Aspect(_overlayHeight);
+ hwW = _screenWidth * _scaleFactor;
+ hwH = effectiveScreenHeight();
+#else
+ hwW = _overlayWidth;
+ hwH = _overlayHeight;
+#endif
+
//
// Create the surface that contains the 8 bit game data
//
@@ -330,7 +340,7 @@ void OSystem_SDL::loadGFXMode() {
// Create the surface that contains the scaled graphics in 16 bit mode
//
- _hwscreen = SDL_SetVideoMode(_screenWidth * _scaleFactor, effectiveScreenHeight(), 16,
+ _hwscreen = SDL_SetVideoMode(hwW, hwH, 16,
_fullscreen ? (SDL_FULLSCREEN|SDL_SWSURFACE) : SDL_SWSURFACE
);
if (_hwscreen == NULL) {
@@ -703,7 +713,7 @@ void OSystem_SDL::setFullscreenMode(bool enable) {
return;
}
-#if defined(MACOSX) && !SDL_VERSION_ATLEAST(1, 2, 6)
+#if (defined(MACOSX) && !SDL_VERSION_ATLEAST(1, 2, 6)) || defined(__MAEMO__)
// On OS X, SDL_WM_ToggleFullScreen is currently not implemented. Worse,
// before SDL 1.2.6 it always returned -1 (which would indicate a
// successful switch). So we simply don't call it at all and use
diff --git a/backends/sdl/sdl.cpp b/backends/sdl/sdl.cpp
index 274ebec193..dce70bc780 100644
--- a/backends/sdl/sdl.cpp
+++ b/backends/sdl/sdl.cpp
@@ -144,7 +144,7 @@ void OSystem_SDL::initBackend() {
_scaleFactor = 1;
_scalerProc = Normal1x;
-#if !defined(_WIN32_WCE) && !defined(__SYMBIAN32__) && !defined(__MAEMO__)
+#if !defined(_WIN32_WCE) && !defined(__SYMBIAN32__)
_fullscreen = ConfMan.getBool("fullscreen");
#else
_fullscreen = true;