diff options
| author | Michael Vogt <michael.vogt@ubuntu.com> | 2006-04-28 22:59:47 +0200 |
|---|---|---|
| committer | Michael Vogt <michael.vogt@ubuntu.com> | 2006-04-28 22:59:47 +0200 |
| commit | 5beee1801b2847ed60ac560fa4655951bf9eda02 (patch) | |
| tree | 8dc4c666dafde15452f1a7caa6929ba02cfe898b /UpdateManager/UpdateManager.py | |
| parent | 913c45306237246a0a1236fb31a5955eb143282a (diff) | |
| parent | d19de868ff0230aebfc0920bd31caa64d51ec920 (diff) | |
| download | python-apt-5beee1801b2847ed60ac560fa4655951bf9eda02.tar.gz | |
* merged from glatzor
Diffstat (limited to 'UpdateManager/UpdateManager.py')
| -rw-r--r-- | UpdateManager/UpdateManager.py | 54 |
1 files changed, 6 insertions, 48 deletions
diff --git a/UpdateManager/UpdateManager.py b/UpdateManager/UpdateManager.py index 6ac83197..648d5f39 100644 --- a/UpdateManager/UpdateManager.py +++ b/UpdateManager/UpdateManager.py @@ -437,9 +437,12 @@ class UpdateManager(SimpleGladeApp): self.textview_changes.get_buffer().set_text("") self.textview_descr.get_buffer().set_text("") else: - text_header = "<big><b>"+gettext.ngettext("You can install one update", "You can install %s updates" % len(self.store), len(self.store))+"</b></big>" - - text_download = _("Download size: %s" % apt_pkg.SizeToStr(self.dl_size)) + text_header = "<big><b>" + \ + gettext.ngettext("You can install %s update", + "You can install %s updates", + len(self.store)) % \ + len(self.store) + "</b></big>" + text_download = _("Download size: %s") % apt_pkg.SizeToStr(self.dl_size) self.notebook_details.set_sensitive(True) self.treeview_update.set_sensitive(True) self.button_install.grab_default() @@ -552,51 +555,6 @@ class UpdateManager(SimpleGladeApp): if x > 0 and y > 0: self.window_main.resize(x,y) - def on_button_preferences_clicked(self, widget): - """ start gnome-software preferences """ - # args: "-n" means we take care of the reloading of the - # package list ourself - #apt_pkg.PkgSystemUnLock() - #args = ['/usr/bin/gnome-software-properties', '-n'] - #child = subprocess.Popen(args) - #self.window_main.set_sensitive(False) - #res = None - #while res == None: - # res = child.poll() - # time.sleep(0.05) - ## while gtk.events_pending(): - # gtk.main_iteration() - # repository information changed, call "reload" - #try: - # apt_pkg.PkgSystemLock() - #except SystemError: - # print "Error geting the cache" - # apt_pkg.PkgSystemLock() - # if res > 0: - # self.on_button_reload_clicked(None) - # self.window_main.set_sensitive(True) - self.window_main.set_sensitive(False) - from SoftwareProperties import SoftwareProperties - prop = SoftwareProperties.SoftwareProperties(self.datadir, None) - prop.window_main.set_transient_for(self.window_main) - prop.run() - prop.window_main.hide() - if prop.modified: - primary = "<span weight=\"bold\" size=\"larger\">%s</span>" % \ - _("Repositories changed") - secondary = _("You need to reload the package list from the servers " - "for your changes to take effect. Do you want to do " - "this now?") - dialog = gtk.MessageDialog(self.window_main, 0, - gtk.MESSAGE_INFO,gtk.BUTTONS_YES_NO,"") - dialog.set_markup(primary); - dialog.format_secondary_text(secondary); - res = dialog.run() - dialog.destroy() - if res == gtk.RESPONSE_YES: - self.on_button_reload_clicked(None) - self.window_main.set_sensitive(True) - def fillstore(self): # use the watch cursor self.window_main.window.set_cursor(gtk.gdk.Cursor(gtk.gdk.WATCH)) |
