[orca] Fix for bug #630591 - Orca's _generateDisplayedText should return an empty list when there is no tex
- From: Joanmarie Diggs <joanied src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [orca] Fix for bug #630591 - Orca's _generateDisplayedText should return an empty list when there is no tex
- Date: Mon, 29 Nov 2010 13:27:24 +0000 (UTC)
commit 4d997deb1a50aa3753f9c474122fb5798ee1ca01
Author: Joanmarie Diggs <joanmarie diggs gmail com>
Date: Sun Oct 24 15:53:34 2010 -0400
Fix for bug #630591 - Orca's _generateDisplayedText should return an empty list when there is no text
src/orca/generator.py | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
---
diff --git a/src/orca/generator.py b/src/orca/generator.py
index 6f09457..158ed5b 100644
--- a/src/orca/generator.py
+++ b/src/orca/generator.py
@@ -879,11 +879,13 @@ class Generator:
def _generateDisplayedText(self, obj, **args ):
"""Returns an array of strings for use by speech and braille that
- represents all the text being displayed by the object. [[[WDW
- - consider returning an empty array if this is not a text
- object.]]]
+ represents all the text being displayed by the object.
"""
- return [self._script.utilities.displayedText(obj)]
+ displayedText = self._script.utilities.displayedText(obj)
+ if not displayedText:
+ return []
+
+ return [displayedText]
#####################################################################
# #
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]