summaryrefslogtreecommitdiff
path: root/UpdateManager
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2006-09-05 13:18:47 +0200
committerMichael Vogt <michael.vogt@ubuntu.com>2006-09-05 13:18:47 +0200
commit0704ed7155433750011e128550a8fb55d94121c0 (patch)
tree1b84dd739467e8329988140486ccb8d5528525a7 /UpdateManager
parent6d41b5e07b5b58a0d14e4ef12f4c39c658e6da5c (diff)
downloadpython-apt-0704ed7155433750011e128550a8fb55d94121c0.tar.gz
* DistUpgrade/forced_obsoletes.txt:
- no longer needed, part of DistUpgrade.cfg now * DistUpgrade/mirrors.txt, DistUpgrade/removal_blacklist.txt: - renamed for consitency * DistUpgrade/DistUpgrade.cfg, DistUpgrade/DistUpgradeCache.py: - added "RemovalBlacklistFile" instead of hardcoding it * DistUpgrade/DistUpgradeConfigParser.py: - added "datadir" to constructor * DistUpgrade/DistUpgradeControler.py: - added datadir * DistUpgrade/DistUpgradeView.py: - added "hideStep()" method - added STEP_PREPARE, STEP_MODIFY_SOURCES, STEP_FETCH_INSTALL, STEP_CLEANUP, STEP_REBOOT * DistUpgrade/DistUpgradeViewGtk.py: - implemendted hideStep() - added datadir arguemnt for constructor * dist-upgrade.py - run it with the "." as arguemnt for the config * UpdateManager/UpdateManager.py: - if it can't be updated, ask about a dist-upgrade instead * update-manager. - added --dist-upgrade * po/*.po - make update-po
Diffstat (limited to 'UpdateManager')
-rw-r--r--UpdateManager/UpdateManager.py45
1 files changed, 19 insertions, 26 deletions
diff --git a/UpdateManager/UpdateManager.py b/UpdateManager/UpdateManager.py
index 3e958db0..240c2471 100644
--- a/UpdateManager/UpdateManager.py
+++ b/UpdateManager/UpdateManager.py
@@ -261,37 +261,30 @@ class UpdateList:
# check if we have held-back something
if cache._depcache.KeepCount > 0:
- #print "WARNING, keeping packages"
+ keepcount = cache._depcache.KeepCount
msg = ("<big><b>%s</b></big>\n\n%s" % \
(_("Cannot install all available updates"),
- _("Some updates require the removal of further software. "
- "Use the function \"Mark All Upgrades\" of the package manager "
- "\"Synaptic\" or run \"sudo apt-get dist-upgrade\" in a "
- "terminal to update your system completely.")))
- dialog = gtk.MessageDialog(self.parent_window, 0, gtk.MESSAGE_INFO,
- gtk.BUTTONS_CLOSE,"")
- dialog.set_default_response(gtk.RESPONSE_OK)
+ _("Some of the updates require more extensive changes "
+ "than expected.\n\n"
+ "This usually means that you have enabled unoffical "
+ "repositories, that it is not "
+ "fully upgraded from the last distribution release or "
+ "that you run a development release "
+ "of the distribution.\n\n"
+ "Would you like to perform a full distribution upgrade "
+ "now?")))
+ dialog = gtk.MessageDialog(self.parent_window, 0,
+ gtk.MESSAGE_QUESTION,
+ gtk.BUTTONS_YES_NO,"")
+ dialog.set_default_response(gtk.RESPONSE_NO)
dialog.set_markup(msg)
dialog.set_title("")
dialog.vbox.set_spacing(6)
- label = gtk.Label(_("The following updates will be skipped:"))
- label.set_alignment(0.0,0.5)
- dialog.set_border_width(6)
- label.show()
- dialog.vbox.pack_start(label)
- scroll = gtk.ScrolledWindow()
- scroll.set_size_request(-1,200)
- scroll.set_policy(gtk.POLICY_AUTOMATIC, gtk.POLICY_AUTOMATIC)
- text = gtk.TextView()
- text.set_editable(False)
- text.set_cursor_visible(False)
- buf = text.get_buffer()
- held_back.sort()
- buf.set_text("\n".join(held_back))
- scroll.add(text)
- dialog.vbox.pack_start(scroll)
- scroll.show_all()
- dialog.run()
+ res = dialog.run()
+ if res == gtk.RESPONSE_YES:
+ os.execl("/usr/bin/gksu",
+ "/usr/bin/gksu",
+ "/usr/bin/update-manager --dist-upgrade")
dialog.destroy()