mirror of
https://github.com/ankitects/anki.git
synced 2025-09-21 07:22:23 -04:00
catch ret in type ans area
This commit is contained in:
parent
6f8a3c5216
commit
0b95bab30b
1 changed files with 7 additions and 1 deletions
|
@ -155,6 +155,11 @@ function _onSpace() {
|
|||
py.link(document.activeElement.href);
|
||||
}
|
||||
}
|
||||
function _typeAnsPress() {
|
||||
if (window.event.keyCode === 13) {
|
||||
_showans();
|
||||
}
|
||||
}
|
||||
$(document).ready(function () {
|
||||
$(".ansbut").focus();
|
||||
});
|
||||
|
@ -388,7 +393,8 @@ div#filler {
|
|||
return ""
|
||||
return """
|
||||
<center>
|
||||
<input type=text id=typeans style="font-family: '%s'; font-size: %s;">
|
||||
<input type=text id=typeans onkeypress="_typeAnsPress();"
|
||||
style="font-family: '%s'; font-size: %s;">
|
||||
</center>
|
||||
""" % (
|
||||
self.getFont())
|
||||
|
|
Loading…
Reference in a new issue