[orca/gnome-3-12] Fix a hang that can occur when using structural navigation with Evince forms



commit bdc714a96c1ee5dd24546a3e99d329101748158d
Author: Joanmarie Diggs <jdiggs igalia com>
Date:   Fri Jun 27 14:59:05 2014 -0400

    Fix a hang that can occur when using structural navigation with Evince forms

 src/orca/structural_navigation.py |   15 ++++++++++-----
 1 files changed, 10 insertions(+), 5 deletions(-)
---
diff --git a/src/orca/structural_navigation.py b/src/orca/structural_navigation.py
index 13c55ae..cfa534e 100644
--- a/src/orca/structural_navigation.py
+++ b/src/orca/structural_navigation.py
@@ -853,11 +853,16 @@ class StructuralNavigation:
         # object rather than the current caret offset. See bug 567984.
         #
         if isNext and self._script.utilities.isSameObject(obj, document):
-            pred = self.isAfterDocumentOffset
-            if criteria.applyPredicate:
-                pred = pred and structuralNavigationObject.predicate
-            criteria.applyPredicate = True
-            structuralNavigationObject.predicate = pred
+            try:
+                document.queryText()
+            except NotImplementedError:
+                pass
+            else:
+                pred = self.isAfterDocumentOffset
+                if criteria.applyPredicate:
+                    pred = pred and structuralNavigationObject.predicate
+                criteria.applyPredicate = True
+                structuralNavigationObject.predicate = pred
 
         rule = collection.createMatchRule(criteria.states.raw(),
                                           criteria.matchStates,


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