From 750461e3ba9e58b653ae7980296d6a0498865642 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Wed, 4 Mar 2009 12:20:49 -0800 Subject: [PATCH] Fix #1983 (Schedule news download - user and password fields) --- src/calibre/gui2/dialogs/scheduler.py | 11 +- src/calibre/gui2/dialogs/scheduler.ui | 459 ++++++++++++-------------- 2 files changed, 222 insertions(+), 248 deletions(-) diff --git a/src/calibre/gui2/dialogs/scheduler.py b/src/calibre/gui2/dialogs/scheduler.py index 58e5935b66..2e4a296407 100644 --- a/src/calibre/gui2/dialogs/scheduler.py +++ b/src/calibre/gui2/dialogs/scheduler.py @@ -366,9 +366,14 @@ class SchedulerDialog(QDialog, Ui_Dialog): def show_recipe(self, index): recipe = self._model.data(index, Qt.UserRole) self.current_recipe = recipe - self.title.setText(recipe.title) - self.author.setText(_('Created by: ') + recipe.author) - self.description.setText(recipe.description if recipe.description else '') + self.blurb.setText(''' +

+ %(title)s
+ %(cb)s %(author)s
+ %(description)s +

+ '''%dict(title=recipe.title, cb=_('Created by: '), author=recipe.author, + description=recipe.description if recipe.description else '')) self.allow_scheduling = False schedule = -1 if recipe.schedule is None else recipe.schedule if schedule < 1e5 and schedule >= 0: diff --git a/src/calibre/gui2/dialogs/scheduler.ui b/src/calibre/gui2/dialogs/scheduler.ui index 808fd0a0d2..c4e4487673 100644 --- a/src/calibre/gui2/dialogs/scheduler.ui +++ b/src/calibre/gui2/dialogs/scheduler.ui @@ -55,252 +55,221 @@ - - - Schedule for download + + + QFrame::NoFrame - - - - - - 75 - true - - - - title - - - Qt::PlainText - - - - - - - description - - - true - - - - - - - author - - - - - - - Qt::Vertical - - - - 20 - 40 - - - - - - - - &Schedule for download: - - - - - - - false - - - - - - - - Every - - - - - - - - - - at - - - - - - - - - - Qt::Horizontal - - - - 40 - 20 - - - - - - - - - - - - Every - - - - - - - - 0 - 0 - - - - Interval at which to download this recipe. A value of zero means that the recipe will be downloaded every hour. - - - days - - - 1 - - - 0.000000000000000 - - - 365.100000000000023 - - - 1.000000000000000 - - - 1.000000000000000 - - - - - - - - - - - - - - - true - - - - - - - &Account - - - - - - - - - &Username: - - - username - - - - - - - &Password: - - - password - - - - - - - QLineEdit::Password - - - - - - - &Show password - - - - - - - - - - Qt::Vertical - - - - 20 - 40 - - - - - - - - For the scheduling to work, you must leave calibre running. - - - true - - - - - - - &Download now - - - - - - - Qt::Vertical - - - - 20 - 40 - - - - - + + true + + + + + 0 + 0 + 361 + 500 + + + + + 0 + + + + + Schedule for download + + + + + + blurb + + + Qt::RichText + + + true + + + true + + + + + + + &Schedule for download: + + + + + + + false + + + + + + + + Every + + + + + + + + + + at + + + + + + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + + + + + Every + + + + + + + + 0 + 0 + + + + Interval at which to download this recipe. A value of zero means that the recipe will be downloaded every hour. + + + days + + + 1 + + + 0.000000000000000 + + + 365.100000000000023 + + + 1.000000000000000 + + + 1.000000000000000 + + + + + + + + + + + + + + + true + + + + + + + &Account + + + + + + + + + &Username: + + + username + + + + + + + &Password: + + + password + + + + + + + QLineEdit::Password + + + + + + + &Show password + + + + + + + + + + For the scheduling to work, you must leave calibre running. + + + true + + + + + + + &Download now + + + + + + + +