orca r4283 - in trunk: . src/orca/scripts/toolkits/Gecko



Author: joanied
Date: Thu Oct  9 06:18:31 2008
New Revision: 4283
URL: http://svn.gnome.org/viewvc/orca?rev=4283&view=rev

Log:
* src/orca/scripts/toolkits/Gecko/script.py:
  Started work on bug #554831 - Google calendar unusable with orca.
  Please note that Google calendar is still unusable with Orca. This
  part of the fix just prevents a hang.


Modified:
   trunk/ChangeLog
   trunk/src/orca/scripts/toolkits/Gecko/script.py

Modified: trunk/src/orca/scripts/toolkits/Gecko/script.py
==============================================================================
--- trunk/src/orca/scripts/toolkits/Gecko/script.py	(original)
+++ trunk/src/orca/scripts/toolkits/Gecko/script.py	Thu Oct  9 06:18:31 2008
@@ -1538,6 +1538,18 @@
             except:
                 pass
 
+        elif eventSourceRole != pyatspi.ROLE_LINK \
+             and self.inDocumentContent(event.source) \
+             and not self.isAriaWidget():
+            [obj, characterOffset] = \
+                self.findFirstCaretContext(event.source, 0)
+            self.setCaretContext(obj, characterOffset)
+            if not self.isSameObject(event.source, obj):
+                if not self.isSameObject(obj, orca_state.locusOfFocus):
+                    orca.setLocusOfFocus(event, obj, False)
+                    self.presentLine(obj, characterOffset)
+                return
+
         default.Script.onFocus(self, event)
 
     def onLinkSelected(self, event):
@@ -4213,6 +4225,13 @@
                     return self.findFirstCaretContext(obj, characterOffset + 1)
                 else:
                     return [obj, characterOffset]
+        elif obj.getRole() == pyatspi.ROLE_TABLE:
+            if obj[0] and obj[0].getRole() in [pyatspi.ROLE_CAPTION,
+                                               pyatspi.ROLE_LIST]:
+                obj = obj[0]
+            else:
+                obj = obj.queryTable().getAccessibleAt(0, 0)
+            return self.findFirstCaretContext(obj, 0)
         else:
             return [obj, -1]
 



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