atom-keymap
Advanced tools
Comparing version 0.5.0 to 0.6.0
@@ -57,5 +57,9 @@ (function() { | ||
} | ||
if (/^[^a-z]$/.test(key)) { | ||
if (/^[a-z]$/.test(key)) { | ||
key = key.toUpperCase(); | ||
} | ||
} else { | ||
if (/^[A-Z]$/.test(key)) { | ||
key = key.toLowerCase(); | ||
} | ||
} | ||
@@ -86,3 +90,3 @@ if (event.metaKey) { | ||
view = null; | ||
if (/^[a-z]$/.test(key) && shift) { | ||
if (/^[a-z]$/.test(key)) { | ||
key = key.toUpperCase(); | ||
@@ -89,0 +93,0 @@ } |
@@ -125,3 +125,3 @@ (function() { | ||
Keymap.prototype.handleKeyboardEvent = function(event, replaying) { | ||
var exactMatch, exactMatchCandidates, foundMatch, keystroke, keystrokes, partialMatchCandidates, partialMatches, target, _i, _len, _ref1, _ref2; | ||
var currentTarget, exactMatch, exactMatchCandidates, foundMatch, keystroke, keystrokes, partialMatchCandidates, partialMatches, target, _i, _len, _ref1, _ref2; | ||
keystroke = this.keystrokeForKeyboardEvent(event); | ||
@@ -146,4 +146,5 @@ if (this.queuedKeystrokes.length > 0 && isAtomModifier(keystroke)) { | ||
if (exactMatchCandidates.length > 0) { | ||
while ((target != null) && target !== document) { | ||
_ref2 = this.findExactMatches(exactMatchCandidates, target); | ||
currentTarget = target; | ||
while ((currentTarget != null) && currentTarget !== document) { | ||
_ref2 = this.findExactMatches(exactMatchCandidates, currentTarget); | ||
for (_i = 0, _len = _ref2.length; _i < _len; _i++) { | ||
@@ -158,3 +159,3 @@ exactMatch = _ref2[_i]; | ||
} | ||
target = target.parentElement; | ||
currentTarget = currentTarget.parentElement; | ||
} | ||
@@ -161,0 +162,0 @@ } |
{ | ||
"name": "atom-keymap", | ||
"version": "0.5.0", | ||
"version": "0.6.0", | ||
"description": "Atom's DOM-aware keymap module", | ||
@@ -5,0 +5,0 @@ "main": "./lib/keymap", |
35744
937