mirror of
https://github.com/atom/atom.git
synced 2026-01-23 05:48:10 -05:00
Defend against jQuery-wrapped targets in keydownEvent spec helper
This commit is contained in:
@@ -187,7 +187,7 @@ window.keydownEvent = (key, properties={}) ->
|
||||
nativeProperties.alt = properties.altKey
|
||||
nativeProperties.shift = properties.shiftKey
|
||||
nativeProperties.cmd = properties.metaKey
|
||||
nativeProperties.target = properties.target
|
||||
nativeProperties.target = properties.target?[0] ? properties.target
|
||||
nativeProperties.which = properties.which
|
||||
originalEvent = nativeKeydownEvent(key, nativeProperties)
|
||||
properties = $.extend({originalEvent}, properties)
|
||||
|
||||
Reference in New Issue
Block a user