Keep track of whether the FactEditor is used for Add or Edit

This commit is contained in:
Shawn M Moore 2010-02-15 13:49:43 -05:00
parent c234423f04
commit 3f551e70f9
2 changed files with 2 additions and 0 deletions

View file

@ -51,6 +51,7 @@ class AddCards(QDialog):
self.editor = ui.facteditor.FactEditor(self,
self.dialog.fieldsArea,
self.parent.deck)
self.editor.addMode = True
def addChooser(self):
self.modelChooser = ui.modelchooser.ModelChooser(self,

View file

@ -42,6 +42,7 @@ class FactEditor(object):
self.deck = deck
self.fact = None
self.fontChanged = False
self.addMode = False
self.setupFields()
self.onChange = None
self.onFactValid = None