[Scummvm-cvs-logs] SF.net SVN: scummvm:[45733] scummvm/branches/branch-1-0-0

sev at users.sourceforge.net sev at users.sourceforge.net
Sat Nov 7 21:01:46 CET 2009


Revision: 45733
          http://scummvm.svn.sourceforge.net/scummvm/?rev=45733&view=rev
Author:   sev
Date:     2009-11-07 20:01:45 +0000 (Sat, 07 Nov 2009)

Log Message:
-----------
Sync linuxmoto backend with trunk

Modified Paths:
--------------
    scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/hardwarekeys.cpp
    scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/linuxmoto-events.cpp
    scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/linuxmoto-sdl.h
    scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/module.mk
    scummvm/branches/branch-1-0-0/backends/platform/sdl/graphics.cpp
    scummvm/branches/branch-1-0-0/dists/motoezx/scummvm.lin
    scummvm/branches/branch-1-0-0/dists/motomagx/mpkg/mySDL.cfg
    scummvm/branches/branch-1-0-0/dists/motomagx/mpkg/run.sh
    scummvm/branches/branch-1-0-0/dists/motomagx/mpkg/scummvm.desktop
    scummvm/branches/branch-1-0-0/dists/motomagx/pep/app/scummvm.sh
    scummvm/branches/branch-1-0-0/dists/motomagx/pep/description.ini
    scummvm/branches/branch-1-0-0/ports.mk

Modified: scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/hardwarekeys.cpp
===================================================================
--- scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/hardwarekeys.cpp	2009-11-07 15:10:14 UTC (rev 45732)
+++ scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/hardwarekeys.cpp	2009-11-07 20:01:45 UTC (rev 45733)
@@ -114,5 +114,5 @@
 
 
 Common::HardwareKeySet *OSystem_LINUXMOTO::getHardwareKeySet() {
-	OSystem_SDL::getHardwareKeySet();
+	return OSystem_SDL::getHardwareKeySet();
 }

Modified: scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/linuxmoto-events.cpp
===================================================================
--- scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/linuxmoto-events.cpp	2009-11-07 15:10:14 UTC (rev 45732)
+++ scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/linuxmoto-events.cpp	2009-11-07 20:01:45 UTC (rev 45733)
@@ -44,6 +44,28 @@
 	return key;
 }
 
+void OSystem_LINUXMOTO::fillMouseEvent(Common::Event &event, int x, int y) {
+	if (_videoMode.mode == GFX_HALF && !_overlayVisible) {
+		event.mouse.x = x*2;
+		event.mouse.y = y*2;
+	} else {
+		event.mouse.x = x;
+		event.mouse.y = y;
+	}
+
+	// Update the "keyboard mouse" coords
+	_km.x = x;
+	_km.y = y;
+
+	// Adjust for the screen scaling
+	if (!_overlayVisible) {
+		event.mouse.x /= _videoMode.scaleFactor;
+		event.mouse.y /= _videoMode.scaleFactor;
+		if (_videoMode.aspectRatioCorrection)
+			event.mouse.y = aspect2Real(event.mouse.y);
+	}
+}
+
 bool OSystem_LINUXMOTO::remapKey(SDL_Event &ev, Common::Event &event) {
 	//  Motorol A1200/E6/A1600 remapkey by Lubomyr
 #ifdef MOTOEZX
@@ -61,7 +83,7 @@
 		ev.key.keysym.sym = SDLK_F5;
 	}
 	// VirtualKeyboard - Camera key
- 	else if (ev.key.keysym.sym == SDLK_PAUSE) {
+	else if (ev.key.keysym.sym == SDLK_PAUSE) {
 		ev.key.keysym.sym = SDLK_F7;
 	}
 	// Enter - mod+fire key
@@ -93,41 +115,13 @@
 		ev.key.keysym.sym = SDLK_LEFTBRACKET;
 	}
 #endif
-	// Motorola Z6/V8 remapkey by Ant-On
+
 #ifdef MOTOMAGX
 	// Quit on cancel
-	if (ev.key.keysym.sym == SDLK_ESCAPE) {
+	if (ev.key.keysym.sym == SDLK_F12) {
 		event.type = Common::EVENT_QUIT;
 		return true;
 	}
-	// F5 Game Menu - Slide Select 
-	if (ev.key.keysym.sym == SDLK_SPACE) {
-		ev.key.keysym.sym = SDLK_F5;
-	}
-	// Escape - Dial key 
-	else if (ev.key.keysym.sym == SDLK_TAB) {
-		ev.key.keysym.sym = SDLK_ESCAPE;
-	}
-	// Space - Virtual keyboard 
-	else if (ev.key.keysym.sym == SDLK_PAUSE) {
-		ev.key.keysym.sym = SDLK_F7;
-	}
-	// 'y' - Left soft
-	else if (ev.key.keysym.sym == SDLK_F9) {	
-		ev.key.keysym.sym = SDLK_y;	
-	}
-	// 'n' - Rigth soft
-	else if (ev.key.keysym.sym == SDLK_F11) {	
-		ev.key.keysym.sym = SDLK_n;	
-	}
-	//  # -> volume'+' 
-	else if (ev.key.keysym.sym == SDLK_HASH) {	
-		ev.key.keysym.sym = SDLK_RIGHTBRACKET;
-	}
-	//  * -> volume'-' 
-	else if (ev.key.keysym.sym == SDLK_WORLD_55) {	
-		ev.key.keysym.sym = SDLK_LEFTBRACKET;
-	}
 #endif
 
 // Joystick to Mouse

Modified: scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/linuxmoto-sdl.h
===================================================================
--- scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/linuxmoto-sdl.h	2009-11-07 15:10:14 UTC (rev 45732)
+++ scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/linuxmoto-sdl.h	2009-11-07 20:01:45 UTC (rev 45733)
@@ -28,6 +28,7 @@
 #define LINUXMOTO_SDL
 
 #include "backends/platform/sdl/sdl.h"
+#include "backends/platform/linuxmoto/linuxmoto-scaler.h"
 
 #include <SDL.h>
 
@@ -35,12 +36,29 @@
 private:
 	bool _audioSuspended;
 public:
+	/* Graphics */
+	void initSize(uint w, uint h);
+	void setGraphicsModeIntern();
+	bool setGraphicsMode(int mode);
+	void internUpdateScreen();
+	const OSystem::GraphicsMode *getSupportedGraphicsModes() const;
+	bool setGraphicsMode(const char *name);
+	int getDefaultGraphicsMode() const;
+	bool loadGFXMode();
+	void drawMouse();
+	void undrawMouse();
+	void showOverlay();
+	void hideOverlay();
+
+	/* Event Stuff */
 	virtual bool remapKey(SDL_Event &ev, Common::Event &event);
 	virtual void preprocessEvents(SDL_Event *event);
 	virtual void setupMixer();
 	virtual Common::HardwareKeySet *getHardwareKeySet();
+	void fillMouseEvent(Common::Event&, int, int);
 	void suspendAudio();
 	int resumeAudio();
+	void warpMouse(int, int);
 };
 
 #endif

Modified: scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/module.mk
===================================================================
--- scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/module.mk	2009-11-07 15:10:14 UTC (rev 45732)
+++ scummvm/branches/branch-1-0-0/backends/platform/linuxmoto/module.mk	2009-11-07 20:01:45 UTC (rev 45733)
@@ -1,10 +1,13 @@
 MODULE := backends/platform/linuxmoto
 
 MODULE_OBJS := \
-	main.o \
-	hardwarekeys.o \
+	linuxmoto-main.o \
 	linuxmoto-events.o \
-	linuxmoto-sdl.o
+	linuxmoto-sdl.o \
+	linuxmoto-scaler.o \
+	linuxmoto-graphics.o \
+	hardwarekeys.o \
+	../wince/ARMscaler.o
 
 MODULE_DIRS += \
 	backends/platform/linuxmoto/
@@ -12,18 +15,5 @@
 # We don't use the rules.mk here on purpose
 OBJS := $(addprefix $(MODULE)/, $(MODULE_OBJS)) $(OBJS)
 
-MODULE := backends/platform/sdl
-
-MODULE_OBJS := \
-	events.o \
-	graphics.o \
-	hardwarekeys.o \
-	main.o \
-	sdl.o
-
-MODULE_DIRS += \
-	backends/platform/sdl/
-
-# We don't use the rules.mk here on purpose
-OBJS := $(addprefix $(MODULE)/, $(MODULE_OBJS)) $(OBJS)
-
+# HACK: The linuxmoto backend is based on the SDL one, so we load that, too.
+include $(srcdir)/backends/platform/sdl/module.mk

Modified: scummvm/branches/branch-1-0-0/backends/platform/sdl/graphics.cpp
===================================================================
--- scummvm/branches/branch-1-0-0/backends/platform/sdl/graphics.cpp	2009-11-07 15:10:14 UTC (rev 45732)
+++ scummvm/branches/branch-1-0-0/backends/platform/sdl/graphics.cpp	2009-11-07 20:01:45 UTC (rev 45733)
@@ -364,7 +364,7 @@
 
 	int hwW, hwH;
 
-#if !defined(__MAEMO__) && !defined(GP2XWIZ)
+#if !defined(__MAEMO__) && !defined(GP2XWIZ) && !defined(LINUXMOTO)
 	_videoMode.overlayWidth = _videoMode.screenWidth * _videoMode.scaleFactor;
 	_videoMode.overlayHeight = _videoMode.screenHeight * _videoMode.scaleFactor;
 

Modified: scummvm/branches/branch-1-0-0/dists/motoezx/scummvm.lin
===================================================================
--- scummvm/branches/branch-1-0-0/dists/motoezx/scummvm.lin	2009-11-07 15:10:14 UTC (rev 45732)
+++ scummvm/branches/branch-1-0-0/dists/motoezx/scummvm.lin	2009-11-07 20:01:45 UTC (rev 45733)
@@ -7,4 +7,4 @@
 export SDL_QT_MODIFICATOR=1
 export HOME=/mmc/mmca1/games
 cd $mypath
-exec $mypath/scummvm --path=/mmc/mmca1/games/data --gfx-mode=1x > /mmc/mmca1/games/logs/scummvm.log 2>&1
+exec $mypath/scummvm --gfx-mode=1x > $mypath/scummvm.log

Modified: scummvm/branches/branch-1-0-0/dists/motomagx/mpkg/mySDL.cfg
===================================================================
--- scummvm/branches/branch-1-0-0/dists/motomagx/mpkg/mySDL.cfg	2009-11-07 15:10:14 UTC (rev 45732)
+++ scummvm/branches/branch-1-0-0/dists/motomagx/mpkg/mySDL.cfg	2009-11-07 20:01:45 UTC (rev 45733)
@@ -9,12 +9,12 @@
 VolumeUp = PLUS
 VolumeDown = MINUS
 SideKey = SPACE
-Call = TAB
-Music = F10
-Red = ESCAPE
+Call = ESCAPE
+Music = F8
+Red = F12
 C = BACKSPACE
-Camera = PAUSE
-Slider = 0
+Camera = F7
+Slider = F5
 0 = 0
 1 = 1
 2 = 2

Modified: scummvm/branches/branch-1-0-0/dists/motomagx/mpkg/run.sh
===================================================================
--- scummvm/branches/branch-1-0-0/dists/motomagx/mpkg/run.sh	2009-11-07 15:10:14 UTC (rev 45732)
+++ scummvm/branches/branch-1-0-0/dists/motomagx/mpkg/run.sh	2009-11-07 20:01:45 UTC (rev 45733)
@@ -7,4 +7,4 @@
 cd $DIR
 rm /mmc/mmca1/.system/mySDL.cfg
 cp $DIR/mySDL.cfg /mmc/mmca1/.system/mySDL.cfg
-./scummvm --path=$DIR --gfx-mode=1x > $DIR/scummvm.log
+exec $DIR/scummvm --path=$DIR --gfx-mode=1x > $DIR/scummvm.log

Modified: scummvm/branches/branch-1-0-0/dists/motomagx/mpkg/scummvm.desktop
===================================================================
--- scummvm/branches/branch-1-0-0/dists/motomagx/mpkg/scummvm.desktop	2009-11-07 15:10:14 UTC (rev 45732)
+++ scummvm/branches/branch-1-0-0/dists/motomagx/mpkg/scummvm.desktop	2009-11-07 20:01:45 UTC (rev 45733)
@@ -1,6 +1,6 @@
 [Desktop Entry]
 BigIcon = scummvm_usr.png
 Directory = scummvm
-Exec = run.sh
+Exec = scummvm.sh
 AniIcon = scummvm_usr.png
 Name = ScummVM

Modified: scummvm/branches/branch-1-0-0/dists/motomagx/pep/app/scummvm.sh
===================================================================
--- scummvm/branches/branch-1-0-0/dists/motomagx/pep/app/scummvm.sh	2009-11-07 15:10:14 UTC (rev 45732)
+++ scummvm/branches/branch-1-0-0/dists/motomagx/pep/app/scummvm.sh	2009-11-07 20:01:45 UTC (rev 45733)
@@ -1,16 +1,10 @@
 #!/bin/sh
 GAMES=/mmc/mmca1/.Games
-export DATA_DIR=$GAMES/.data/ScummVM
 export LD_LIBRARY_PATH=$GAMES/.lib:$LD_LIBRARY_PATH
 # uncomment next line if you wanna 270-degrees clockwise rotated screen 
 #export SDL_QT_INVERT_ROTATION=1
-
 GAME_PATH=`basename $0`
 GAME_PATH=`echo $0 | sed -e 's/'$GAME_PATH'//g'`
 cd "$GAME_PATH"
-
-export HOME="$GAME_PATH"
-
-export LD_PREADLOAD=/usr/lib/libtaskman.so
-
-exec ./scummvm -g 1x
+export HOME="$GAMES"
+exec ./scummvm --gfx-mode=1x > $GAME_PATH/scummvm.log

Modified: scummvm/branches/branch-1-0-0/dists/motomagx/pep/description.ini
===================================================================
--- scummvm/branches/branch-1-0-0/dists/motomagx/pep/description.ini	2009-11-07 15:10:14 UTC (rev 45732)
+++ scummvm/branches/branch-1-0-0/dists/motomagx/pep/description.ini	2009-11-07 20:01:45 UTC (rev 45733)
@@ -9,7 +9,7 @@
 InstallPath = ../../mmc/mmca1/.Games/ScummVM/
 AppLockable = 1
 Author = ScummVM Team
-Version = trunk
+Version = 1.0.0
 Daemon = 1
 BigIcon= scummvm_big_usr.png
 AniIcon= scummvm_big_usr.png

Modified: scummvm/branches/branch-1-0-0/ports.mk
===================================================================
--- scummvm/branches/branch-1-0-0/ports.mk	2009-11-07 15:10:14 UTC (rev 45732)
+++ scummvm/branches/branch-1-0-0/ports.mk	2009-11-07 20:01:45 UTC (rev 45733)
@@ -216,6 +216,7 @@
 	$(CP) $(srcdir)/backends/vkeybd/packs/vkeybd_default.zip motoezx/scummvm/
 	$(CP) $(srcdir)/dists/motoezx/* motoezx/scummvm/
 	tar -C motoezx -cvzf motoezx/ScummVM.pkg scummvm
+	$(RM) -r motoezx/scummvm
 
 # Special target to create a motomagx snapshot
 motomagx-mpkg: $(EXECUTABLE)
@@ -225,16 +226,28 @@
 	$(CP) $(srcdir)/backends/vkeybd/packs/vkeybd_default.zip motomagx/scummvm/
 	$(CP) $(srcdir)/dists/motomagx/mpkg/* motomagx/scummvm/
 	tar -C motomagx -cvzf motomagx/ScummVM.mpkg scummvm
+	$(RM) -r motomagx/scummvm
 
+motomagx-mgx: $(EXECUTABLE)
+	$(MKDIR) motomagx/scummvm
+	$(STRIP) $(EXECUTABLE) -o motomagx/scummvm/$(EXECUTABLE)
+	$(INSTALL) -c -m 644 $(DIST_FILES_THEMES) $(DIST_FILES_ENGINEDATA) motomagx/scummvm/
+	$(CP) $(srcdir)/backends/vkeybd/packs/vkeybd_default.zip motomagx/scummvm/
+	$(CP) $(srcdir)/dists/motomagx/mgx/* motomagx/scummvm/
+	tar -C motomagx -cvf motomagx/ScummVM.mgx scummvm
+	$(RM) -r motomagx/scummvm
+
 motomagx-pep: $(EXECUTABLE)
 	$(MKDIR) motomagx/pep
 	$(CP) -r $(srcdir)/dists/motomagx/pep/* motomagx/pep
+	$(RM) -r motomagx/pep/app/.svn
 	$(STRIP) $(EXECUTABLE) -o motomagx/pep/app/$(EXECUTABLE)
 	$(INSTALL) -c -m 644 $(DIST_FILES_THEMES) $(DIST_FILES_ENGINEDATA) motomagx/pep/app
 	$(CP) $(srcdir)/backends/vkeybd/packs/vkeybd_default.zip motomagx/pep/app
 	tar -C motomagx/pep -czvf motomagx/ScummVM.pep app description.ini  scummvm_big_usr.png  scummvm_small_usr.png
+	$(RM) -r motomagx/pep
 
-.PHONY: deb bundle osxsnap win32dist wiidist motoezx motomagx-mpkg motomagx-pep install uninstall
+.PHONY: deb bundle osxsnap win32dist wiidist motoezx motomagx-mpkg motomagx-mgx motomagx-pep install uninstall
 
 #
 # ARM specific


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