orca r3836 - in trunk: . src/orca src/orca/scripts



Author: richb
Date: Sat Apr 19 17:07:46 2008
New Revision: 3836
URL: http://svn.gnome.org/viewvc/orca?rev=3836&view=rev

Log:
        * src/orca/scripts/gnome-terminal.py:
          src/orca/default.py:
          Fix for bug #519901 - Orca doesn't warn via braille that an
          inaccessible object got the focus.


Modified:
   trunk/ChangeLog
   trunk/src/orca/default.py
   trunk/src/orca/scripts/gnome-terminal.py

Modified: trunk/src/orca/default.py
==============================================================================
--- trunk/src/orca/default.py	(original)
+++ trunk/src/orca/default.py	Sat Apr 19 17:07:46 2008
@@ -1005,6 +1005,8 @@
             self.onValueChanged
         listeners["window:activate"]                        = \
             self.onWindowActivated
+        listeners["window:deactivate"]                      = \
+            self.onWindowDeactivated
 
         return listeners
 
@@ -3778,6 +3780,12 @@
              event.source.getApplication()):
             speech.stop()
 
+            # Clear the braille display just in case we are about to give
+            # focus to an inaccessible application. See bug #519901 for
+            # more details.
+            #
+            braille.clear()
+
         # Because window activated and deactivated events may be
         # received in any order when switching from one application to
         # another, locusOfFocus and activeWindow, we really only change

Modified: trunk/src/orca/scripts/gnome-terminal.py
==============================================================================
--- trunk/src/orca/scripts/gnome-terminal.py	(original)
+++ trunk/src/orca/scripts/gnome-terminal.py	Sat Apr 19 17:07:46 2008
@@ -93,7 +93,8 @@
         # and if the old locus of focus also had a "terminal role.
         # See bug #518762 for more details.
         #
-        if newLocusOfFocus.getRole() == pyatspi.ROLE_TERMINAL:
+        if newLocusOfFocus and \
+           newLocusOfFocus.getRole() == pyatspi.ROLE_TERMINAL:
             pageTab = event.source.parent.parent.parent
             if oldLocusOfFocus.getRole() == pyatspi.ROLE_TERMINAL and \
                pageTab.getRole() == pyatspi.ROLE_PAGE_TAB and \



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