View | Details | Raw Unified
Collapse All | Expand All

(-) src/options.c.orig (-8 / +77 lines)
 Lines 656-661    Link Here 
	gboolean list_mixer_plugins;	/* list mixer plugins */
	gboolean list_mixer_plugins;	/* list mixer plugins */
	gboolean keyboard_leds;		/* use keyboard leds */
	gboolean keyboard_leds;		/* use keyboard leds */
	gboolean dirty;			/* dirty not in 0.61 pr1 */
	gboolean dirty;			/* dirty not in 0.61 pr1 */
	gboolean newx11modeusage;	/* for 0.72.1 -x11-mode changes */
	gboolean xvext;			/* xv extension 0.60 + patch from
	gboolean xvext;			/* xv extension 0.60 + patch from
					   Alastair M. Robinson*/
					   Alastair M. Robinson*/
	gboolean vidix;			/* another target from Alastair M. Robinson
	gboolean vidix;			/* another target from Alastair M. Robinson
 Lines 32-39    Link Here 
#include <unistd.h>
#include <unistd.h>
#define BUFFER_SIZE 1000
#define BUFFER_SIZE 1000
gboolean create_game_list_file(void)
gboolean create_game_list_file(void)
{
{
	FILE *xmame_pipe=NULL;
	FILE *xmame_pipe=NULL;
 Lines 957-962    Link Here 
	version=atof(p);
	version=atof(p);
	g_free(opt);
	g_free(opt);
	
	
	/* version 0.72.1 introduces new syntax for the -x11-mode
	if (version>=0.72)
		available_options.newx11modeusage=TRUE;
	/* do not test anymore if the executable is valid since
	/* do not test anymore if the executable is valid since
	/* to be able to load the 0.68 options */
	/* to be able to load the 0.68 options */
	if (version==0.68)
	if (version==0.68)
 Lines 989-995    Link Here 
	available_options.list_mixer_plugins = FALSE;
	available_options.list_mixer_plugins = FALSE;
	available_options.keyboard_leds = FALSE;
	available_options.keyboard_leds = FALSE;
	available_options.dirty = FALSE;
	available_options.dirty = FALSE;
	available_options.xvext = FALSE;
	if (version>=0.72)
	{
		available_options.xvext=TRUE;
		available_options.fullscreen=TRUE;
	}
	else
	{
		available_options.xvext = FALSE;
		available_options.fullscreen = FALSE;
	}
	available_options.vidix = FALSE;
	available_options.vidix = FALSE;
	available_options.yuv = FALSE;
	available_options.yuv = FALSE;
	available_options.yv12 = FALSE;
	available_options.yv12 = FALSE;
 Lines 999-1005    Link Here 
	available_options.x11joyname = FALSE;
	available_options.x11joyname = FALSE;
	available_options.joydevname = FALSE;
	available_options.joydevname = FALSE;
	available_options.video_mode = FALSE;
	available_options.video_mode = FALSE;
	available_options.fullscreen = FALSE;
	available_options.cfgname = FALSE;
	available_options.cfgname = FALSE;
	available_options.grabmouse = FALSE;
	available_options.grabmouse = FALSE;
	available_options.grabkeyboard = FALSE;
	available_options.grabkeyboard = FALSE;
 Lines 34-39    Link Here 
#include <gtk/gtk.h>
#include <gtk/gtk.h>
#include "gxmame.h"
#include "gxmame.h"
#include "mameio.h"
#include "options.h"
#include "options.h"
#include "io.h"
#include "io.h"
#include "callbacks.h"
#include "callbacks.h"
 Lines 7252-7257    Link Here 
			*vidix=NULL,
			*vidix=NULL,
			*geometry = NULL,
			*geometry = NULL,
			*newext = NULL;
			*newext = NULL;
		int	x11mode = 0;
		if (available_options.mitshm)
		if (available_options.mitshm)
		{
		{
 Lines 7261-7267    Link Here 
		/* put the new extention option (xv and vidix) in a string*/
		/* put the new extention option (xv and vidix) in a string*/
		if (target->xvgeom_flag &&
		if (target->xvgeom_flag &&
			geometry = g_strdup_printf("-geometry
			geometry = g_strdup_printf("-geometry
		newext =  g_strdup_printf("%s "					/* fullscreen
		/* 0.72 removes -fullscreen option in favour of new */
		/* -x11-mode values */
		if (available_options.newx11modeusage)
		{
			newext =  g_strdup_printf("%s "					/* geometry */
					  "%s "					/* yuv */
					  "%s",					/* yv12 */
					  geometry?geometry:"",
					 
					 
					);
		}
		else
		{
			newext =  g_strdup_printf("%s "					/* fullscreen
					  "%s "					/* geometry */
					  "%s "					/* geometry */
					  "%s "					/* yuv */
					  "%s "					/* yuv */
					  "%s",					/* yv12 */
					  "%s",					/* yv12 */
 Lines 7270-7275    Link Here 
					 
					 
					 
					 
					);
					);
		}
		if (available_options.xvext)
		if (available_options.xvext)
		{
		{
 Lines 7289-7296    Link Here 
		
		
	
	
		Video_Mode_option =
		Video_Mode_option =
		
		option_string = g_strdup_printf ("-x11-mode %i "
		/* 0.72 introduces new usage of -x11-mode: */
		/* 0 = normal windowed */
		/* 1 = DGA fullscreen */
		/* 2 = Xv windowed */
		/* 3 = Xv fullscreen */
		if (available_options.newx11modeusage)
		{
			x11mode=target->x11_mode;
			if (target->xvext)
			{
				x11mode=2;
				if (target->xvfullscreen)
					x11mode=3;
			}
				
			option_string = g_strdup_printf ("-x11-mode %i "
						"-%scursor "
						"%s "				/* mitshm */
						"%s "				/* xvext */
						"%s "				/* newext */
						"-%sxsync "
						"-%sprivatecmap "
						"-%sxil "
						"-%smtxil "
						"%s ",				/* Video mode */
						x11mode,
						(target->cursor)?"":"no",
						mitshm?mitshm:"",
						vidix?vidix:"",
						newext?newext:"",
						(target->xsync)?"":"no",
						(target->privatecmap)?"":"no",
						(target->xil)?"":"no",
						(target->mtxil)?"":"no",
						Video_Mode_option?Video_Mode_option:""
						);
		}
		else
		{
			option_string = g_strdup_printf ("-x11-mode %i "
						"-%scursor "
						"-%scursor "
						"%s "				/* mitshm */
						"%s "				/* mitshm */
						"%s "				/* xvext */
						"%s "				/* xvext */
 Lines 7312-7318    Link Here 
						(target->xil)?"":"no",
						(target->xil)?"":"no",
						(target->mtxil)?"":"no",
						(target->mtxil)?"":"no",
						Video_Mode_option?Video_Mode_option:""
						Video_Mode_option?Video_Mode_option:""
						);
						);						
		}
		g_free(Video_Mode_option);
		g_free(Video_Mode_option);
		g_free(xvext);
		g_free(xvext);
		g_free(vidix);
		g_free(vidix);