[Pkg-bazaar-commits] ./bzr-gtk/unstable r620: Merge fix for LP#290618: dbus plugin loading crashes vis
Jasper Groenewegen
colbrac at xs4all.nl
Fri Apr 10 07:50:58 UTC 2009
------------------------------------------------------------
revno: 620
committer: Jasper Groenewegen <colbrac at xs4all.nl>
branch nick: trunk
timestamp: Wed 2008-10-29 10:01:26 +0100
message:
Merge fix for LP#290618: dbus plugin loading crashes vis
modified:
notify.py
preferences/notifications.py
------------------------------------------------------------
revno: 619.1.1
committer: Vincent Ladeuil <v.ladeuil+lp at free.fr>
branch nick: 290618-dbus-missing
timestamp: Wed 2008-10-29 09:36:29 +0100
message:
Fix bug #290618 by using the right facilities.
* preferences/notifications.py:
(NotificationsPage): Slight cosmetic adjustments.
* notify.py:
<cough> don't import plugins.dbus just before defining a function
to check for its presence :)
modified:
notify.py
preferences/notifications.py
-------------- next part --------------
=== modified file 'notify.py'
--- a/notify.py 2008-10-28 16:02:01 +0000
+++ b/notify.py 2008-10-29 08:36:29 +0000
@@ -17,14 +17,17 @@
"""Notification area icon and notification for Bazaar."""
import gtk
-import bzrlib.plugins.dbus
+import bzrlib
+
def has_dbus():
return (getattr(bzrlib.plugins, "dbus", None) is not None)
+
def has_avahi():
return (getattr(bzrlib.plugins, "avahi", None) is not None)
+
class NotifyPopupMenu(gtk.Menu):
def __init__(self):
super(NotifyPopupMenu, self).__init__()
=== modified file 'preferences/notifications.py'
--- a/preferences/notifications.py 2008-10-28 16:02:01 +0000
+++ b/preferences/notifications.py 2008-10-29 08:36:29 +0000
@@ -25,14 +25,15 @@
from bzrlib.plugins.gtk.notify import has_avahi, has_dbus
class NotificationsPage(gtk.VBox):
- def __init__(self, config):
+ def __init__(self, config, homogeneous=False, spacing=6):
self.config = config
- gtk.VBox.__init__(self)
+ gtk.VBox.__init__(self, homogeneous=homogeneous, spacing=spacing)
+ self.set_spacing(spacing) # The vertical one
self.gateway_to_lan = gtk.CheckButton("_Gateway to LAN")
- self.pack_start(self.gateway_to_lan)
+ self.pack_start(self.gateway_to_lan, expand=False)
self.gateway_to_lan.set_sensitive(has_dbus())
self.announce_on_lan = gtk.CheckButton("_Announce on LAN")
- self.pack_start(self.announce_on_lan)
+ self.pack_start(self.announce_on_lan, expand=False)
self.announce_on_lan.set_sensitive(has_avahi())
More information about the Pkg-bazaar-commits
mailing list