mirror of
https://github.com/ankitects/anki.git
synced 2025-09-21 15:32:23 -04:00
bare minimum to get the browser to show up
This commit is contained in:
parent
33d79a80ec
commit
f2865d7bf5
6 changed files with 81 additions and 170 deletions
|
@ -32,10 +32,10 @@ def openHelp(name):
|
||||||
class DialogManager(object):
|
class DialogManager(object):
|
||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
from aqt import addcards, cardlist
|
from aqt import addcards, browser
|
||||||
self._dialogs = {
|
self._dialogs = {
|
||||||
"AddCards": [addcards.AddCards, None],
|
"AddCards": [addcards.AddCards, None],
|
||||||
"CardList": [cardlist.EditDeck, None],
|
"Browser": [browser.Browser, None],
|
||||||
}
|
}
|
||||||
|
|
||||||
def open(self, name, *args):
|
def open(self, name, *args):
|
||||||
|
|
|
@ -16,12 +16,6 @@ from anki.hooks import addHook, removeHook
|
||||||
from anki.utils import stripHTMLMedia
|
from anki.utils import stripHTMLMedia
|
||||||
import aqt.editor, aqt.modelchooser
|
import aqt.editor, aqt.modelchooser
|
||||||
|
|
||||||
# todo:
|
|
||||||
# if field.fieldModel.features:
|
|
||||||
# w.setLayoutDirection(Qt.RightToLeft)
|
|
||||||
# else:
|
|
||||||
# w.setLayoutDirection(Qt.LeftToRight)
|
|
||||||
|
|
||||||
class AddCards(QDialog):
|
class AddCards(QDialog):
|
||||||
|
|
||||||
def __init__(self, mw):
|
def __init__(self, mw):
|
||||||
|
|
|
@ -125,64 +125,9 @@ class DeckModel(QAbstractTableModel):
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
def showMatching(self, force=True):
|
def showMatching(self, force=True):
|
||||||
if not self.sortKey:
|
return
|
||||||
self.cards = []
|
# if self.deck.getInt('reverseOrder'):
|
||||||
return
|
# self.cards.reverse()
|
||||||
# sorting
|
|
||||||
if not self.searchStr:
|
|
||||||
ads = ""
|
|
||||||
self.lastSearch = ""
|
|
||||||
else:
|
|
||||||
if (self.searchStr.strip() == self.lastSearch.strip()
|
|
||||||
and not force):
|
|
||||||
# just whitespace
|
|
||||||
return
|
|
||||||
QApplication.instance().processEvents()
|
|
||||||
self.lastSearch = self.searchStr
|
|
||||||
ids = self.deck.findCards(self.searchStr)
|
|
||||||
ads = "cards.id in %s" % ids2str(ids)
|
|
||||||
sort = ""
|
|
||||||
if isinstance(self.sortKey, types.StringType):
|
|
||||||
# card property
|
|
||||||
if self.sortKey == "fact":
|
|
||||||
sort = "order by facts.created, cards.created"
|
|
||||||
else:
|
|
||||||
sort = "order by cards." + self.sortKey
|
|
||||||
if self.sortKey in ("question", "answer"):
|
|
||||||
sort += " collate nocase"
|
|
||||||
if self.sortKey == "fact":
|
|
||||||
query = """
|
|
||||||
select cards.id from cards, facts
|
|
||||||
where cards.factId = facts.id """
|
|
||||||
if ads:
|
|
||||||
query += "and " + ads + " "
|
|
||||||
else:
|
|
||||||
query = "select id from cards "
|
|
||||||
if ads:
|
|
||||||
query += "where %s " % ads
|
|
||||||
query += sort
|
|
||||||
else:
|
|
||||||
# field value
|
|
||||||
ret = self.deck.db.all(
|
|
||||||
"select id, numeric from fieldModels where name = :name",
|
|
||||||
name=self.sortKey[1])
|
|
||||||
fields = ",".join([str(x[0]) for x in ret])
|
|
||||||
# if multiple models have the same field, use the first numeric bool
|
|
||||||
numeric = ret[0][1]
|
|
||||||
if numeric:
|
|
||||||
order = "cast(fields.value as real)"
|
|
||||||
else:
|
|
||||||
order = "fields.value collate nocase"
|
|
||||||
if ads:
|
|
||||||
ads = " and " + ads
|
|
||||||
query = ("select cards.id "
|
|
||||||
"from fields, cards where fields.fieldModelId in (%s) "
|
|
||||||
"and fields.factId = cards.factId" + ads +
|
|
||||||
" order by cards.ordinal, %s") % (fields, order)
|
|
||||||
# run the query
|
|
||||||
self.cards = self.deck.db.all(query)
|
|
||||||
if self.deck.getInt('reverseOrder'):
|
|
||||||
self.cards.reverse()
|
|
||||||
self.reset()
|
self.reset()
|
||||||
|
|
||||||
def updateCard(self, index):
|
def updateCard(self, index):
|
||||||
|
@ -339,19 +284,16 @@ class StatusDelegate(QItemDelegate):
|
||||||
painter.restore()
|
painter.restore()
|
||||||
return QItemDelegate.paint(self, painter, option, index)
|
return QItemDelegate.paint(self, painter, option, index)
|
||||||
|
|
||||||
class EditDeck(QMainWindow):
|
class Browser(QMainWindow):
|
||||||
|
|
||||||
def __init__(self, parent):
|
def __init__(self, mw):
|
||||||
windParent = None
|
QMainWindow.__init__(self, None)
|
||||||
QMainWindow.__init__(self, windParent)
|
|
||||||
applyStyles(self)
|
applyStyles(self)
|
||||||
self.parent = parent
|
self.mw = mw
|
||||||
self.deck = self.parent.deck
|
self.deck = self.mw.deck
|
||||||
self.config = parent.config
|
|
||||||
self.origModTime = parent.deck.modified
|
|
||||||
self.currentRow = None
|
self.currentRow = None
|
||||||
self.lastFilter = ""
|
self.lastFilter = ""
|
||||||
self.dialog = aqt.forms.cardlist.Ui_MainWindow()
|
self.dialog = aqt.forms.browser.Ui_Dialog()
|
||||||
self.dialog.setupUi(self)
|
self.dialog.setupUi(self)
|
||||||
self.setUnifiedTitleAndToolBarOnMac(True)
|
self.setUnifiedTitleAndToolBarOnMac(True)
|
||||||
restoreGeom(self, "editor", 38)
|
restoreGeom(self, "editor", 38)
|
||||||
|
@ -359,12 +301,11 @@ class EditDeck(QMainWindow):
|
||||||
restoreSplitter(self.dialog.splitter, "editor")
|
restoreSplitter(self.dialog.splitter, "editor")
|
||||||
self.dialog.splitter.setChildrenCollapsible(False)
|
self.dialog.splitter.setChildrenCollapsible(False)
|
||||||
# toolbar
|
# toolbar
|
||||||
self.dialog.toolBar.setIconSize(QSize(self.config['iconSize'],
|
self.dialog.toolBar.setIconSize(QSize(self.mw.config['iconSize'],
|
||||||
self.config['iconSize']))
|
self.mw.config['iconSize']))
|
||||||
self.dialog.toolBar.toggleViewAction().setText(_("Toggle Toolbar"))
|
self.dialog.toolBar.toggleViewAction().setText(_("Toggle Toolbar"))
|
||||||
# flush all changes before we load
|
# flush all changes before we load
|
||||||
self.deck.db.flush()
|
self.model = DeckModel(self.mw, self.mw.deck)
|
||||||
self.model = DeckModel(self.parent, self.parent.deck)
|
|
||||||
self.dialog.tableView.setSortingEnabled(False)
|
self.dialog.tableView.setSortingEnabled(False)
|
||||||
self.dialog.tableView.setShowGrid(False)
|
self.dialog.tableView.setShowGrid(False)
|
||||||
self.dialog.tableView.setModel(self.model)
|
self.dialog.tableView.setModel(self.model)
|
||||||
|
@ -383,12 +324,11 @@ class EditDeck(QMainWindow):
|
||||||
self.setupEditor()
|
self.setupEditor()
|
||||||
self.setupCardInfo()
|
self.setupCardInfo()
|
||||||
self.dialog.filterEdit.setFocus()
|
self.dialog.filterEdit.setFocus()
|
||||||
ui.dialogs.open("CardList", self)
|
|
||||||
self.drawTags()
|
self.drawTags()
|
||||||
self.updateFilterLabel()
|
self.updateFilterLabel()
|
||||||
self.show()
|
self.show()
|
||||||
if self.parent.currentCard:
|
# if self.parent.currentCard:
|
||||||
self.currentCard = self.parent.currentCard
|
# self.currentCard = self.parent.currentCard
|
||||||
self.updateSearch()
|
self.updateSearch()
|
||||||
|
|
||||||
def findCardInDeckModel(self):
|
def findCardInDeckModel(self):
|
||||||
|
@ -399,10 +339,10 @@ class EditDeck(QMainWindow):
|
||||||
|
|
||||||
def updateFont(self):
|
def updateFont(self):
|
||||||
self.dialog.tableView.setFont(QFont(
|
self.dialog.tableView.setFont(QFont(
|
||||||
self.config['editFontFamily'],
|
self.mw.config['editFontFamily'],
|
||||||
self.config['editFontSize']))
|
self.mw.config['editFontSize']))
|
||||||
self.dialog.tableView.verticalHeader().setDefaultSectionSize(
|
self.dialog.tableView.verticalHeader().setDefaultSectionSize(
|
||||||
self.parent.config['editLineSize'])
|
self.mw.config['editLineSize'])
|
||||||
self.model.reset()
|
self.model.reset()
|
||||||
|
|
||||||
def setupFilter(self):
|
def setupFilter(self):
|
||||||
|
@ -419,7 +359,7 @@ class EditDeck(QMainWindow):
|
||||||
|
|
||||||
def setupSort(self):
|
def setupSort(self):
|
||||||
self.dialog.sortBox.setMaxVisibleItems(30)
|
self.dialog.sortBox.setMaxVisibleItems(30)
|
||||||
self.sortIndex = self.deck.getInt("sortIndex") or 0
|
self.sortIndex = int(self.deck.conf.get("sortIdx", "0"))
|
||||||
self.drawSort()
|
self.drawSort()
|
||||||
self.connect(self.dialog.sortBox, SIGNAL("activated(int)"),
|
self.connect(self.dialog.sortBox, SIGNAL("activated(int)"),
|
||||||
self.sortChanged)
|
self.sortChanged)
|
||||||
|
@ -428,6 +368,7 @@ class EditDeck(QMainWindow):
|
||||||
self.reverseOrder)
|
self.reverseOrder)
|
||||||
|
|
||||||
def drawTags(self):
|
def drawTags(self):
|
||||||
|
return
|
||||||
self.dialog.tagList.setMaxVisibleItems(30)
|
self.dialog.tagList.setMaxVisibleItems(30)
|
||||||
self.dialog.tagList.view().setMinimumWidth(200)
|
self.dialog.tagList.view().setMinimumWidth(200)
|
||||||
self.dialog.tagList.setFixedWidth(170)
|
self.dialog.tagList.setFixedWidth(170)
|
||||||
|
@ -493,8 +434,6 @@ class EditDeck(QMainWindow):
|
||||||
_("Lapses"),
|
_("Lapses"),
|
||||||
_("First Review"),
|
_("First Review"),
|
||||||
]
|
]
|
||||||
self.sortFields = sorted(self.deck.allFields())
|
|
||||||
self.sortList.extend([_("'%s'") % f for f in self.sortFields])
|
|
||||||
self.dialog.sortBox.clear()
|
self.dialog.sortBox.clear()
|
||||||
self.dialog.sortBox.addItems(QStringList(self.sortList))
|
self.dialog.sortBox.addItems(QStringList(self.sortList))
|
||||||
if self.sortIndex >= len(self.sortList):
|
if self.sortIndex >= len(self.sortList):
|
||||||
|
@ -502,7 +441,7 @@ class EditDeck(QMainWindow):
|
||||||
self.dialog.sortBox.setCurrentIndex(self.sortIndex)
|
self.dialog.sortBox.setCurrentIndex(self.sortIndex)
|
||||||
|
|
||||||
def updateSortOrder(self):
|
def updateSortOrder(self):
|
||||||
if self.deck.getInt("reverseOrder"):
|
if int(self.deck.conf.get("revOrder", "0")):
|
||||||
self.dialog.sortOrder.setIcon(QIcon(":/icons/view-sort-descending.png"))
|
self.dialog.sortOrder.setIcon(QIcon(":/icons/view-sort-descending.png"))
|
||||||
else:
|
else:
|
||||||
self.dialog.sortOrder.setIcon(QIcon(":/icons/view-sort-ascending.png"))
|
self.dialog.sortOrder.setIcon(QIcon(":/icons/view-sort-ascending.png"))
|
||||||
|
@ -532,9 +471,9 @@ class EditDeck(QMainWindow):
|
||||||
self.sortKey = "firstAnswered"
|
self.sortKey = "firstAnswered"
|
||||||
else:
|
else:
|
||||||
self.sortKey = ("field", self.sortFields[idx-11])
|
self.sortKey = ("field", self.sortFields[idx-11])
|
||||||
self.rebuildSortIndex(self.sortKey)
|
#self.rebuildSortIndex(self.sortKey)
|
||||||
self.sortIndex = idx
|
self.sortIndex = idx
|
||||||
self.deck.setVar('sortIndex', idx)
|
self.deck.conf['sortIdx'] = idx
|
||||||
self.model.sortKey = self.sortKey
|
self.model.sortKey = self.sortKey
|
||||||
self.model.updateHeader()
|
self.model.updateHeader()
|
||||||
if refresh:
|
if refresh:
|
||||||
|
@ -552,7 +491,6 @@ class EditDeck(QMainWindow):
|
||||||
k="ix_cards_sort")
|
k="ix_cards_sort")
|
||||||
if old and key in old:
|
if old and key in old:
|
||||||
return
|
return
|
||||||
self.parent.setProgressParent(self)
|
|
||||||
self.deck.startProgress(2)
|
self.deck.startProgress(2)
|
||||||
self.deck.updateProgress(_("Building Index..."))
|
self.deck.updateProgress(_("Building Index..."))
|
||||||
self.deck.db.statement("drop index if exists ix_cards_sort")
|
self.deck.db.statement("drop index if exists ix_cards_sort")
|
||||||
|
@ -563,7 +501,6 @@ class EditDeck(QMainWindow):
|
||||||
"create index ix_cards_sort on cards (%s)" % key)
|
"create index ix_cards_sort on cards (%s)" % key)
|
||||||
self.deck.db.statement("analyze")
|
self.deck.db.statement("analyze")
|
||||||
self.deck.finishProgress()
|
self.deck.finishProgress()
|
||||||
self.parent.setProgressParent(None)
|
|
||||||
|
|
||||||
def tagChanged(self, idx):
|
def tagChanged(self, idx):
|
||||||
if idx == 0:
|
if idx == 0:
|
||||||
|
@ -591,23 +528,17 @@ class EditDeck(QMainWindow):
|
||||||
"of %(tot)d cards shown; %(sel)s)", self.deck.cardCount) %
|
"of %(tot)d cards shown; %(sel)s)", self.deck.cardCount) %
|
||||||
{
|
{
|
||||||
"cur": len(self.model.cards),
|
"cur": len(self.model.cards),
|
||||||
"tot": self.deck.cardCount,
|
"tot": self.deck.cardCount(),
|
||||||
"sel": ngettext("%d selected", "%d selected", selected) % selected
|
"sel": ngettext("%d selected", "%d selected", selected) % selected
|
||||||
} + " - " + self.deck.name())
|
} + " - " + self.deck.name())
|
||||||
|
|
||||||
def onEvent(self, type='field'):
|
def onEvent(self, type='field'):
|
||||||
if self.deck.undoAvailable():
|
if self.deck.undoName():
|
||||||
self.dialog.actionUndo.setText(_("Undo %s") %
|
self.dialog.actionUndo.setText(_("Undo %s") %
|
||||||
self.deck.undoName())
|
self.deck.undoName())
|
||||||
self.dialog.actionUndo.setEnabled(True)
|
self.dialog.actionUndo.setEnabled(True)
|
||||||
else:
|
else:
|
||||||
self.dialog.actionUndo.setEnabled(False)
|
self.dialog.actionUndo.setEnabled(False)
|
||||||
if self.deck.redoAvailable():
|
|
||||||
self.dialog.actionRedo.setText(_("Redo %s") %
|
|
||||||
self.deck.redoName())
|
|
||||||
self.dialog.actionRedo.setEnabled(True)
|
|
||||||
else:
|
|
||||||
self.dialog.actionRedo.setEnabled(False)
|
|
||||||
if type=="all":
|
if type=="all":
|
||||||
self.updateAfterCardChange()
|
self.updateAfterCardChange()
|
||||||
else:
|
else:
|
||||||
|
@ -638,8 +569,9 @@ class EditDeck(QMainWindow):
|
||||||
self.updateSearch()
|
self.updateSearch()
|
||||||
|
|
||||||
def updateSearch(self, force=True):
|
def updateSearch(self, force=True):
|
||||||
if self.parent.inDbHandler:
|
# fixme:
|
||||||
return
|
# if self.mw.inDbHandler:
|
||||||
|
# return
|
||||||
self.model.searchStr = unicode(self.dialog.filterEdit.text())
|
self.model.searchStr = unicode(self.dialog.filterEdit.text())
|
||||||
self.model.showMatching(force)
|
self.model.showMatching(force)
|
||||||
self.updateFilterLabel()
|
self.updateFilterLabel()
|
||||||
|
@ -685,7 +617,7 @@ class EditDeck(QMainWindow):
|
||||||
|
|
||||||
def setupMenus(self):
|
def setupMenus(self):
|
||||||
# actions
|
# actions
|
||||||
self.connect(self.dialog.actionAddItems, SIGNAL("triggered()"), self.parent.onAddCard)
|
self.connect(self.dialog.actionAddItems, SIGNAL("triggered()"), self.mw.onAddCard)
|
||||||
self.connect(self.dialog.actionDelete, SIGNAL("triggered()"), self.deleteCards)
|
self.connect(self.dialog.actionDelete, SIGNAL("triggered()"), self.deleteCards)
|
||||||
self.connect(self.dialog.actionAddTag, SIGNAL("triggered()"), self.addTags)
|
self.connect(self.dialog.actionAddTag, SIGNAL("triggered()"), self.addTags)
|
||||||
self.connect(self.dialog.actionDeleteTag, SIGNAL("triggered()"), self.deleteTags)
|
self.connect(self.dialog.actionDeleteTag, SIGNAL("triggered()"), self.deleteTags)
|
||||||
|
@ -719,14 +651,13 @@ class EditDeck(QMainWindow):
|
||||||
|
|
||||||
def onClose(self):
|
def onClose(self):
|
||||||
saveSplitter(self.dialog.splitter, "editor")
|
saveSplitter(self.dialog.splitter, "editor")
|
||||||
self.editor.saveFieldsNow()
|
self.editor.saveNow()
|
||||||
self.editor.setFact(None)
|
self.editor.setFact(None)
|
||||||
self.editor.close()
|
|
||||||
saveGeom(self, "editor")
|
saveGeom(self, "editor")
|
||||||
saveState(self, "editor")
|
saveState(self, "editor")
|
||||||
saveHeader(self.dialog.tableView.horizontalHeader(), "editor")
|
saveHeader(self.dialog.tableView.horizontalHeader(), "editor")
|
||||||
self.hide()
|
self.hide()
|
||||||
ui.dialogs.close("CardList")
|
aqt.dialogs.close("Browser")
|
||||||
self.teardownHooks()
|
self.teardownHooks()
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
@ -745,10 +676,10 @@ class EditDeck(QMainWindow):
|
||||||
######################################################################
|
######################################################################
|
||||||
|
|
||||||
def setupEditor(self):
|
def setupEditor(self):
|
||||||
self.editor = ui.facteditor.FactEditor(self,
|
self.editor = aqt.editor.Editor(self.mw,
|
||||||
self.dialog.fieldsArea,
|
self.dialog.fieldsArea)
|
||||||
self.deck)
|
# fixme:
|
||||||
self.editor.onChange = self.onEvent
|
#self.editor.onChange = self.onEvent
|
||||||
self.connect(self.dialog.tableView.selectionModel(),
|
self.connect(self.dialog.tableView.selectionModel(),
|
||||||
SIGNAL("currentRowChanged(QModelIndex, QModelIndex)"),
|
SIGNAL("currentRowChanged(QModelIndex, QModelIndex)"),
|
||||||
self.rowChanged)
|
self.rowChanged)
|
||||||
|
@ -800,7 +731,7 @@ where id in (%s)""" % ",".join([
|
||||||
self.rowChanged(self.currentRow, None)
|
self.rowChanged(self.currentRow, None)
|
||||||
self.model.refresh()
|
self.model.refresh()
|
||||||
self.drawTags()
|
self.drawTags()
|
||||||
self.parent.reset()
|
self.mw.reset()
|
||||||
|
|
||||||
# Menu options
|
# Menu options
|
||||||
######################################################################
|
######################################################################
|
||||||
|
@ -835,11 +766,9 @@ where id in (%s)""" % ",".join([
|
||||||
if label is None:
|
if label is None:
|
||||||
label = _("Add Tags")
|
label = _("Add Tags")
|
||||||
if r:
|
if r:
|
||||||
self.parent.setProgressParent(self)
|
|
||||||
self.deck.setUndoStart(label)
|
self.deck.setUndoStart(label)
|
||||||
self.deck.addTags(self.selectedFacts(), tags)
|
self.deck.addTags(self.selectedFacts(), tags)
|
||||||
self.deck.setUndoEnd(label)
|
self.deck.setUndoEnd(label)
|
||||||
self.parent.setProgressParent(None)
|
|
||||||
self.updateAfterCardChange()
|
self.updateAfterCardChange()
|
||||||
|
|
||||||
def deleteTags(self, tags=None, label=None):
|
def deleteTags(self, tags=None, label=None):
|
||||||
|
@ -852,11 +781,9 @@ where id in (%s)""" % ",".join([
|
||||||
if label is None:
|
if label is None:
|
||||||
label = _("Delete Tags")
|
label = _("Delete Tags")
|
||||||
if r:
|
if r:
|
||||||
self.parent.setProgressParent(self)
|
|
||||||
self.deck.setUndoStart(label)
|
self.deck.setUndoStart(label)
|
||||||
self.deck.deleteTags(self.selectedFacts(), tags)
|
self.deck.deleteTags(self.selectedFacts(), tags)
|
||||||
self.deck.setUndoEnd(label)
|
self.deck.setUndoEnd(label)
|
||||||
self.parent.setProgressParent(None)
|
|
||||||
self.updateAfterCardChange()
|
self.updateAfterCardChange()
|
||||||
|
|
||||||
def updateToggles(self):
|
def updateToggles(self):
|
||||||
|
@ -876,23 +803,19 @@ where id in (%s)""" % ",".join([
|
||||||
|
|
||||||
def _onSuspend(self):
|
def _onSuspend(self):
|
||||||
n = _("Suspend")
|
n = _("Suspend")
|
||||||
self.parent.setProgressParent(self)
|
|
||||||
self.deck.setUndoStart(n)
|
self.deck.setUndoStart(n)
|
||||||
self.deck.suspendCards(self.selectedCards())
|
self.deck.suspendCards(self.selectedCards())
|
||||||
self.parent.reset()
|
self.mw.reset()
|
||||||
self.deck.setUndoEnd(n)
|
self.deck.setUndoEnd(n)
|
||||||
self.parent.setProgressParent(None)
|
|
||||||
self.model.refresh()
|
self.model.refresh()
|
||||||
self.updateAfterCardChange()
|
self.updateAfterCardChange()
|
||||||
|
|
||||||
def _onUnsuspend(self):
|
def _onUnsuspend(self):
|
||||||
n = _("Unsuspend")
|
n = _("Unsuspend")
|
||||||
self.parent.setProgressParent(self)
|
|
||||||
self.deck.setUndoStart(n)
|
self.deck.setUndoStart(n)
|
||||||
self.deck.unsuspendCards(self.selectedCards())
|
self.deck.unsuspendCards(self.selectedCards())
|
||||||
self.parent.reset()
|
self.mw.reset()
|
||||||
self.deck.setUndoEnd(n)
|
self.deck.setUndoEnd(n)
|
||||||
self.parent.setProgressParent(None)
|
|
||||||
self.model.refresh()
|
self.model.refresh()
|
||||||
self.updateAfterCardChange()
|
self.updateAfterCardChange()
|
||||||
|
|
||||||
|
@ -957,7 +880,6 @@ where id in %s""" % ids2str(sf))
|
||||||
return
|
return
|
||||||
# for each fact id, generate
|
# for each fact id, generate
|
||||||
n = _("Generate Cards")
|
n = _("Generate Cards")
|
||||||
self.parent.setProgressParent(self)
|
|
||||||
self.deck.startProgress()
|
self.deck.startProgress()
|
||||||
self.deck.setUndoStart(n)
|
self.deck.setUndoStart(n)
|
||||||
facts = self.deck.db.query(Fact).filter(
|
facts = self.deck.db.query(Fact).filter(
|
||||||
|
@ -970,14 +892,13 @@ where id in %s""" % ids2str(sf))
|
||||||
self.deck.updateProgress()
|
self.deck.updateProgress()
|
||||||
self.deck.flushMod()
|
self.deck.flushMod()
|
||||||
self.deck.finishProgress()
|
self.deck.finishProgress()
|
||||||
self.parent.setProgressParent(None)
|
|
||||||
self.deck.setUndoEnd(n)
|
self.deck.setUndoEnd(n)
|
||||||
self.updateSearch()
|
self.updateSearch()
|
||||||
self.updateAfterCardChange()
|
self.updateAfterCardChange()
|
||||||
|
|
||||||
def cram(self):
|
def cram(self):
|
||||||
self.close()
|
self.close()
|
||||||
self.parent.onCram(self.selectedCards())
|
self.mw.onCram(self.selectedCards())
|
||||||
|
|
||||||
def onChangeModel(self):
|
def onChangeModel(self):
|
||||||
sf = self.selectedFacts()
|
sf = self.selectedFacts()
|
||||||
|
@ -994,11 +915,9 @@ where id in %s""" % ids2str(sf))
|
||||||
d.exec_()
|
d.exec_()
|
||||||
if d.ret:
|
if d.ret:
|
||||||
n = _("Change Model")
|
n = _("Change Model")
|
||||||
self.parent.setProgressParent(self)
|
|
||||||
self.deck.setUndoStart(n)
|
self.deck.setUndoStart(n)
|
||||||
self.deck.changeModel(sf, *d.ret)
|
self.deck.changeModel(sf, *d.ret)
|
||||||
self.deck.setUndoEnd(n)
|
self.deck.setUndoEnd(n)
|
||||||
self.parent.setProgressParent(None)
|
|
||||||
self.updateSearch()
|
self.updateSearch()
|
||||||
self.updateAfterCardChange()
|
self.updateAfterCardChange()
|
||||||
|
|
||||||
|
@ -1067,15 +986,15 @@ where id in %s""" % ids2str(sf))
|
||||||
frm = aqt.forms.editfont.Ui_Dialog()
|
frm = aqt.forms.editfont.Ui_Dialog()
|
||||||
frm.setupUi(d)
|
frm.setupUi(d)
|
||||||
frm.fontCombo.setCurrentFont(QFont(
|
frm.fontCombo.setCurrentFont(QFont(
|
||||||
self.parent.config['editFontFamily']))
|
self.mw.config['editFontFamily']))
|
||||||
frm.fontSize.setValue(self.parent.config['editFontSize'])
|
frm.fontSize.setValue(self.mw.config['editFontSize'])
|
||||||
frm.lineSize.setValue(self.parent.config['editLineSize'])
|
frm.lineSize.setValue(self.mw.config['editLineSize'])
|
||||||
if d.exec_():
|
if d.exec_():
|
||||||
self.parent.config['editFontFamily'] = (
|
self.mw.config['editFontFamily'] = (
|
||||||
unicode(frm.fontCombo.currentFont().family()))
|
unicode(frm.fontCombo.currentFont().family()))
|
||||||
self.parent.config['editFontSize'] = (
|
self.mw.config['editFontSize'] = (
|
||||||
int(frm.fontSize.value()))
|
int(frm.fontSize.value()))
|
||||||
self.parent.config['editLineSize'] = (
|
self.mw.config['editLineSize'] = (
|
||||||
int(frm.lineSize.value()))
|
int(frm.lineSize.value()))
|
||||||
self.updateFont()
|
self.updateFont()
|
||||||
|
|
||||||
|
@ -1105,7 +1024,6 @@ where id in %s""" % ids2str(sf))
|
||||||
if not d.exec_():
|
if not d.exec_():
|
||||||
return
|
return
|
||||||
n = _("Find and Replace")
|
n = _("Find and Replace")
|
||||||
self.parent.setProgressParent(self)
|
|
||||||
self.deck.startProgress(2)
|
self.deck.startProgress(2)
|
||||||
self.deck.updateProgress(_("Replacing..."))
|
self.deck.updateProgress(_("Replacing..."))
|
||||||
self.deck.setUndoStart(n)
|
self.deck.setUndoStart(n)
|
||||||
|
@ -1126,8 +1044,7 @@ where id in %s""" % ids2str(sf))
|
||||||
parent=self)
|
parent=self)
|
||||||
self.deck.setUndoEnd(n)
|
self.deck.setUndoEnd(n)
|
||||||
self.deck.finishProgress()
|
self.deck.finishProgress()
|
||||||
self.parent.setProgressParent(None)
|
self.mw.reset()
|
||||||
self.parent.reset()
|
|
||||||
self.updateSearch()
|
self.updateSearch()
|
||||||
self.updateAfterCardChange()
|
self.updateAfterCardChange()
|
||||||
if changed is not None:
|
if changed is not None:
|
|
@ -8,7 +8,7 @@ from PyQt4.QtWebKit import QWebView
|
||||||
import re, os, sys, tempfile, urllib2, ctypes, simplejson, traceback
|
import re, os, sys, tempfile, urllib2, ctypes, simplejson, traceback
|
||||||
from anki.utils import stripHTML, parseTags
|
from anki.utils import stripHTML, parseTags
|
||||||
from anki.sound import play
|
from anki.sound import play
|
||||||
from anki.hooks import addHook, removeHook, runHook, runFilter
|
from anki.hooks import runHook
|
||||||
from aqt.sound import getAudio
|
from aqt.sound import getAudio
|
||||||
from aqt.webview import AnkiWebView
|
from aqt.webview import AnkiWebView
|
||||||
from aqt.utils import shortcut, showInfo, showWarning, getBase, getFile
|
from aqt.utils import shortcut, showInfo, showWarning, getBase, getFile
|
||||||
|
@ -17,6 +17,7 @@ import anki.js
|
||||||
|
|
||||||
# fixme: when tab order returns to the webview, the previously focused field
|
# fixme: when tab order returns to the webview, the previously focused field
|
||||||
# is focused, which is not good when the user is tabbing through the dialog
|
# is focused, which is not good when the user is tabbing through the dialog
|
||||||
|
# fixme: set rtl in div css
|
||||||
|
|
||||||
pics = ("jpg", "jpeg", "png", "tif", "tiff", "gif")
|
pics = ("jpg", "jpeg", "png", "tif", "tiff", "gif")
|
||||||
audio = ("wav", "mp3", "ogg", "flac")
|
audio = ("wav", "mp3", "ogg", "flac")
|
||||||
|
|
|
@ -633,7 +633,7 @@ Debug info:\n%s""") % traceback.format_exc(), help="DeckErrors")
|
||||||
aqt.dialogs.open("AddCards", self)
|
aqt.dialogs.open("AddCards", self)
|
||||||
|
|
||||||
def onEditDeck(self):
|
def onEditDeck(self):
|
||||||
aqt.dialogs.open("CardList", self)
|
aqt.dialogs.open("Browser", self)
|
||||||
|
|
||||||
def onEditCurrent(self):
|
def onEditCurrent(self):
|
||||||
self.moveToState("editCurrentFact")
|
self.moveToState("editCurrentFact")
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<ui version="4.0">
|
<ui version="4.0">
|
||||||
<class>MainWindow</class>
|
<class>Dialog</class>
|
||||||
<widget class="QMainWindow" name="MainWindow">
|
<widget class="QMainWindow" name="Dialog">
|
||||||
<property name="geometry">
|
<property name="geometry">
|
||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
|
@ -11,10 +11,10 @@
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
<string>Browse Items</string>
|
<string>Browser</string>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowIcon">
|
<property name="windowIcon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/find.png</normaloff>:/icons/find.png</iconset>
|
<normaloff>:/icons/find.png</normaloff>:/icons/find.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QWidget" name="centralwidget">
|
<widget class="QWidget" name="centralwidget">
|
||||||
|
@ -97,7 +97,7 @@
|
||||||
<string/>
|
<string/>
|
||||||
</property>
|
</property>
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/view-sort-ascending.png</normaloff>:/icons/view-sort-ascending.png</iconset>
|
<normaloff>:/icons/view-sort-ascending.png</normaloff>:/icons/view-sort-ascending.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="flat">
|
<property name="flat">
|
||||||
|
@ -223,7 +223,7 @@
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>599</width>
|
<width>599</width>
|
||||||
<height>20</height>
|
<height>22</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QMenu" name="menuEdit">
|
<widget class="QMenu" name="menuEdit">
|
||||||
|
@ -231,7 +231,6 @@
|
||||||
<string>&Edit</string>
|
<string>&Edit</string>
|
||||||
</property>
|
</property>
|
||||||
<addaction name="actionUndo"/>
|
<addaction name="actionUndo"/>
|
||||||
<addaction name="actionRedo"/>
|
|
||||||
<addaction name="separator"/>
|
<addaction name="separator"/>
|
||||||
<addaction name="actionSelectAll"/>
|
<addaction name="actionSelectAll"/>
|
||||||
<addaction name="actionSelectFacts"/>
|
<addaction name="actionSelectFacts"/>
|
||||||
|
@ -317,7 +316,7 @@
|
||||||
</widget>
|
</widget>
|
||||||
<action name="actionDelete">
|
<action name="actionDelete">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/editdelete.png</normaloff>:/icons/editdelete.png</iconset>
|
<normaloff>:/icons/editdelete.png</normaloff>:/icons/editdelete.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -329,7 +328,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionAddTag">
|
<action name="actionAddTag">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/Anki_Add_Tag.png</normaloff>:/icons/Anki_Add_Tag.png</iconset>
|
<normaloff>:/icons/Anki_Add_Tag.png</normaloff>:/icons/Anki_Add_Tag.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -338,7 +337,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionDeleteTag">
|
<action name="actionDeleteTag">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/Anki_Del_Tag.png</normaloff>:/icons/Anki_Del_Tag.png</iconset>
|
<normaloff>:/icons/Anki_Del_Tag.png</normaloff>:/icons/Anki_Del_Tag.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -347,7 +346,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionAddCards">
|
<action name="actionAddCards">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/Anki_Card.png</normaloff>:/icons/Anki_Card.png</iconset>
|
<normaloff>:/icons/Anki_Card.png</normaloff>:/icons/Anki_Card.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -356,7 +355,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionReschedule">
|
<action name="actionReschedule">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/edit-undo.png</normaloff>:/icons/edit-undo.png</iconset>
|
<normaloff>:/icons/edit-undo.png</normaloff>:/icons/edit-undo.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -370,7 +369,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionUndo">
|
<action name="actionUndo">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/edit-undo.png</normaloff>:/icons/edit-undo.png</iconset>
|
<normaloff>:/icons/edit-undo.png</normaloff>:/icons/edit-undo.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -379,7 +378,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionRedo">
|
<action name="actionRedo">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/edit-redo.png</normaloff>:/icons/edit-redo.png</iconset>
|
<normaloff>:/icons/edit-redo.png</normaloff>:/icons/edit-redo.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -393,7 +392,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionFind">
|
<action name="actionFind">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/document-preview.png</normaloff>:/icons/document-preview.png</iconset>
|
<normaloff>:/icons/document-preview.png</normaloff>:/icons/document-preview.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -405,7 +404,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionFact">
|
<action name="actionFact">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/Anki_Fact.png</normaloff>:/icons/Anki_Fact.png</iconset>
|
<normaloff>:/icons/Anki_Fact.png</normaloff>:/icons/Anki_Fact.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -417,7 +416,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionNextCard">
|
<action name="actionNextCard">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/go-next.png</normaloff>:/icons/go-next.png</iconset>
|
<normaloff>:/icons/go-next.png</normaloff>:/icons/go-next.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -429,7 +428,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionPreviousCard">
|
<action name="actionPreviousCard">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/go-previous.png</normaloff>:/icons/go-previous.png</iconset>
|
<normaloff>:/icons/go-previous.png</normaloff>:/icons/go-previous.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -441,7 +440,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionFirstCard">
|
<action name="actionFirstCard">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/go-first.png</normaloff>:/icons/go-first.png</iconset>
|
<normaloff>:/icons/go-first.png</normaloff>:/icons/go-first.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -453,7 +452,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionLastCard">
|
<action name="actionLastCard">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/go-last.png</normaloff>:/icons/go-last.png</iconset>
|
<normaloff>:/icons/go-last.png</normaloff>:/icons/go-last.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -465,7 +464,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionGuide">
|
<action name="actionGuide">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/help.png</normaloff>:/icons/help.png</iconset>
|
<normaloff>:/icons/help.png</normaloff>:/icons/help.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -477,7 +476,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionChangeModel">
|
<action name="actionChangeModel">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/system-software-update.png</normaloff>:/icons/system-software-update.png</iconset>
|
<normaloff>:/icons/system-software-update.png</normaloff>:/icons/system-software-update.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -496,7 +495,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionCram">
|
<action name="actionCram">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/view-pim-calendar.png</normaloff>:/icons/view-pim-calendar.png</iconset>
|
<normaloff>:/icons/view-pim-calendar.png</normaloff>:/icons/view-pim-calendar.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -510,7 +509,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionSuspend">
|
<action name="actionSuspend">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/media-playback-pause.png</normaloff>:/icons/media-playback-pause.png</iconset>
|
<normaloff>:/icons/media-playback-pause.png</normaloff>:/icons/media-playback-pause.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -519,7 +518,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionUnsuspend">
|
<action name="actionUnsuspend">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/media-playback-start2.png</normaloff>:/icons/media-playback-start2.png</iconset>
|
<normaloff>:/icons/media-playback-start2.png</normaloff>:/icons/media-playback-start2.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -528,7 +527,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionTags">
|
<action name="actionTags">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/anki-tag.png</normaloff>:/icons/anki-tag.png</iconset>
|
<normaloff>:/icons/anki-tag.png</normaloff>:/icons/anki-tag.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -540,7 +539,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionSort">
|
<action name="actionSort">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/view-sort-ascending.png</normaloff>:/icons/view-sort-ascending.png</iconset>
|
<normaloff>:/icons/view-sort-ascending.png</normaloff>:/icons/view-sort-ascending.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -552,7 +551,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionAddItems">
|
<action name="actionAddItems">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/list-add.png</normaloff>:/icons/list-add.png</iconset>
|
<normaloff>:/icons/list-add.png</normaloff>:/icons/list-add.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -567,7 +566,7 @@
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
</property>
|
</property>
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/media-playback-pause.png</normaloff>:/icons/media-playback-pause.png</iconset>
|
<normaloff>:/icons/media-playback-pause.png</normaloff>:/icons/media-playback-pause.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -579,7 +578,7 @@
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
</property>
|
</property>
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/rating.png</normaloff>:/icons/rating.png</iconset>
|
<normaloff>:/icons/rating.png</normaloff>:/icons/rating.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -588,7 +587,7 @@
|
||||||
</action>
|
</action>
|
||||||
<action name="actionCardList">
|
<action name="actionCardList">
|
||||||
<property name="icon">
|
<property name="icon">
|
||||||
<iconset resource="../icons.qrc">
|
<iconset resource="icons.qrc">
|
||||||
<normaloff>:/icons/generate_07.png</normaloff>:/icons/generate_07.png</iconset>
|
<normaloff>:/icons/generate_07.png</normaloff>:/icons/generate_07.png</iconset>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
|
@ -605,7 +604,7 @@
|
||||||
</action>
|
</action>
|
||||||
</widget>
|
</widget>
|
||||||
<resources>
|
<resources>
|
||||||
<include location="../icons.qrc"/>
|
<include location="icons.qrc"/>
|
||||||
</resources>
|
</resources>
|
||||||
<connections>
|
<connections>
|
||||||
<connection>
|
<connection>
|
Loading…
Reference in a new issue