summaryrefslogtreecommitdiff
path: root/sphinx/themes/basic/static/doctools.js
diff options
context:
space:
mode:
Diffstat (limited to 'sphinx/themes/basic/static/doctools.js')
-rw-r--r--sphinx/themes/basic/static/doctools.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/sphinx/themes/basic/static/doctools.js b/sphinx/themes/basic/static/doctools.js
index daccd209d..7d88f807d 100644
--- a/sphinx/themes/basic/static/doctools.js
+++ b/sphinx/themes/basic/static/doctools.js
@@ -285,9 +285,10 @@ var Documentation = {
initOnKeyListeners: function() {
$(document).keydown(function(event) {
var activeElementType = document.activeElement.tagName;
- // don't navigate when in search box or textarea
+ // don't navigate when in search box, textarea, dropdown or button
if (activeElementType !== 'TEXTAREA' && activeElementType !== 'INPUT' && activeElementType !== 'SELECT'
- && !event.altKey && !event.ctrlKey && !event.metaKey && !event.shiftKey) {
+ && activeElementType !== 'BUTTON' && !event.altKey && !event.ctrlKey && !event.metaKey
+ && !event.shiftKey) {
switch (event.keyCode) {
case 37: // left
var prevHref = $('link[rel="prev"]').prop('href');