[orca] Handle another case of objects going defunct on us
- From: Joanmarie Diggs <joanied src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [orca] Handle another case of objects going defunct on us
- Date: Thu, 9 Jun 2016 11:52:26 +0000 (UTC)
commit f106019c607aa3073b9d1ac7638db3632d41cb4f
Author: Joanmarie Diggs <jdiggs igalia com>
Date: Thu Jun 9 07:50:55 2016 -0400
Handle another case of objects going defunct on us
src/orca/script_utilities.py | 9 ++++++++-
1 files changed, 8 insertions(+), 1 deletions(-)
---
diff --git a/src/orca/script_utilities.py b/src/orca/script_utilities.py
index 4b93e55..0e9d076 100644
--- a/src/orca/script_utilities.py
+++ b/src/orca/script_utilities.py
@@ -3486,7 +3486,14 @@ class Utilities:
return table.getAccessibleAt(row, column)
def isLastCell(self, obj):
- if not (obj and obj.getRole() == pyatspi.ROLE_TABLE_CELL):
+ try:
+ role = obj.getRole()
+ except:
+ msg = "ERROR: Exception getting role of %s" % obj
+ debug.println(debug.LEVEL_INFO, msg, True)
+ return False
+
+ if not role == pyatspi.ROLE_TABLE_CELL:
return False
isTable = lambda x: x and 'Table' in pyatspi.listInterfaces(x)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]