[orca] Re-enable looking for unrelated labels in gnome-shell notifications



commit 41b75dfda92dfbbd2db21bab8ca564963fd2b644
Author: Joanmarie Diggs <jdiggs igalia com>
Date:   Tue Jul 10 12:37:37 2018 -0400

    Re-enable looking for unrelated labels in gnome-shell notifications

 src/orca/scripts/apps/gnome-shell/script_utilities.py | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/src/orca/scripts/apps/gnome-shell/script_utilities.py 
b/src/orca/scripts/apps/gnome-shell/script_utilities.py
index 052d86894..c36fee7c5 100644
--- a/src/orca/scripts/apps/gnome-shell/script_utilities.py
+++ b/src/orca/scripts/apps/gnome-shell/script_utilities.py
@@ -96,9 +96,11 @@ class Utilities(script_utilities.Utilities):
         if not root:
             return []
 
-        isDialog = lambda x: x and x.getRole() == pyatspi.ROLE_DIALOG
-        if not isDialog(root) and pyatspi.findAncestor(root, isDialog) is None:
-            msg = "GNOME SHELL: Not seeking unrelated labels for non-dialog"
+        roles = [pyatspi.ROLE_DIALOG, pyatspi.ROLE_NOTIFICATION]
+
+        hasRole = lambda x: x and x.getRole() in roles
+        if not hasRole(root) and pyatspi.findAncestor(root, hasRole) is None:
+            msg = "GNOME SHELL: Not seeking unrelated labels for %s" % root
             debug.println(debug.LEVEL_INFO, msg, True)
             return []
 


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