[mythtv] PATCH: mythgame patch for latest mame (reworked)

Kyle Mestery kmestery at comcast.net
Sun Jan 11 22:29:59 EST 2004


On Sun, 11 Jan 2004, Isaac Richards wrote:

> Can you simply make it test for the most recent (or newer) versions of xmame,
> then?  The version can be updated when someone finds it, but the code would
> then be there to check already.
>
Attached is a revamped patch that checks for the latest version of mame
(minor version 77) and sets up the options correctly. This should allow
older versions to continue to use the older options.

Kyle
-------------- next part --------------
Index: mamehandler.cpp
===================================================================
RCS file: /var/lib/mythcvs/mythgame/mythgame/mamehandler.cpp,v
retrieving revision 1.24
diff -u -r1.24 mamehandler.cpp
--- mamehandler.cpp	9 Jan 2004 20:31:23 -0000	1.24
+++ mamehandler.cpp	12 Jan 2004 03:28:29 -0000
@@ -765,11 +765,17 @@
 
                 if (!strcmp(tmp, "37 BETA 4")) {
                         fullscreen = " -nocabview";
+                } else if (!strcmp(tmp, "77")) {
+                        /* Version 77 likes -fullscreen instead of -fullview */
+                        fullscreen = " -fullscreen";
                 } else {
                         fullscreen = " -fullview";
                 }
                 if (!strcmp(tmp, "37 BETA 5")) {
                         fullscreen = " -nocabview";
+                } else if (!strcmp(tmp, "77")) {
+                        /* Version 77 likes -fullscreen instead of -fullview */
+                        fullscreen = " -fullscreen";
                 } else {
                         fullscreen = " -fullview";
                 }
@@ -875,8 +881,13 @@
         }
         /* the nocursor option doesn't apply to SDL builds of xmame */
         if ( strcmp(general_prefs.xmame_display_target, "SDL")) {
-          *exec+= game_settings.fullscreen ? (" -nocursor" + fullscreen) : 
-                  windowed;
+          if (!strcmp(general_prefs.xmame_minor, "77")) {
+            /* Version 77 does not like -nocursor */
+            *exec+= game_settings.fullscreen ? (fullscreen) : windowed;
+          } else {
+            *exec+= game_settings.fullscreen ? (" -nocursor" + fullscreen) : 
+                    windowed;
+          }
         }
         else
           *exec+= game_settings.fullscreen ? fullscreen : windowed;


More information about the mythtv-dev mailing list