[orca] Eliminate false positive identifying Thunderbird spellcheck dialog



commit 2abfff30dd7311febe0b71efadbd35d279926674
Author: Joanmarie Diggs <jdiggs igalia com>
Date:   Mon Sep 7 12:46:15 2015 -0400

    Eliminate false positive identifying Thunderbird spellcheck dialog

 src/orca/scripts/apps/Thunderbird/spellcheck.py |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)
---
diff --git a/src/orca/scripts/apps/Thunderbird/spellcheck.py b/src/orca/scripts/apps/Thunderbird/spellcheck.py
index 9466ec1..66b3b6f 100644
--- a/src/orca/scripts/apps/Thunderbird/spellcheck.py
+++ b/src/orca/scripts/apps/Thunderbird/spellcheck.py
@@ -58,7 +58,14 @@ class SpellCheck(spellcheck.SpellCheck):
         return False
 
     def _isCandidateWindow(self, window):
-        return window and window.getRole() == pyatspi.ROLE_DIALOG
+        if not (window and window.getRole() == pyatspi.ROLE_DIALOG):
+            return False
+
+        isPageTabList = lambda x: x and x.getRole() == pyatspi.ROLE_PAGE_TAB_LIST
+        if pyatspi.findDescendant(window, isPageTabList):
+            return False
+
+        return True
 
     def _findChangeToEntry(self, root):
         isEntry = lambda x: x and x.getRole() == pyatspi.ROLE_ENTRY \


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