if the due counts are disabled, hide in titlebar too

This commit is contained in:
Damien Elmes 2009-04-07 11:31:56 +09:00
parent 8f2f01340a
commit 9418b62c7a
2 changed files with 11 additions and 8 deletions

View file

@ -1825,13 +1825,16 @@ it to your friends.
deckpath = self.deck.name() deckpath = self.deck.name()
if self.deck.modifiedSinceSave(): if self.deck.modifiedSinceSave():
deckpath += "*" deckpath += "*"
title = _("%(path)s (%(due)d of %(cards)d due)" if not self.config['showProgress']:
" - %(title)s") % { title = deckpath + " - " + title
"path": deckpath, else:
"title": title, title = _("%(path)s (%(due)d of %(cards)d due)"
"cards": self.deck.cardCount, " - %(title)s") % {
"due": self.deck.failedSoonCount + self.deck.revCount "path": deckpath,
} "title": title,
"cards": self.deck.cardCount,
"due": self.deck.failedSoonCount + self.deck.revCount
}
self.setWindowTitle(title) self.setWindowTitle(title)
def setStatus(self, text, timeout=3000): def setStatus(self, text, timeout=3000):

View file

@ -100,7 +100,7 @@
<item> <item>
<widget class="QCheckBox" name="showProgress" > <widget class="QCheckBox" name="showProgress" >
<property name="text" > <property name="text" >
<string>Show information in status bar</string> <string>Show due count, ETA and performance bars</string>
</property> </property>
</widget> </widget>
</item> </item>