public/ckeditor/4.4dev/core/editor.js
function() {
			var keystrokes = this.keystrokeHandler.keystrokes,
				newKeystrokes = CKEDITOR.tools.isArray( arguments[ 0 ] ) ? arguments[ 0 ] : [ [].slice.call( arguments, 0 ) ],
				keystroke, behavior;

			for ( var i = newKeystrokes.length; i--; ) {
				keystroke = newKeystrokes[ i ];
				behavior = 0;

				// It may be a pair of: [ key, command ]
				if ( CKEDITOR.tools.isArray( keystroke ) ) {
					behavior = keystroke[ 1 ];
					keystroke = keystroke[ 0 ];
				}

				if ( behavior )
					keystrokes[ keystroke ] = behavior;
				else
					delete keystrokes[ keystroke ];
			}
		}
function() {
			var keystrokes = this.keystrokeHandler.keystrokes,
				newKeystrokes = CKEDITOR.tools.isArray( arguments[ 0 ] ) ? arguments[ 0 ] : [ [].slice.call( arguments, 0 ) ],
				keystroke, behavior;

			for ( var i = newKeystrokes.length; i--; ) {
				keystroke = newKeystrokes[ i ];
				behavior = 0;

				// It may be a pair of: [ key, command ]
				if ( CKEDITOR.tools.isArray( keystroke ) ) {
					behavior = keystroke[ 1 ];
					keystroke = keystroke[ 0 ];
				}

				if ( behavior )
					keystrokes[ keystroke ] = behavior;
				else
					delete keystrokes[ keystroke ];
			}
		}
function ( ) { var keystrokes = this . keystrokeHandler . keystrokes , newKeystrokes = CKEDITOR . tools . isArray ( arguments [ 0 ] ) ? arguments [ 0 ] : [ [ ] . slice . call ( arguments , 0 ) ] , keystroke , behavior ; for ( var i = newKeystrokes . length ; i -- ; ) { keystroke = newKeystrokes [ i ] ; behavior = 0 ; // It may be a pair of: [ key, command ] if ( CKEDITOR . tools . isArray ( keystroke ) ) { behavior = keystroke [ 1 ] ; keystroke = keystroke [ 0 ] ; } if ( behavior ) keystrokes [ keystroke ] = behavior ; else delete keystrokes [ keystroke ] ; } }
Assigns keystrokes associated to editor commands.

editor.setKeystroke( CKEDITOR.CTRL + 115, 'save' );	// Assigned CTRL+S to "save" command.
editor.setKeystroke( CKEDITOR.CTRL + 115, false );	// Disabled CTRL+S keystroke assignment.
editor.setKeystroke( [
[ CKEDITOR.ALT + 122, false ],
[ CKEDITOR.CTRL + 121, 'link' ],
[ CKEDITOR.SHIFT + 120, 'bold' ]
] );

This method may be used in the following cases:

* By plugins (like `link` or `basicstyles`) to set their keystrokes when plugins are being loaded.
* During the runtime to modify existing keystrokes.

The editor handles keystroke configuration in the following order:

1. Plugins use this method to define default keystrokes.
2. Editor extends default keystrokes with {@link CKEDITOR.config#keystrokes}.
3. Editor blocks keystrokes defined in {@link CKEDITOR.config#blockedKeystrokes}.

After all, you can still set new keystrokes using this method during the runtime.

@since 4.0
@param {Number/Array} keystroke Keystroke or an array of keystroke definitions.
@param {String/Boolean} [behavior] A command to be executed on the keystroke.
Assigns keystrokes associated to editor commands .