librustdoc: don't override ctrl-s and other browser shortcuts

This commit is contained in:
Ivan Kozik 2015-11-05 10:39:02 +00:00
parent 7839827a39
commit 3b2a8e1259
1 changed files with 4 additions and 0 deletions

View File

@ -101,6 +101,10 @@
if (document.activeElement.tagName == "INPUT")
return;
// Don't interfere with browser shortcuts
if (ev.ctrlKey || ev.altKey || ev.metaKey)
return;
switch (getVirtualKey(ev)) {
case "Escape":
if (!$("#help").hasClass("hidden")) {