fix 'loading' message by removing old type answer code

This commit is contained in:
Damien Elmes 2016-07-07 11:08:32 +10:00
parent 26fdf1e01f
commit 39a2ddac51

View File

@ -155,11 +155,6 @@ function _toggleStar (show) {
} }
} }
function _getTypedText () {
if (typeans) {
pycmd("typeans:"+typeans.value);
}
};
function _typeAnsPress() { function _typeAnsPress() {
if (window.event.keyCode === 13) { if (window.event.keyCode === 13) {
pycmd("ans"); pycmd("ans");
@ -307,7 +302,7 @@ The front of this card is empty. Please run Tools>Empty Cards.""")
elif url == "more": elif url == "more":
self.showContextMenu() self.showContextMenu()
else: else:
openLink(url) print("unrecognized anki link:", url)
# CSS # CSS
########################################################################## ##########################################################################
@ -379,8 +374,6 @@ Please run Tools>Empty Cards""")
""" % (self.typeFont, self.typeSize), buf) """ % (self.typeFont, self.typeSize), buf)
def typeAnsAnswerFilter(self, buf): def typeAnsAnswerFilter(self, buf):
# tell webview to call us back with the input content
self.web.eval("_getTypedText();")
if not self.typeCorrect: if not self.typeCorrect:
return re.sub(self.typeAnsPat, "", buf) return re.sub(self.typeAnsPat, "", buf)
origSize = len(buf) origSize = len(buf)