def __init__(self):
GObject.Object.__init__(self)
settings = Gio.Settings.new("org.ubuntubudgie.plugins.budgie-extras")
settings.bind("ws-overview-index", self,
'mode_index',
Gio.SettingsBindFlags.DEFAULT)
# general
self.mode = modes[self.mode_index]
self.appbutton = Gtk.Button.new()
self.appbutton.set_relief(Gtk.ReliefStyle.NONE)
icon = Gtk.Image.new_from_icon_name("1-wso", Gtk.IconSize.MENU)
self.appbutton.set_image(icon)
self.menu = Gtk.Menu()
self.create_menu()
self.update = Thread(target=self.show_seconds)
# daemonize the thread to make the indicator stopable
self.update.setDaemon(True)
self.update.start()
评论列表
文章目录