From 37519fd6ec7449375744af147d4212dda9bf95af Mon Sep 17 00:00:00 2001 From: Steve Kashishian Date: Mon, 10 Feb 2014 21:45:19 -0500 Subject: [PATCH 1/2] don't capture keydowns if modifier key is active --- src/map/handler/Map.Keyboard.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/map/handler/Map.Keyboard.js b/src/map/handler/Map.Keyboard.js index da79ec4f..d3dd2745 100644 --- a/src/map/handler/Map.Keyboard.js +++ b/src/map/handler/Map.Keyboard.js @@ -125,6 +125,8 @@ L.Map.Keyboard = L.Handler.extend({ }, _onKeyDown: function (e) { + if (e.altKey || e.ctrlKey || e.shiftKey || e.metaKey) { return; } + var key = e.keyCode, map = this._map; From c339a7e8081c469e7ec550de7b3d7a5a5f28a656 Mon Sep 17 00:00:00 2001 From: Steve Date: Wed, 12 Feb 2014 09:18:09 -0500 Subject: [PATCH 2/2] allow shift key to be active --- src/map/handler/Map.Keyboard.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/map/handler/Map.Keyboard.js b/src/map/handler/Map.Keyboard.js index d3dd2745..085ee119 100644 --- a/src/map/handler/Map.Keyboard.js +++ b/src/map/handler/Map.Keyboard.js @@ -125,7 +125,7 @@ L.Map.Keyboard = L.Handler.extend({ }, _onKeyDown: function (e) { - if (e.altKey || e.ctrlKey || e.shiftKey || e.metaKey) { return; } + if (e.altKey || e.ctrlKey || e.metaKey) { return; } var key = e.keyCode, map = this._map;