[orca] Chromium: Handle window activate event with null children
- From: Joanmarie Diggs <joanied src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [orca] Chromium: Handle window activate event with null children
- Date: Sun, 13 Jun 2021 12:46:57 +0000 (UTC)
commit 76396d4b302b32f772941891faa9b2a553da61f5
Author: Joanmarie Diggs <jdiggs igalia com>
Date: Sun Jun 13 14:45:32 2021 +0200
Chromium: Handle window activate event with null children
src/orca/scripts/toolkits/Chromium/script.py | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
---
diff --git a/src/orca/scripts/toolkits/Chromium/script.py b/src/orca/scripts/toolkits/Chromium/script.py
index 653cf1639..62b0198a5 100644
--- a/src/orca/scripts/toolkits/Chromium/script.py
+++ b/src/orca/scripts/toolkits/Chromium/script.py
@@ -353,7 +353,7 @@ class Script(web.Script):
if super().onTextAttributesChanged(event):
return
- msg = "Chromium: Passing along event to default script"
+ msg = "CHROMIUM: Passing along event to default script"
debug.println(debug.LEVEL_INFO, msg, True)
default.Script.onTextAttributesChanged(self, event)
@@ -429,6 +429,11 @@ class Script(web.Script):
# already showing at the time of window activation. If that changes,
# we should store presented alerts so we don't double-present them.
for child in event.source:
+ if not child:
+ msg = "CHROMIUM: Event source claims null child"
+ debug.println(debug.LEVEL_INFO, msg, True)
+ continue
+
if child.getRole() == pyatspi.ROLE_ALERT:
self.presentObject(child)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]