diff options
author | Johannes Schickel | 2010-10-13 03:57:44 +0000 |
---|---|---|
committer | Johannes Schickel | 2010-10-13 03:57:44 +0000 |
commit | 75e8452b6e6a2bf4fb2f588aa00b428a60d873b5 (patch) | |
tree | f29541d55309487a94bd1d38e8b53bb3dde9aec6 /backends/platform/gp2x | |
parent | 48ee83b88957dab86bc763e9ef21a70179fa8679 (diff) | |
parent | e9f50882ea5b6beeefa994040be9d3bab6a1f107 (diff) | |
download | scummvm-rg350-75e8452b6e6a2bf4fb2f588aa00b428a60d873b5.tar.gz scummvm-rg350-75e8452b6e6a2bf4fb2f588aa00b428a60d873b5.tar.bz2 scummvm-rg350-75e8452b6e6a2bf4fb2f588aa00b428a60d873b5.zip |
OPENGL: Merged from trunk, from rev 52105 to 53396.
This includes an rather hacky attempt to merge all the recent gp2x backend
changes into the branch. I suppose the gp2x backend and probably all new
backends, i.e. gph, dingux etc., might not compile anymore.
Since I have no way of testing those it would be nice if porters could look
into getting those up to speed in this branch.
svn-id: r53399
Diffstat (limited to 'backends/platform/gp2x')
-rw-r--r-- | backends/platform/gp2x/build/README-GP2X | 6 | ||||
-rwxr-xr-x | backends/platform/gp2x/gp2x-bundle.mk | 12 | ||||
-rw-r--r-- | backends/platform/gp2x/gp2x-hw.cpp | 25 | ||||
-rw-r--r-- | backends/platform/gp2x/gp2x-hw.h | 8 | ||||
-rw-r--r-- | backends/platform/gp2x/gp2x.cpp | 4 |
5 files changed, 44 insertions, 11 deletions
diff --git a/backends/platform/gp2x/build/README-GP2X b/backends/platform/gp2x/build/README-GP2X index f95a974230..dc93a9f1c9 100644 --- a/backends/platform/gp2x/build/README-GP2X +++ b/backends/platform/gp2x/build/README-GP2X @@ -20,10 +20,10 @@ Contents: Please refer to the: -GP2X/GP2XWiz ScummVM Forum: <http://forums.scummvm.org/viewforum.php?f=14> -WiKi: <http://wiki.scummvm.org/index.php/GP2X> +GP2X/GP2XWiz ScummVM Forum: <http://forums.scummvm.org/viewforum.php?f=14> +WiKi: <http://wiki.scummvm.org/index.php/GP2X> -for the most current information on the port and any updates to this +for the most current information on the port and any updates to this documentation. ------------------------------------------------------------------------ diff --git a/backends/platform/gp2x/gp2x-bundle.mk b/backends/platform/gp2x/gp2x-bundle.mk index c6fb72c1c3..67d22d1889 100755 --- a/backends/platform/gp2x/gp2x-bundle.mk +++ b/backends/platform/gp2x/gp2x-bundle.mk @@ -6,7 +6,7 @@ gp2x-bundle: $(EXECUTABLE) $(MKDIR) "$(bundle_name)" $(MKDIR) "$(bundle_name)/saves" $(MKDIR) "$(bundle_name)/engine-data" - + echo "Please put your save games in this dir" >> "$(bundle_name)/saves/PUT_SAVES_IN_THIS_DIR" $(CP) $(srcdir)/backends/platform/gp2x/build/scummvm.gpe $(bundle_name)/ @@ -28,13 +28,13 @@ ifdef DYNAMIC_MODULES endif tar -C $(bundle_name) -cvjf $(bundle_name).tar.bz2 . - rm -R ./$(bundle_name) + rm -R ./$(bundle_name) gp2x-bundle-debug: $(EXECUTABLE) $(MKDIR) "$(bundle_name)" $(MKDIR) "$(bundle_name)/saves" $(MKDIR) "$(bundle_name)/engine-data" - + echo "Please put your save games in this dir" >> "$(bundle_name)/saves/PUT_SAVES_IN_THIS_DIR" $(CP) $(srcdir)/backends/platform/gp2x/build/scummvm.gpe $(bundle_name)/ @@ -46,15 +46,15 @@ gp2x-bundle-debug: $(EXECUTABLE) $(INSTALL) -c -m 644 $(DIST_FILES_THEMES) $(bundle_name)/ $(INSTALL) -c -m 644 $(DIST_FILES_ENGINEDATA) $(bundle_name)/engine-data $(CP) $(srcdir)/backends/vkeybd/packs/vkeybd_default.zip $(bundle_name)/ - + $(INSTALL) -c -m 777 $(srcdir)/$(EXECUTABLE) $(bundle_name)/$(EXECUTABLE) ifdef DYNAMIC_MODULES $(INSTALL) -d "$(bundle_name)/scummvm/plugins" $(INSTALL) -c -m 644 $(PLUGINS) "$(bundle_name)/scummvm/plugins" endif - + tar -C $(bundle_name) -cvjf $(bundle_name)-debug.tar.bz2 . - rm -R ./$(bundle_name) + rm -R ./$(bundle_name) .PHONY: gp2x-bundle gp2x-bundle-debug diff --git a/backends/platform/gp2x/gp2x-hw.cpp b/backends/platform/gp2x/gp2x-hw.cpp index 2dc5b4f579..75e4ca6471 100644 --- a/backends/platform/gp2x/gp2x-hw.cpp +++ b/backends/platform/gp2x/gp2x-hw.cpp @@ -197,3 +197,28 @@ void gp2x_video_wait_vsync(void) } /* namespace GP2X_HW */ +namespace GPH { + +enum { + /* Touchscreen TapMode */ + TAPMODE_LEFT = 0, + TAPMODE_RIGHT = 1, + TAPMODE_HOVER = 2 +}; + +int tapmodeLevel = TAPMODE_LEFT; + +void ToggleTapMode() { + if (tapmodeLevel == TAPMODE_LEFT) { + tapmodeLevel = TAPMODE_RIGHT; + } else if (tapmodeLevel == TAPMODE_RIGHT) { + tapmodeLevel = TAPMODE_HOVER; + } else if (tapmodeLevel == TAPMODE_HOVER) { + tapmodeLevel = TAPMODE_LEFT; + } else { + tapmodeLevel = TAPMODE_LEFT; + } +} + + +} /* namespace GPH */ diff --git a/backends/platform/gp2x/gp2x-hw.h b/backends/platform/gp2x/gp2x-hw.h index 7e72812cc4..872c44f118 100644 --- a/backends/platform/gp2x/gp2x-hw.h +++ b/backends/platform/gp2x/gp2x-hw.h @@ -54,4 +54,12 @@ extern void gp2x_video_wait_vsync(void); } /* namespace GP2X_HW */ +namespace GPH { + +extern int tapmodeLevel; + +extern void ToggleTapMode(); + +} /* namespace GPH */ + #endif //GP2X_HW_H diff --git a/backends/platform/gp2x/gp2x.cpp b/backends/platform/gp2x/gp2x.cpp index b4396db0ea..c297a45833 100644 --- a/backends/platform/gp2x/gp2x.cpp +++ b/backends/platform/gp2x/gp2x.cpp @@ -50,7 +50,7 @@ void OSystem_GP2X::initBackend() { char workDirName[PATH_MAX + 1]; if (getcwd(workDirName, PATH_MAX) == NULL) { - error("Could not obtain current working directory."); + error("Could not obtain current working directory"); } else { printf("Current working directory: %s\n", workDirName); } @@ -162,7 +162,7 @@ void OSystem_GP2X::addSysArchivesToSearchSet(Common::SearchSet &s, int priority) char workDirName[PATH_MAX + 1]; if (getcwd(workDirName, PATH_MAX) == NULL) { - error("Error: Could not obtain current working directory."); + error("Error: Could not obtain current working directory"); } Common::FSNode workdirNode(workDirName); |