[orca] Don't filter out labels without names when getting unrelated labels
- From: Joanmarie Diggs <joanied src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [orca] Don't filter out labels without names when getting unrelated labels
- Date: Fri, 2 Oct 2015 18:37:18 +0000 (UTC)
commit 0120de847fd3dae6acbdb54f742764106b3995aa
Author: Joanmarie Diggs <jdiggs igalia com>
Date: Fri Oct 2 14:34:49 2015 -0400
Don't filter out labels without names when getting unrelated labels
Some labels expose their contents via the accesible text interface.
src/orca/script_utilities.py | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
---
diff --git a/src/orca/script_utilities.py b/src/orca/script_utilities.py
index 566f67f..9307456 100644
--- a/src/orca/script_utilities.py
+++ b/src/orca/script_utilities.py
@@ -1558,7 +1558,6 @@ class Utilities:
allLabels = pyatspi.findAllDescendants(root, hasRole)
try:
labels = [x for x in allLabels if not x.getRelationSet()]
- labels = [x for x in labels if x.parent and x.name != x.parent.name]
if onlyShowing:
labels = [x for x in labels if x.getState().contains(pyatspi.STATE_SHOWING)]
except:
@@ -1567,7 +1566,7 @@ class Utilities:
# Eliminate duplicates
d = {}
for label in labels:
- if label.name == root.name:
+ if label.name and label.name in [root.name, label.parent.name]:
continue
d[label.name] = label
labels = list(d.values())
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]