From 4c4a6a9bfc64de22486afbfe9f7c31adb883bd35 Mon Sep 17 00:00:00 2001 From: Michael Jumper Date: Thu, 22 May 2014 15:09:02 -0700 Subject: [PATCH] GUAC-708: Do not allow user selection within text input (in case a user presses Ctrl+A, for example). --- guacamole/src/main/webapp/scripts/client-ui.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/guacamole/src/main/webapp/scripts/client-ui.js b/guacamole/src/main/webapp/scripts/client-ui.js index 3e7eacb77..742afcafa 100644 --- a/guacamole/src/main/webapp/scripts/client-ui.js +++ b/guacamole/src/main/webapp/scripts/client-ui.js @@ -2244,6 +2244,11 @@ GuacUI.Client.attach = function(guac) { }, false); + // Do not allow event target contents to be selected during input + GuacUI.Client.text_input.target.addEventListener("selectstart", function(e) { + e.preventDefault(); + }, false); + /* * Zoom */