[orca] Add some more debugging to the event manager
- From: Joanmarie Diggs <joanied src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [orca] Add some more debugging to the event manager
- Date: Thu, 29 Oct 2015 07:34:13 +0000 (UTC)
commit 73b6e3ac92c205634b7e5ae07766998eaebdea20
Author: Joanmarie Diggs <jdiggs igalia com>
Date: Thu Oct 29 15:57:40 2015 +0900
Add some more debugging to the event manager
src/orca/event_manager.py | 13 +++++++++++++
1 files changed, 13 insertions(+), 0 deletions(-)
---
diff --git a/src/orca/event_manager.py b/src/orca/event_manager.py
index 625e16e..fd73f70 100644
--- a/src/orca/event_manager.py
+++ b/src/orca/event_manager.py
@@ -96,19 +96,30 @@ class EventManager:
def _ignore(self, event):
"""Returns True if this event should be ignored."""
+ msg = '\nINFO: %s for %s in %s' % (event.type, event.source, event.host_application)
+ debug.println(debug.LEVEL_INFO, msg)
+
if not self._active:
+ msg = 'INFO: Ignoring because event manager is not active'
+ debug.println(debug.LEVEL_INFO, msg)
return True
if list(filter(event.type.startswith, self._ignoredEvents)):
+ msg = 'INFO: Ignoring because event type is ignored'
+ debug.println(debug.LEVEL_INFO, msg)
return True
if event.type.startswith('window'):
+ msg = 'INFO: Not ignoring because event type is never ignored'
+ debug.println(debug.LEVEL_INFO, msg)
return False
# This should ultimately be changed as there are valid reasons
# to handle these events at the application level.
if event.type.startswith('object:children-changed:remove') \
and event.source != self.registry.getDesktop(0):
+ msg = 'INFO: Ignoring because event type is ignored'
+ debug.println(debug.LEVEL_INFO, msg)
return True
if event.type.startswith('object:text-changed') and event.type.endswith('system'):
@@ -182,6 +193,8 @@ class EventManager:
debug.println(debug.LEVEL_INFO, msg)
return True
+ msg = 'INFO: Not ignoring due to lack of cause'
+ debug.println(debug.LEVEL_INFO, msg)
return False
def _addToQueue(self, event, asyncMode):
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]