summaryrefslogtreecommitdiff
path: root/core/editor_basic.js
diff options
context:
space:
mode:
authorlsces <lester@lsces.co.uk>2013-07-15 14:22:23 +0100
committerlsces <lester@lsces.co.uk>2013-07-15 14:22:23 +0100
commit6d4c4f12d15ae68d912972921997a8c5180c9aea (patch)
tree104274447272d09617c483cf6b0ee79559c9fe6f /core/editor_basic.js
parentde6d09676a9527919813a4474cc28af554a35fe1 (diff)
downloadckeditor-6d4c4f12d15ae68d912972921997a8c5180c9aea.tar.gz
ckeditor-6d4c4f12d15ae68d912972921997a8c5180c9aea.tar.bz2
ckeditor-6d4c4f12d15ae68d912972921997a8c5180c9aea.zip
Upgrade to CKEditor V4
Directory structure changed so many files removed and replace in a new location This batch is the delete and add
Diffstat (limited to 'core/editor_basic.js')
-rw-r--r--core/editor_basic.js36
1 files changed, 36 insertions, 0 deletions
diff --git a/core/editor_basic.js b/core/editor_basic.js
new file mode 100644
index 0000000..8c54b8f
--- /dev/null
+++ b/core/editor_basic.js
@@ -0,0 +1,36 @@
+/**
+ * @license Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
+ * For licensing, see LICENSE.html or http://ckeditor.com/license
+ */
+
+if ( !CKEDITOR.editor ) {
+ // Documented at editor.js.
+ CKEDITOR.editor = function() {
+ // Push this editor to the pending list. It'll be processed later once
+ // the full editor code is loaded.
+ CKEDITOR._.pending.push( [ this, arguments ] );
+
+ // Call the CKEDITOR.event constructor to initialize this instance.
+ CKEDITOR.event.call( this );
+ };
+
+ // Both fire and fireOnce will always pass this editor instance as the
+ // "editor" param in CKEDITOR.event.fire. So, we override it to do that
+ // automaticaly.
+ CKEDITOR.editor.prototype.fire = function( eventName, data ) {
+ if ( eventName in { instanceReady:1,loaded:1 } )
+ this[ eventName ] = true;
+
+ return CKEDITOR.event.prototype.fire.call( this, eventName, data, this );
+ };
+
+ CKEDITOR.editor.prototype.fireOnce = function( eventName, data ) {
+ if ( eventName in { instanceReady:1,loaded:1 } )
+ this[ eventName ] = true;
+
+ return CKEDITOR.event.prototype.fireOnce.call( this, eventName, data, this );
+ };
+
+ // "Inherit" (copy actually) from CKEDITOR.event.
+ CKEDITOR.event.implementOn( CKEDITOR.editor.prototype );
+}