[Scummvm-cvs-logs] SF.net SVN: scummvm:[49403] scummvm/trunk/backends/platform/iphone
vinterstum at users.sourceforge.net
vinterstum at users.sourceforge.net
Thu Jun 3 05:22:11 CEST 2010
Revision: 49403
http://scummvm.svn.sourceforge.net/scummvm/?rev=49403&view=rev
Author: vinterstum
Date: 2010-06-03 03:22:10 +0000 (Thu, 03 Jun 2010)
Log Message:
-----------
We'll now default to non-touchpad mode on the iPad
Modified Paths:
--------------
scummvm/trunk/backends/platform/iphone/iphone_common.h
scummvm/trunk/backends/platform/iphone/iphone_video.h
scummvm/trunk/backends/platform/iphone/iphone_video.m
scummvm/trunk/backends/platform/iphone/osys_main.cpp
Modified: scummvm/trunk/backends/platform/iphone/iphone_common.h
===================================================================
--- scummvm/trunk/backends/platform/iphone/iphone_common.h 2010-06-03 03:11:19 UTC (rev 49402)
+++ scummvm/trunk/backends/platform/iphone/iphone_common.h 2010-06-03 03:22:10 UTC (rev 49403)
@@ -72,6 +72,7 @@
void iPhone_initSurface(int width, int height);
bool iPhone_fetchEvent(int *outEvent, float *outX, float *outY);
const char* iPhone_getDocumentsDir();
+bool iPhone_isHighResDevice();
#ifdef __cplusplus
}
Modified: scummvm/trunk/backends/platform/iphone/iphone_video.h
===================================================================
--- scummvm/trunk/backends/platform/iphone/iphone_video.h 2010-06-03 03:11:19 UTC (rev 49402)
+++ scummvm/trunk/backends/platform/iphone/iphone_video.h 2010-06-03 03:22:10 UTC (rev 49403)
@@ -43,8 +43,6 @@
SoftKeyboard* _keyboardView;
CALayer* _screenLayer;
- int _fullWidth;
- int _fullHeight;
int _widthOffset;
int _heightOffset;
Modified: scummvm/trunk/backends/platform/iphone/iphone_video.m
===================================================================
--- scummvm/trunk/backends/platform/iphone/iphone_video.m 2010-06-03 03:11:19 UTC (rev 49402)
+++ scummvm/trunk/backends/platform/iphone/iphone_video.m 2010-06-03 03:22:10 UTC (rev 49403)
@@ -29,6 +29,8 @@
static iPhoneView *sharedInstance = nil;
static int _width = 0;
static int _height = 0;
+static int _fullWidth;
+static int _fullHeight;
static CGRect _screenRect;
static char* _textureBuffer = 0;
static int _textureWidth = 0;
@@ -42,6 +44,10 @@
// static long lastTick = 0;
// static int frames = 0;
+bool iPhone_isHighResDevice() {
+ return _fullHeight > 480;
+}
+
void iPhone_updateScreen() {
if (!_needsScreenUpdate) {
_needsScreenUpdate = 1;
Modified: scummvm/trunk/backends/platform/iphone/osys_main.cpp
===================================================================
--- scummvm/trunk/backends/platform/iphone/osys_main.cpp 2010-06-03 03:11:19 UTC (rev 49402)
+++ scummvm/trunk/backends/platform/iphone/osys_main.cpp 2010-06-03 03:22:10 UTC (rev 49403)
@@ -57,7 +57,7 @@
_overlayVisible(false), _overlayBuffer(NULL), _fullscreen(NULL),
_mouseHeight(0), _mouseWidth(0), _mouseBuf(NULL), _lastMouseTap(0),
_secondaryTapped(false), _lastSecondaryTap(0), _screenOrientation(kScreenOrientationFlippedLandscape),
- _needEventRestPeriod(false), _mouseClickAndDragEnabled(false), _touchpadModeEnabled(true),
+ _needEventRestPeriod(false), _mouseClickAndDragEnabled(false),
_gestureStartX(-1), _gestureStartY(-1), _fullScreenIsDirty(false), _fullScreenOverlayIsDirty(false),
_mouseDirty(false), _timeSuspended(0), _lastDragPosX(-1), _lastDragPosY(-1), _screenChangeCount(0)
@@ -65,6 +65,7 @@
_queuedInputEvent.type = (Common::EventType)0;
_lastDrawnMouseRect = Common::Rect(0, 0, 0, 0);
+ _touchpadModeEnabled = !iPhone_isHighResDevice();
_fsFactory = new POSIXFilesystemFactory();
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list