summaryrefslogtreecommitdiff
path: root/hw/xwin/winprocarg.c
diff options
context:
space:
mode:
authorJon TURNEY <jon.turney@dronecode.org.uk>2010-03-24 22:41:22 +0000
committerJon TURNEY <jon.turney@dronecode.org.uk>2012-01-26 14:40:25 +0000
commit74af860f9a59332f6ed1ac9b3e7867fbbb3d7305 (patch)
treea29dc35b02d59666919f57367528623df483b22b /hw/xwin/winprocarg.c
parentc0f3709501a0afd3bf77e783f11d2c2e5f489d3b (diff)
hw/xwin: turn on -emulate3buttons if less than 3 mouse buttons are reported
Try to be more intelligent with default options, turn on -emulate3buttons by default if less than 3 mouse buttons are reported by Windows Also, add -noemulate3buttons option so this default setting can be reversed if desired Also, correctly report the number of mouse buttons windows is reporting, rather than always at least 3 Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Diffstat (limited to 'hw/xwin/winprocarg.c')
-rw-r--r--hw/xwin/winprocarg.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/hw/xwin/winprocarg.c b/hw/xwin/winprocarg.c
index 6553e72f8..9bec84141 100644
--- a/hw/xwin/winprocarg.c
+++ b/hw/xwin/winprocarg.c
@@ -141,7 +141,7 @@ winInitializeScreenDefaults(void)
defaultScreenInfo.fLessPointer = FALSE;
defaultScreenInfo.iResizeMode = notAllowed;
defaultScreenInfo.fNoTrayIcon = FALSE;
- defaultScreenInfo.iE3BTimeout = WIN_E3B_OFF;
+ defaultScreenInfo.iE3BTimeout = WIN_E3B_DEFAULT;
defaultScreenInfo.fUseWinKillKey = WIN_DEFAULT_WIN_KILL;
defaultScreenInfo.fUseUnixKillKey = WIN_DEFAULT_UNIX_KILL;
defaultScreenInfo.fIgnoreInput = FALSE;
@@ -789,6 +789,17 @@ ddxProcessArgument (int argc, char *argv[], int i)
}
/*
+ * Look for the '-noemulate3buttons' argument
+ */
+ if (IS_OPTION ("-noemulate3buttons"))
+ {
+ screenInfoPtr->iE3BTimeout = WIN_E3B_OFF;
+
+ /* Indicate that we have processed this argument */
+ return 1;
+ }
+
+ /*
* Look for the '-depth n' argument
*/
if (IS_OPTION ("-depth"))