From 9ff30f0c2688f8d074b1fd4e7f711ca3a3989ddd Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Tue, 6 Jan 2009 10:46:20 +0900 Subject: [PATCH] only prompt type in the answer once --- ankiqt/ui/main.py | 7 ++++++- designer/main.ui | 4 ++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/ankiqt/ui/main.py b/ankiqt/ui/main.py index fbdda60f4..bbcb35bf1 100644 --- a/ankiqt/ui/main.py +++ b/ankiqt/ui/main.py @@ -438,7 +438,12 @@ new: def showAnswerButton(self): if self.currentCard.cardModel.typeAnswer: self.mainWin.buttonStack.setCurrentIndex(4) - self.mainWin.typeAnswerField.selectAll() + if not unicode(self.mainWin.typeAnswerField.text()): + self.mainWin.typeAnswerField.setText(_( + "Type in the answer and hit enter")) + self.mainWin.typeAnswerField.selectAll() + else: + self.mainWin.typeAnswerField.setText("") else: self.mainWin.buttonStack.setCurrentIndex(0) self.mainWin.showAnswerButton.setFocus() diff --git a/designer/main.ui b/designer/main.ui index 71c86ac4d..222a3b128 100644 --- a/designer/main.ui +++ b/designer/main.ui @@ -733,7 +733,7 @@ 0 0 - 542 + 428 49 @@ -762,7 +762,7 @@ - Type answer and hit enter +