Reference to the associated mxGraph.
Optional reference to the event target. If null, the document element is used as the event target, that is, the object where the key event listener is installed.
Maps from keycodes to functions for pressed control keys.
Maps from keycodes to functions for pressed control and shift keys.
Specifies if events are handled. Default is true.
Reference to the mxGraph associated with this handler.
Maps from keycodes to functions for non-pressed control keys.
Maps from keycodes to functions for pressed shift keys.
Reference to the target DOM, that is, the DOM node where the key event listeners are installed.
Binds the specified keycode to the given function. This binding is used if the control key is pressed.
Binds the specified keycode to the given function. This binding is used if the control and shift key are pressed.
Binds the specified keycode to the given function. This binding is used if the control key is not pressed.
Binds the specified keycode to the given function. This binding is used if the shift key is pressed.
Destroys the handler and all its references into the DOM. This does normally not need to be called, it is called automatically when the window unloads (in IE).
Hook to process ESCAPE keystrokes. This implementation invokes mxGraph.stopEditing to cancel the current editing, connecting and/or other ongoing modifications.
Returns the function associated with the given key event or null if no function is associated with the given event.
Returns true if the control key is pressed. This uses mxEvent.isControlDown.
Returns true if events are handled. This implementation returns enabled.
Returns true if the given event should be handled. isEventIgnored is called later if the event is not an escape key stroke, in which case escape is called. This implementation returns true if isEnabled returns true for both, this handler and graph, if the event is not consumed and if isGraphEvent returns true.
Returns true if the given keystroke should be ignored. This returns graph.isEditing().
Returns true if the event should be processed by this handler, that is, if the event source is either the target, one of its direct children, a descendant of the <mxGraph.container>, or the mxGraph.cellEditor of the graph.
Handles the event by invoking the function bound to the respective keystroke if isEnabledForEvent returns true for the given event and if isEventIgnored returns false, except for escape for which isEventIgnored is not invoked.
Enables or disables event handling by updating enabled.
Generated using TypeDoc
Constructs an event handler that executes functions bound to specific keystrokes.
鸿则 hungtcs@163.com
2020-01-09