[orca] Eliminate double-presentation of caret-moved events from mouse clicks



commit 302d662fe58967405226888e32c7a2b2fc157d20
Author: Joanmarie Diggs <joanmarie diggs gmail com>
Date:   Tue Jan 21 09:34:17 2020 -0500

    Eliminate double-presentation of caret-moved events from mouse clicks

 src/orca/scripts/web/script.py | 5 +++++
 1 file changed, 5 insertions(+)
---
diff --git a/src/orca/scripts/web/script.py b/src/orca/scripts/web/script.py
index 1c83b3a92..85d80520e 100644
--- a/src/orca/scripts/web/script.py
+++ b/src/orca/scripts/web/script.py
@@ -1445,6 +1445,11 @@ class Script(default.Script):
             return True
 
         if self._lastCommandWasMouseButton:
+            if (event.source, event.detail1) == self.utilities.getCaretContext():
+                msg = "WEB: Event is for current caret context."
+                debug.println(debug.LEVEL_INFO, msg, True)
+                return True
+
             msg = "WEB: Event handled: Last command was mouse button"
             debug.println(debug.LEVEL_INFO, msg, True)
             self.utilities.setCaretContext(event.source, event.detail1)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]