[Spice-devel] [PATCH xf86-video-qxl 3/4 v2] Correct the XSpice AgentMouse configuration options.

Jeremy White jwhite at codeweavers.com
Mon Oct 19 12:33:57 PDT 2015


Since the introduction of vdagent support in commit
294daff7ea930f338ec6d77ec3465b6f727c168e, the
SpiceAgentMouse setting has not really operated correctly.

That is, if SpiceVdagentEnabled was true, the value
of SpiceAgentMouse was overridden.

This patch corrects that.

It also shifts the default; that matches qemu, and effectively
preserves the current default behavior.

Signed-off-by: Jeremy White <jwhite at codeweavers.com>
---
 examples/spiceqxl.xorg.conf.example | 6 +++---
 src/qxl_driver.c                    | 3 +--
 src/spiceqxl_uinput.c               | 1 -
 3 files changed, 4 insertions(+), 6 deletions(-)

diff --git a/examples/spiceqxl.xorg.conf.example b/examples/spiceqxl.xorg.conf.example
index d15f7f2..9b223c8 100644
--- a/examples/spiceqxl.xorg.conf.example
+++ b/examples/spiceqxl.xorg.conf.example
@@ -126,9 +126,9 @@ Section "Device"
     # defaults to 16
     #Option "FrameBufferSize" "16"
 
-    # Set Spice Agent Mouse
-    # defaults to false
-    #Option "SpiceAgentMouse" "False"
+    # Set Spice Agent Mouse - Use Agent mouse if an agent connects
+    # defaults to true
+    #Option "SpiceAgentMouse" "True"
 
     # Set Spice Playback compression
     # defaults to true
diff --git a/src/qxl_driver.c b/src/qxl_driver.c
index ce0a88e..e21addd 100644
--- a/src/qxl_driver.c
+++ b/src/qxl_driver.c
@@ -98,9 +98,8 @@ const OptionInfoRec DefaultOptions[] =
       "SpiceX509Dir",             OPTV_STRING,    {0}, FALSE},
     { OPTION_SPICE_SASL,
       "SpiceSasl",                OPTV_BOOLEAN,   {0}, FALSE},
-    /* VVV qemu defaults to 1 - not implemented in xspice yet */
     { OPTION_SPICE_AGENT_MOUSE,
-      "SpiceAgentMouse",          OPTV_BOOLEAN,   {0}, FALSE},
+      "SpiceAgentMouse",          OPTV_BOOLEAN,   {0}, TRUE },
     { OPTION_SPICE_DISABLE_TICKETING,
       "SpiceDisableTicketing",    OPTV_BOOLEAN,   {0}, FALSE},
     { OPTION_SPICE_PASSWORD,
diff --git a/src/spiceqxl_uinput.c b/src/spiceqxl_uinput.c
index 38ed2ed..82065c7 100644
--- a/src/spiceqxl_uinput.c
+++ b/src/spiceqxl_uinput.c
@@ -121,7 +121,6 @@ void spiceqxl_uinput_init(qxl_screen_t *qxl)
                uinput_filename, strerror(errno));
         return;
     }
-    spice_server_set_agent_mouse(qxl->spice_server, 1);
 }
 
 void spiceqxl_uinput_watch(qxl_screen_t *qxl, Bool on)
-- 
2.1.4



More information about the Spice-devel mailing list