deskbar-applet r2051 - in trunk: . deskbar/handlers
- From: sebp svn gnome org
- To: svn-commits-list gnome org
- Subject: deskbar-applet r2051 - in trunk: . deskbar/handlers
- Date: Sun, 30 Mar 2008 12:59:02 +0100 (BST)
Author: sebp
Date: Sun Mar 30 12:59:02 2008
New Revision: 2051
URL: http://svn.gnome.org/viewvc/deskbar-applet?rev=2051&view=rev
Log:
Catch dbus.DBusException, too
Modified:
trunk/ChangeLog
trunk/deskbar/handlers/tomboy.py
Modified: trunk/deskbar/handlers/tomboy.py
==============================================================================
--- trunk/deskbar/handlers/tomboy.py (original)
+++ trunk/deskbar/handlers/tomboy.py Sun Mar 30 12:59:02 2008
@@ -27,7 +27,7 @@
def activate(self, text=None):
try:
tomboy().DisplayNote(self._note)
- except dbus.exceptions.DBusException, e:
+ except (dbus.DBusException, dbus.exceptions.DBusException), e:
LOGGER.exception(e)
return
@@ -43,7 +43,7 @@
def is_valid(self, text=None):
try:
return (not tomboy() == None) and tomboy().NoteExists(self._note)
- except dbus.exceptions.DBusException, e:
+ except (dbus.DBusException, dbus.exceptions.DBusException), e:
LOGGER.exception(e)
return False
@@ -53,7 +53,7 @@
def activate(self, text=None):
try:
if self.really_delete(): tomboy().DeleteNote(self._note)
- except dbus.exceptions.DBusException, e:
+ except (dbus.DBusException, dbus.exceptions.DBusException), e:
LOGGER.exception(e)
return
@@ -93,7 +93,7 @@
if self.is_valid():
self._note = tomboy().CreateNamedNote( self._title )
tomboy().DisplayNote(self._note)
- except dbus.exceptions.DBusException, e:
+ except (dbus.DBusException, dbus.exceptions.DBusException), e:
LOGGER.exception(e)
return
@@ -112,7 +112,7 @@
def is_valid(self, text=None):
try:
return tomboy().FindNote(self._title) == ''
- except dbus.exceptions.DBusException, e:
+ except (dbus.DBusException, dbus.exceptions.DBusException), e:
LOGGER.exception(e)
return False
@@ -176,7 +176,7 @@
match = TomboyExistingNoteMatch(note)
match.set_priority (self.get_priority())
self._emit_query_ready( text, [match] )
- except dbus.exceptions.DBusException, e:
+ except (dbus.DBusException, dbus.exceptions.DBusException), e:
LOGGER.exception(e)
return
@@ -190,7 +190,7 @@
match = TomboyCreateNoteMatch(case)
match.set_priority (self.get_priority())
self._emit_query_ready( text, [match] )
- except dbus.exceptions.DBusException, e:
+ except (dbus.DBusException, dbus.exceptions.DBusException), e:
LOGGER.exception(e)
return
@@ -201,7 +201,7 @@
# A lambda, because otherwise the handler won't get the query text
reply_handler=lambda notes: self.handle_searchnotes( text, notes ),
error_handler=self.handle_dbus_error )
- except dbus.exceptions.DBusException, e:
+ except (dbus.DBusException, dbus.exceptions.DBusException), e:
LOGGER.exception(e)
return
@@ -234,7 +234,7 @@
else:
TomboyNotesModule.INSTRUCTIONS = _("Tomboy does not seem to be installed.")
return False
- except dbus.exceptions.DBusException, e:
+ except (dbus.DBusException, dbus.exceptions.DBusException), e:
LOGGER.exception(e)
return False
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]