def update_context(self): if module_check.has_ccm() and module_check.has_right_compiz(): import compizconfig as ccs load_ccm() self.context = ccs.Context()
label = gtk.Label() label.set_markup(_("<span size=\"x-large\">This module is error while loading.</span>")) label.set_justify(gtk.JUSTIFY_FILL) vbox.pack_start(label, False, False, 50) hbox = gtk.HBox(False, 0) vbox.pack_start(hbox, False, False, 0) return vbox from computer import Computer from session import Session from autostart import AutoStart from icons import Icon if module_check.has_right_compiz(): from compiz import Compiz else: Compiz = Notice if module_check.get_gnome_version() >= 20: from userdir import UserDir from templates import Templates else: UserDir = Notice Templates = Notice if module_check.is_ubuntu(): from installer import Installer from cleaner import PackageCleaner else:
def create_interface(self): if module_check.has_apt(): update_apt_cache(True) self.packageWorker = PackageWorker() self.advanced_settings = AptCheckButton(_("Install Advanced Desktop Effects Settings Manager"), 'compizconfig-settings-manager') self.advanced_settings.connect('toggled', self.colleague_changed) self.simple_settings = AptCheckButton(_("Install Simple Desktop Effects Settings manager"), 'simple-ccsm') self.simple_settings.connect('toggled', self.colleague_changed) self.screenlets = AptCheckButton(_("Install Screenlets Widget Application"), 'screenlets') self.screenlets.connect('toggled', self.colleague_changed) if module_check.has_ccm() and module_check.has_right_compiz(): hbox = gtk.HBox(False, 0) hbox.pack_start(self.create_edge_setting(), True, False, 0) edge_setting = SinglePack('Edge Settings', hbox) self.pack_start(edge_setting, False, False, 0) self.snap = SnapWindow(_("Enable snapping windows"), self) self.wobbly_w = WobblyWindow(_("Enable wobbly windows"), self); box = ListPack(_("Window Effects"), (self.snap, self.wobbly_w)) self.pack_start(box, False, False, 0) button1 = OpacityMenu(_("Enable transparent menus")) self.wobbly_m = WobblyMenu(_("Enable wobbly menus"), self) box = ListPack(_("Menu Effects"), (button1, self.wobbly_m)) self.pack_start(box, False, False, 0) if module_check.has_apt(): update_apt_cache(True) box = ListPack(_("Useful Extensions"), ( self.simple_settings, self.screenlets, )) self.button = gtk.Button(stock = gtk.STOCK_APPLY) self.button.connect("clicked", self.on_apply_clicked, box) self.button.set_sensitive(False) hbox = gtk.HBox(False, 0) hbox.pack_end(self.button, False, False, 0) box.vbox.pack_start(hbox, False, False, 0) self.pack_start(box, False, False, 0) else: box = ListPack(_("Prerequisite Conditions"), ( self.advanced_settings, )) self.button = gtk.Button(stock = gtk.STOCK_APPLY) self.button.connect("clicked", self.on_apply_clicked, box) self.button.set_sensitive(False) hbox = gtk.HBox(False, 0) hbox.pack_end(self.button, False, False, 0) box.vbox.pack_start(hbox, False, False, 0) self.pack_start(box, False, False, 0)