summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristophe Fergeau <cfergeau@redhat.com>2012-04-02 17:09:28 +0200
committerChristophe Fergeau <cfergeau@redhat.com>2012-04-04 10:22:00 +0200
commit2eaa3cf7adbdffdddbed0bc6b9e87d50f8229d16 (patch)
treed612ab28666aaeeae1dbd213c2888d4f55ad78f2
parent79436bcd0d44eecef447bac23d8ea4eb4c81fb78 (diff)
controller: handle USB redirection messages
-rw-r--r--data/spice-protocol.vapi4
-rw-r--r--gtk/controller/controller.vala12
m---------spice-common0
3 files changed, 16 insertions, 0 deletions
diff --git a/data/spice-protocol.vapi b/data/spice-protocol.vapi
index 4b88175..66f1373 100644
--- a/data/spice-protocol.vapi
+++ b/data/spice-protocol.vapi
@@ -62,6 +62,10 @@ namespace SpiceProtocol {
ENABLE_SMARTCARD,
+ ENABLE_USB,
+ ENABLE_USB_AUTOSHARE,
+ USB_FILTER,
+
//spice client -> external app
MENU_ITEM_CLICK,
diff --git a/gtk/controller/controller.vala b/gtk/controller/controller.vala
index 5970aaf..185f5e0 100644
--- a/gtk/controller/controller.vala
+++ b/gtk/controller/controller.vala
@@ -43,6 +43,9 @@ public class Controller: Object {
public bool send_cad { private set; get; }
public string[] disable_effects {private set; get; }
public uint32 color_depth {private set; get; }
+ public bool enable_usbredir { private set; get; }
+ public bool enable_usb_autoshare { private set; get; }
+ public string usb_filter { private set; get; }
public signal void do_connect ();
public signal void show ();
@@ -160,6 +163,15 @@ public class Controller: Object {
case SpiceProtocol.Controller.MsgId.HIDE:
hide ();
break;
+ case SpiceProtocol.Controller.MsgId.ENABLE_USB:
+ enable_usbredir = (bool)v.value;
+ break;
+ case SpiceProtocol.Controller.MsgId.ENABLE_USB_AUTOSHARE:
+ enable_usb_autoshare = (bool)v.value;
+ break;
+ case SpiceProtocol.Controller.MsgId.USB_FILTER:
+ usb_filter = str;
+ break;
default:
warn_if_reached ();
return false;
diff --git a/spice-common b/spice-common
-Subproject 2ab866f522d8f730a93288fd82a596f00f19390
+Subproject e96dbb4172ec7a47a5b15d3b9e921e12623fdda