This commit is contained in:
Kovid Goyal 2008-06-11 12:36:27 -07:00
parent 069c9fb925
commit 72c304e345

View File

@ -1150,6 +1150,14 @@ class Main(MainWindow, Ui_MainWindow):
self.vanity.setText(self.vanity_template%(dict(version=self.latest_version, self.vanity.setText(self.vanity_template%(dict(version=self.latest_version,
device=self.device_info))) device=self.device_info)))
self.vanity.update() self.vanity.update()
s = Settings()
if True or s.get('update to version %s'%version, True):
d = question_dialog(self, _('Update available'), _('%s has been updated to version %s. Visit the download page?')%(__appname__, version))
if d.exec_() == QMessageBox.Yes:
url = 'http://calibre.kovidgoyal.net/download_'+('windows' if iswindows else 'osx' if isosx else 'linux')
print url
QDesktopServices.openUrl(QUrl(url))
s.set('update to version %s'%version, False)
def main(args=sys.argv): def main(args=sys.argv):