[orca] Add some debugging output to characterOffsetInParent



commit 3921a067925f3b3faf1ff26ba8ab5cbdac564349
Author: Joanmarie Diggs <jdiggs igalia com>
Date:   Tue May 12 14:25:33 2015 -0400

    Add some debugging output to characterOffsetInParent

 src/orca/script_utilities.py |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)
---
diff --git a/src/orca/script_utilities.py b/src/orca/script_utilities.py
index 90e641c..af6557f 100644
--- a/src/orca/script_utilities.py
+++ b/src/orca/script_utilities.py
@@ -1562,7 +1562,8 @@ class Utilities:
         try:
             hyperlink = obj.queryHyperlink()
         except NotImplementedError:
-            pass
+            msg = "INFO: %s does not implement the hyperlink interface" % obj
+            debug.println(debug.LEVEL_INFO, msg)
         else:
             # We need to make sure that this is an embedded object in
             # some accessible text (as opposed to an imagemap link).
@@ -1571,7 +1572,11 @@ class Utilities:
                 obj.parent.queryText()
                 offset = hyperlink.startIndex
             except:
-                pass
+                msg = "ERROR: Exception getting startIndex for %s in parent %s" % (obj, obj.parent)
+                debug.println(debug.LEVEL_INFO, msg)
+            else:
+                msg = "INFO: startIndex of %s is %i" % (obj, offset)
+                debug.println(debug.LEVEL_INFO, msg)
 
         return offset
 


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