[orca] Update spellchecking support to handle changes in Thunderbird



commit 0a71347f8ed7a1398465d8e5682ab9bdfbd29f40
Author: Joanmarie Diggs <jdiggs igalia com>
Date:   Mon May 25 13:47:43 2015 -0400

    Update spellchecking support to handle changes in Thunderbird

 src/orca/scripts/apps/Thunderbird/spellcheck.py |    2 +-
 src/orca/spellcheck.py                          |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/orca/scripts/apps/Thunderbird/spellcheck.py b/src/orca/scripts/apps/Thunderbird/spellcheck.py
index 4099a32..317067c 100644
--- a/src/orca/scripts/apps/Thunderbird/spellcheck.py
+++ b/src/orca/scripts/apps/Thunderbird/spellcheck.py
@@ -71,6 +71,6 @@ class SpellCheck(spellcheck.SpellCheck):
         return pyatspi.findDescendant(root, isError)
 
     def _findSuggestionsList(self, root):
-        isList = lambda x: x and x.getRole() == pyatspi.ROLE_LIST \
+        isList = lambda x: x and x.getRole() in [pyatspi.ROLE_LIST, pyatspi.ROLE_LIST_BOX] \
                   and 'Selection' in x.get_interfaces()
         return pyatspi.findDescendant(root, isList)
diff --git a/src/orca/spellcheck.py b/src/orca/spellcheck.py
index e6e30de..54816ac 100644
--- a/src/orca/spellcheck.py
+++ b/src/orca/spellcheck.py
@@ -206,7 +206,7 @@ class SpellCheck:
         if not entry:
             return False
 
-        label = self._script.utilities.displayedLabel(entry)
+        label = self._script.utilities.displayedLabel(entry) or entry.name
         string = self._script.utilities.substring(entry, 0, -1)
         voice = self._script.voices.get(settings.DEFAULT_VOICE)
         self._script.speakMessage("%s %s" % (label, string), voice=voice)


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