MCPcopy Create free account
hub / github.com/select2/select2 / buildKeyDownEvent

Function buildKeyDownEvent

tests/selection/openOnKeyDown-tests.js:15–17  ·  view source on GitHub ↗

* Build a keydown event with the given key code and extra options. * * @param {Number} keyCode the keyboard code to be used for the 'which' * attribute of the keydown event. * @param {Object} eventProps extra properties to build the keydown event. * * @retur

(keyCode, eventProps)

Source from the content-addressed store, hash-verified

13 * @return {jQuery.Event} a 'keydown' type event.
14 */
15function buildKeyDownEvent (keyCode, eventProps) {
16 return $.Event('keydown', $.extend({}, { which: keyCode }, eventProps));
17}
18
19/**
20 * Wrapper function providing a select2 element with a given enabled/disabled

Callers 1

testAbledFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…