Using WebSocket tunnnel for connection (HTTP Tunnel temporarily disabled - need suppo...
[guacamole.git] / src / main / webapp / client.xhtml
index fb8c20c..1a319ea 100644 (file)
             window.onload = function() {
                 window.setTimeout(function() {
 
+                    var tunnel;
+
+                    // TODO: Detect WebSocket and websocket-tunnel
+                    tunnel = new Guacamole.WebSocketTunnel("websocket-tunnel")
+                    //tunnel = new Guacamole.HTTPTunnel("tunnel")
+
                     // Instantiate client
-                    var guac = new Guacamole.Client(
-                        new Guacamole.HTTPTunnel("tunnel")
-                    );
+                    var guac = new Guacamole.Client(tunnel);
 
                     // Add client to UI
                     guac.getDisplay().className = "software-cursor";