*/\r
CKEDITOR.editor.prototype.setMode = function( mode )\r
{\r
+ this.fire( 'beforeSetMode', { newMode : mode } );\r
+\r
var data,\r
holderElement = this.getThemeSpace( 'contents' ),\r
isDirty = this.checkDirty();\r
*/\r
CKEDITOR.editor.prototype.focus = function()\r
{\r
+ this.forceNextSelectionCheck();\r
var mode = getMode( this );\r
if ( mode )\r
mode.focus();\r
\r
/**\r
* Sets whether the editor should have the focus when the page loads.\r
+ * @name CKEDITOR.config.startupFocus\r
* @type Boolean\r
* @default false\r
* @example\r
*/\r
\r
/**\r
- * Fired before changing the editing mode\r
+ * Fired before changing the editing mode.\r
* @name CKEDITOR.editor#beforeModeUnload\r
* @event\r
*/\r
+\r
+ /**\r
+ * Fired before the editor mode is set.\r
+ * @name CKEDITOR.editor#beforeSetMode\r
+ * @event\r
+ * @since 3.5.3\r
+ * @param {String} newMode The name of the mode which is about to be set.\r
+ */\r