[orca/orca-gnome3: 44/87] Fix for bug #645256 - Unhandled LookupError when an application is quit
- From: Alejandro Leiva <aleiva src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [orca/orca-gnome3: 44/87] Fix for bug #645256 - Unhandled LookupError when an application is quit
- Date: Fri, 1 Apr 2011 11:16:30 +0000 (UTC)
commit 67224fb677c98712eaa4c6e3a391c8628afb2a01
Author: Joanmarie Diggs <joanmarie diggs gmail com>
Date: Sat Mar 19 15:44:05 2011 -0400
Fix for bug #645256 - Unhandled LookupError when an application is quit
src/orca/event_manager.py | 16 ++++++++++++----
1 files changed, 12 insertions(+), 4 deletions(-)
---
diff --git a/src/orca/event_manager.py b/src/orca/event_manager.py
index 272a8de..bd3d04c 100644
--- a/src/orca/event_manager.py
+++ b/src/orca/event_manager.py
@@ -432,10 +432,18 @@ class EventManager:
eType = event.type
if eType.startswith("object:children-changed:remove"):
- if event.source == self.registry.getDesktop(0):
- _scriptManager.reclaimScripts()
- if settings.debugMemoryUsage:
- orca.cleanupGarbage()
+ try:
+ if event.source == self.registry.getDesktop(0):
+ _scriptManager.reclaimScripts()
+ if settings.debugMemoryUsage:
+ orca.cleanupGarbage()
+ return
+ except LookupError:
+ # If we got this error here, we'll get it again when we
+ # attempt to get the state, catch it, and clean up.
+ pass
+ except:
+ debug.printException(debug.LEVEL_WARNING)
return
# Clean up any flat review context so that Orca does not get
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]