orca r4319 - in trunk: . src/orca
- From: joanied svn gnome org
- To: svn-commits-list gnome org
- Subject: orca r4319 - in trunk: . src/orca
- Date: Tue, 4 Nov 2008 14:44:41 +0000 (UTC)
Author: joanied
Date: Tue Nov 4 14:44:41 2008
New Revision: 4319
URL: http://svn.gnome.org/viewvc/orca?rev=4319&view=rev
Log:
* src/orca/structural_navigation.py:
Fix for bug #556470 - Orca should not land on empty (cell-less)
tables when using structural navigation by table.
Modified:
trunk/ChangeLog
trunk/src/orca/structural_navigation.py
Modified: trunk/src/orca/structural_navigation.py
==============================================================================
--- trunk/src/orca/structural_navigation.py (original)
+++ trunk/src/orca/structural_navigation.py Tue Nov 4 14:44:41 2008
@@ -3149,7 +3149,7 @@
"""
role = [pyatspi.ROLE_TABLE]
- return MatchCriteria(collection, roles=role)
+ return MatchCriteria(collection, roles=role, applyPredicate=True)
def _tablePredicate(self, obj, arg=None):
"""The predicate to be used for verifying that the object
@@ -3161,7 +3161,13 @@
the criteria (e.g. the level of a heading).
"""
- return (obj and obj.getRole() == pyatspi.ROLE_TABLE)
+ if obj and obj.childCount and obj.getRole() == pyatspi.ROLE_TABLE:
+ try:
+ return obj.queryTable().nRows > 0
+ except:
+ pass
+
+ return False
def _tablePresentation(self, obj, arg=None):
"""Presents the table or indicates that one was not found.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]