Keyboard support for the calendar.
@protected
@param {aria.DomEvent} domEvt Key down event
4360
function (domEvt) {
            var domElt = this.getDom();
            if (this.sendKey(domEvt.charCode, domEvt.keyCode)) {
                domEvt.preventDefault(true);
                domElt.focus();
            }
        }
884147
function (domEvt) {
            if (this._actingDom && this._hasMouseOver === false) {
                this._hasFocus = true;
                var offset;
                if (ariaCoreBrowser.isFirefox) {
                    offset = {
                        left : 1,
                        top : 2
                    };
                } else {
                    offset = {
                        left : 1,
                        top : 1
                    };
                }
                if (this._ellipsis) {
                    this._ellipsis.displayFullText(offset);
                }
            }
        }
891310
function (domEvt) {
            this.$ActionWidget._dom_onmouseenter.call(this, domEvt);
            if (this._ellipsis) {
                var mouseOverTime = new Date();

                /*
                 * James says: When they click on the full text of the ellipses, the refresh removes the full text, but
                 * then the mouseover is raised which puts the full text back in the way again. This makes sure that a
                 * time has passed from initialisation before displaying it.
                 */
                var timeDifference = mouseOverTime.getTime() - this.loadTime.getTime();
                if (timeDifference > 200) {

                    this._hasMouseOver = true;
                    var offset;
                    if (ariaCoreBrowser.isFirefox) {
                        offset = {
                            left : 1,
                            top : 2
                        };
                    } else if (ariaCoreBrowser.isIE8) {
                        offset = {
                            left : 0,
                            top : 1
                        };
                    } else {
                        offset = {
                            left : 1,
                            top : 1
                        };
                    }

                    if (this._ellipsis) {
                        this._ellipsis.displayFullText(offset);
                    }
                }

            }
        }
1168102
function (domEvt) {
            if (this._hasMouseOver === false && this._hasFocus === true) {
                this._hasFocus = false;
                if (this._ellipsis) {
                    this._ellipsis._hideFullText(domEvt.relatedTarget);
                }
            }
        }
1052823
function (event) {
            var domEvent = aria.DomEvent;
            if (event.keyCode === domEvent.KC_ENTER) {
                this._updateValue(false);
            }
            this.$DropDownInput._dom_onkeypress.call(this, event);
        }
256585
function _keydownHook(event) {
            var keyCode;

            // (page) up, (page) down, enter and tab key are handled by the list
            if (event.type === "keydown") {
                keyCode = event.keyCode;

                if (keyCode === KeyEvent.DOM_VK_TAB) {
                    self.close();
                } else if (keyCode === KeyEvent.DOM_VK_UP) {
                    // Move up one, wrapping at edges (if nothing selected, select the last item)
                    self._tryToSelect(self._selectedIndex === -1 ? -1 : self._selectedIndex - 1, -1);
                } else if (keyCode === KeyEvent.DOM_VK_DOWN) {
                    // Move down one, wrapping at edges (if nothing selected, select the first item)
                    self._tryToSelect(self._selectedIndex === -1 ? 0 : self._selectedIndex + 1, +1);
                } else if (keyCode === KeyEvent.DOM_VK_PAGE_UP) {
                    // Move up roughly one 'page', stopping at edges (not wrapping) (if nothing selected, selects the first item)
                    self._tryToSelect((self._selectedIndex || 0) - self._itemsPerPage(), -1, true);
                } else if (keyCode === KeyEvent.DOM_VK_PAGE_DOWN) {
                    // Move down roughly one 'page', stopping at edges (not wrapping) (if nothing selected, selects the item one page down from the top)
                    self._tryToSelect((self._selectedIndex || 0) + self._itemsPerPage(), +1, true);

                } else if (keyCode === KeyEvent.DOM_VK_HOME) {
                    self._tryToSelect(0, +1);
                } else if (keyCode === KeyEvent.DOM_VK_END) {
                    self._tryToSelect(self.$items.length - 1, -1);

                } else if (self._selectedIndex !== -1 &&
                        (keyCode === KeyEvent.DOM_VK_RETURN)) {

                    // Trigger a click handler to commmit the selected item
                    self._selectionHandler();
                } else {
                    // Let the event bubble.
                    return false;
                }

                event.stopImmediatePropagation();
                event.preventDefault();
                return true;
            }

            // If we didn't handle it, let other global keydown hooks handle it.
            return false;
        }
1049406
function onKeydown(event)
{
  // Gets the keycode, then stores it
  var keyCode = event.which;

  // Checks which action matches with the current keycode
  switch (keyCode)
  {
    case 65: keyA();
    break;

    case 66: keyB();
    break;

    case 67: keyC();
    break;

    case 68: keyD();
    break;

    case 69: keyE();
    break;

    case 70: keyF();
    break;

    case 71: keyG();
    break;

    case 72: keyH();
    break;

    case 73: keyI();
    break;

    case 74: keyJ();
    break;

    case 75: keyK();
    break;

    case 76: keyL();
    break;

    case 77: keyM();
    break;

    case 78: keyN();
    break;

    case 79: keyO();
    break;

    case 80: keyP();
    break;

    case 81: keyQ();
    break;

    case 82: keyR();
    break;

    case 83: keyS();
    break;

    case 84: keyT();
    break;

    case 85: keyU();
    break;

    case 86: keyV();
    break;

    case 87: keyW();
    break;

    case 88: keyX();
    break;

    case 89: keyY();
    break;

    case 90: keyZ();
    break;

    case 96: key0();
    break;

    case 97: key1();
    break;

    case 98: key2();
    break;

    case 99: key3();
    break;

    case 100: key4();
    break;

    case 101: key5();
    break;

    case 102: key6();
    break;

    case 103: key7();
    break;

    case 104: key8();
    break;

    case 105: key9();
    break;

    // Gets the jim help element to toggle the none class
    default:
    document.getElementById('jim-help').classList.toggle('none');
  }
}
697073
function onKeyEventTargetKeyDown(e) {
      var macroModeState = vimGlobalState.macroModeState;
      var lastChange = macroModeState.lastInsertModeChanges;
      var keyName = CodeMirror.keyName(e);
      function onKeyFound() {
        lastChange.changes.push(new InsertModeKey(keyName));
        return true;
      }
      if (keyName.indexOf('Delete') != -1 || keyName.indexOf('Backspace') != -1) {
        CodeMirror.lookupKey(keyName, ['vim-insert'], onKeyFound);
      }
    }
1264287
function keyboardNavigation() {
        var _this3 = this;

        if (this.events.hasOwnProperty('keyboard')) {
            return false;
        }
        this.events['keyboard'] = addEvent('keydown', {
            onElement: window,
            withCallback: function withCallback(event, target) {
                event = event || window.event;
                var key = event.keyCode;
                if (key == 39) _this3.nextSlide();
                if (key == 37) _this3.prevSlide();
                if (key == 27) _this3.close();
            }
        });
    }
733774
def on_key_down(self, event):
        
        keycode = event.GetKeyCode()
        meta_down = event.MetaDown() or event.GetCmdDown()
        if keycode == 86 and meta_down:
            # treat it as if it were a wx.EVT_TEXT_SIZE
            self.do_fit(event)
148756
function keydown(event) {
			var inc = 0;
			if (ctrl.horizontal) {
				if (event.which === 37) { // LEFT
					inc = -1;
				} else if (event.which === 39) { // RIGHT
					inc = 1;
				}
			} else {
				var innerLimit = ctrl.getInnerLimit();
				if (event.which === 38) { // UP
					inc = -1;
				} else if (event.which === 40) { // DOWN
					inc = 1;
				} else if (event.which === 33) { // PAGEUP
					inc = -innerLimit;
				} else if (event.which === 34) { // PAGEDOWN
					inc = innerLimit;
				} else if (event.which === 35) { // END
					inc = $scope.total - $scope.ngBegin - innerLimit;
				} else if (event.which === 36) { // HOME
					inc = -$scope.ngBegin;
				}
			}
			if (inc !== 0) {
				boxesScrollServices.stopEvent(event);
				$scope.ngBegin = $scope.ngBegin + inc;
			}
		}
474634
function handleHeadingKeydown(e) {
    eventUtils.handleLeftRightArrowsKeydown(e, () => {
        e.preventDefault();
        let index = getElementIndex(getHeadingEl(e, this.state.fake));
        const maxIndex = this.headingsEl.children.length - 1;
        const keyCode = e.charCode || e.keyCode;
        if (keyCode === 37) index = index === 0 ? maxIndex : index - 1;
        if (keyCode === 39) index = index === maxIndex ? 0 : index + 1;

        this.headingsEl.children[index].focus();
        if (this.state.activation === 'auto') this.processStateChange(index);
    });
    eventUtils.handleActionKeydown(e, () => {
        e.preventDefault();
        this.handleHeadingClick(e);
    });
}
717375
function onVolumeKeydown(event) {
		const { keyCode, shiftKey } = event;

		// 37: LEFT, 38: UP, 39: RIGHT, 40: DOWN
		if (37 <= keyCode && 40 >= keyCode) {
			event.preventDefault();

			const isLTR = /^(btt|ltr)$/.test(volumeDir);
			const offset = 37 === keyCode || 39 === keyCode ? keyCode - 38 : isLTR ? 39 - keyCode : keyCode - 39;

			media.volume = Math.max(0, Math.min(1, media.volume + offset * (isLTR ? 0.1 : -0.1) * (shiftKey ? 1 : 0.2)));
		}
	}
260883
function (keyCode, cb) {
            if (keyCode == this.KEYS.VK_SHIFT) {
                this._keyShift = true;
            }
            if (keyCode == this.KEYS.VK_CTRL) {
                this._keyCtrl = true;
            }
            if (typeof keyCode == "string" && this._keyShift) {
                keyCode = keyCode.toUpperCase();
            }
            if (keyCode == this.KEYS.VK_ALT) {
                this._keyAlt = true;
            }
            this._sendEvent('keydown', keyCode, null, null, this._getModifier());
            this._callCallback(cb);
        }
1015230
function _handleKeyEvent(event) {
        var i, handled = false;
        for (i = _globalKeydownHooks.length - 1; i >= 0; i--) {
            if (_globalKeydownHooks[i](event)) {
                handled = true;
                break;
            }
        }
        _detectAltGrKeyDown(event);
        if (!handled && _handleKey(_translateKeyboardEvent(event))) {
            event.stopPropagation();
            event.preventDefault();
        }
    }
437067
function(event) {
      if (this.frozen == "leave") this.frozen = null;
      if (this.frozen && (!this.keyFilter || this.keyFilter(event.keyCode))) {
        event.stop();
        this.frozen(event);
        return;
      }

      var code = event.keyCode;
      // Don't scan when the user is typing.
      this.delayScanning();
      // Schedule a paren-highlight event, if configured.
      if (this.options.autoMatchParens)
        this.scheduleParenHighlight();

      // The various checks for !altKey are there because AltGr sets both
      // ctrlKey and altKey to true, and should not be recognised as
      // Control.
      if (code == 13) { // enter
        if (event.ctrlKey && !event.altKey) {
          this.reparseBuffer();
        }
        else {
          select.insertNewlineAtCursor(this.win);
          this.indentAtCursor();
          select.scrollToCursor(this.container);
        }
        event.stop();
      }
      else if (code == 9 && this.options.tabMode != "default" && !event.ctrlKey) { // tab
        this.handleTab(!event.shiftKey);
        event.stop();
      }
      else if (code == 32 && event.shiftKey && this.options.tabMode == "default") { // space
        this.handleTab(true);
        event.stop();
      }
      else if (code == 36 && !event.shiftKey && !event.ctrlKey) { // home
        if (this.home()) event.stop();
      }
      else if (code == 35 && !event.shiftKey && !event.ctrlKey) { // end
        if (this.end()) event.stop();
      }
      else if ((code == 219 || code == 221) && event.ctrlKey && !event.altKey) { // [, ]
        this.highlightParens(event.shiftKey, true);
        event.stop();
      }
      else if (event.metaKey && !event.shiftKey && (code == 37 || code == 39)) { // Meta-left/right
        var cursor = select.selectionTopNode(this.container);
        if (cursor === false || !this.container.firstChild) return;

        if (code == 37) select.focusAfterNode(startOfLine(cursor), this.container);
        else {
          var end = endOfLine(cursor, this.container);
          select.focusAfterNode(end ? end.previousSibling : this.container.lastChild, this.container);
        }
        event.stop();
      }
      else if ((event.ctrlKey || event.metaKey) && !event.altKey) {
        if ((event.shiftKey && code == 90) || code == 89) { // shift-Z, Y
          select.scrollToNode(this.history.redo());
          event.stop();
        }
        else if (code == 90 || (safari && code == 8)) { // Z, backspace
          select.scrollToNode(this.history.undo());
          event.stop();
        }
        else if (code == 83 && this.options.saveFunction) { // S
          this.options.saveFunction();
          event.stop();
        }
        else if (internetExplorer && code == 86) {
          this.reroutePasteEvent();
        }
      }
    }
750996
function (event) {
                if (event.keyCode == aria.DomEvent.KC_SPACE) {
                    this._setRadioValue();
                    event.preventDefault(true);
                } else if (event.keyCode == aria.DomEvent.KC_LEFT) {
                    this._navigate(-1);
                    event.preventDefault(true);
                } else if (event.keyCode == aria.DomEvent.KC_RIGHT) {
                    this._navigate(+1);
                    event.preventDefault(true);
                } else if (event.keyCode == aria.DomEvent.KC_DOWN) {
                    this._navigate(+1);
                    event.preventDefault(true);
                } else if (event.keyCode == aria.DomEvent.KC_UP) {
                    this._navigate(-1);
                    event.preventDefault(true);
                }
            }