fix hotkeys

This commit is contained in:
albert
2013-02-21 15:35:54 -05:00
parent 18e7801cac
commit 19398df28e
2 changed files with 3 additions and 3 deletions

View File

@@ -493,7 +493,7 @@ Danbooru.Note = {
$(function() {
if ($("#c-posts").length && $("#a-show").length && $("#image").length) {
$("#translate").one("click", Danbooru.Note.TranslationMode.start);
$(document).bind("keypress", "n", Danbooru.Note.TranslationMode.start);
$(document).bind("keydown.n", Danbooru.Note.TranslationMode.start);
Danbooru.Note.load_all();
$("#image").click(Danbooru.Note.Box.toggle_all);
}

View File

@@ -28,13 +28,13 @@
}
Danbooru.Post.initialize_shortcuts = function() {
$(document).bind("keypress", '/', function(e) {
$(document).bind("keydown./", function(e) {
$("#tags").trigger("focus");
e.preventDefault();
});
if ($("#a-show").length) {
$(document).bind("keypress", 'e', function(e) {
$(document).bind("keydown.e", function(e) {
$("#post-edit-link").trigger("click");
$("#post_tag_string").trigger("focus");
e.preventDefault();