[orca] Fix presentation of caret-moved events for Firefox's autocompletes



commit 57b0e8f74f3ea6c4a61979be27b2e64cb0c86412
Author: Joanmarie Diggs <jdiggs igalia com>
Date:   Mon Mar 31 12:49:36 2014 -0400

    Fix presentation of caret-moved events for Firefox's autocompletes

 src/orca/scripts/toolkits/Gecko/script.py          |    1 +
 .../scripts/toolkits/Gecko/script_utilities.py     |    9 +++++++++
 2 files changed, 10 insertions(+), 0 deletions(-)
---
diff --git a/src/orca/scripts/toolkits/Gecko/script.py b/src/orca/scripts/toolkits/Gecko/script.py
index bbf30c1..f7a92e5 100644
--- a/src/orca/scripts/toolkits/Gecko/script.py
+++ b/src/orca/scripts/toolkits/Gecko/script.py
@@ -995,6 +995,7 @@ class Script(default.Script):
 
         if self.utilities.inFindToolbar():
             self.presentFindResults(event.source, -1)
+            self._saveFocusedObjectInfo(orca_state.locusOfFocus)
             return
 
         if not self.inDocumentContent(orca_state.locusOfFocus) \
diff --git a/src/orca/scripts/toolkits/Gecko/script_utilities.py 
b/src/orca/scripts/toolkits/Gecko/script_utilities.py
index ba4b299..6c61050 100644
--- a/src/orca/scripts/toolkits/Gecko/script_utilities.py
+++ b/src/orca/scripts/toolkits/Gecko/script_utilities.py
@@ -232,6 +232,15 @@ class Utilities(script_utilities.Utilities):
 
         return False
 
+    def inFindToolbar(self, obj=None):
+        if not obj:
+            obj = orca_state.locusOfFocus
+
+        if obj and obj.parent.getRole() == pyatspi.ROLE_AUTOCOMPLETE:
+            return False
+
+        return script_utilities.Utilities.inFindToolbar(obj)
+
     def isEntry(self, obj):
         """Returns True if we should treat this object as an entry."""
 


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