JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
vanilla ckeditor-3.6.3
[ckeditor.git] / _source / core / scriptloader.js
index 0ad7d86..3640fcd 100644 (file)
@@ -1,5 +1,5 @@
 /*\r
-Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved.\r
+Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved.\r
 For licensing, see LICENSE.html or http://ckeditor.com/license\r
 */\r
 \r
@@ -15,8 +15,8 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
  */\r
 CKEDITOR.scriptLoader = (function()\r
 {\r
-       var uniqueScripts = {};\r
-       var waitingList = {};\r
+       var uniqueScripts = {},\r
+               waitingList = {};\r
 \r
        return /** @lends CKEDITOR.scriptLoader */ {\r
                /**\r
@@ -33,8 +33,8 @@ CKEDITOR.scriptLoader = (function()
                 *              ones.\r
                 * @param {Object} [scope] The scope ("this" reference) to be used for\r
                 *              the callback call. Default to {@link CKEDITOR}.\r
-                * @param {Boolean} [noCheck] Indicates that the script must be loaded\r
-                *              anyway, not checking if it has already loaded.\r
+                * @param {Boolean} [showBusy] Changes the cursor of the document while\r
++               *              the script is loaded.\r
                 * @example\r
                 * CKEDITOR.scriptLoader.load( '/myscript.js' );\r
                 * @example\r
@@ -51,7 +51,7 @@ CKEDITOR.scriptLoader = (function()
                 *         alert( 'Number of failures: ' + failed.length );\r
                 *     });\r
                 */\r
-               load : function( scriptUrl, callback, scope, noCheck, showBusy )\r
+               load : function( scriptUrl, callback, scope, showBusy )\r
                {\r
                        var isString = ( typeof scriptUrl == 'string' );\r
 \r
@@ -109,7 +109,7 @@ CKEDITOR.scriptLoader = (function()
 \r
                        var loadScript = function( url )\r
                        {\r
-                               if ( noCheck !== true && uniqueScripts[ url ] )\r
+                               if ( uniqueScripts[ url ] )\r
                                {\r
                                        checkLoaded( url, true );\r
                                        return;\r
@@ -175,24 +175,6 @@ CKEDITOR.scriptLoader = (function()
                        {\r
                                loadScript( scriptUrl[ i ] );\r
                        }\r
-               },\r
-\r
-               /**\r
-                * Executes a JavaScript code into the current document.\r
-                * @param {String} code The code to be executed.\r
-                * @example\r
-                * CKEDITOR.scriptLoader.loadCode( 'var x = 10;' );\r
-                * alert( x );  // "10"\r
-                */\r
-               loadCode : function( code )\r
-               {\r
-                       // Create the <script> element.\r
-                       var script = new CKEDITOR.dom.element( 'script' );\r
-                       script.setAttribute( 'type', 'text/javascript' );\r
-                       script.appendText( code );\r
-\r
-                       // Append it to <head>.\r
-                       script.appendTo( CKEDITOR.document.getHead() );\r
                }\r
        };\r
 })();\r