Yet more fixes for r59799: fix typo, JS error in js2stopgap, reminify.
authorRoan Kattouw <catrope@users.mediawiki.org>
Mon, 7 Dec 2009 21:28:52 +0000 (21:28 +0000)
committerRoan Kattouw <catrope@users.mediawiki.org>
Mon, 7 Dec 2009 21:28:52 +0000 (21:28 +0000)
js2/js2stopgap.js
js2/js2stopgap.min.js

index 28baceb..0a72515 100644 (file)
@@ -9467,7 +9467,7 @@ $j = jQuery.noConflict();
 /**
  * Provides js2 compatible mw functions
  */
-if( !mw ){
+if( typeof mw == 'undefined' || !mw ){
    mw = { };
    /**
     * Provides js2 compatible onload hook
@@ -9477,7 +9477,7 @@ if( !mw ){
        $j(document).ready( func );
    }
    // Define a dummy mw.load function:
-   mw.load = function( callback) { callbcak() };
+   mw.load = function( deps, callback ) { callback(); };
    
    // Creates global message object if not already in existence
        if ( !gMsg ) var gMsg = {};
@@ -9515,4 +9515,4 @@ if( !mw ){
                }
        }
    
-}
\ No newline at end of file
+}
index 94cd141..b5e9820 100644 (file)
@@ -775,8 +775,7 @@ if(props[name]==null||props[name]==undefined)
 target[name]=props[name];return target;};function isArray(a){return(a&&(($.browser.safari&&typeof a=='object'&&a.length)||(a.constructor&&a.constructor.toString().match(/\Array\(\)/))));};$.fn.datepicker=function(options){if(!$.datepicker.initialized){$(document).mousedown($.datepicker._checkExternalClick).find('body').append($.datepicker.dpDiv);$.datepicker.initialized=true;}
 var otherArgs=Array.prototype.slice.call(arguments,1);if(typeof options=='string'&&(options=='isDisabled'||options=='getDate'))
 return $.datepicker['_'+options+'Datepicker'].apply($.datepicker,[this[0]].concat(otherArgs));if(options=='option'&&arguments.length==2&&typeof arguments[1]=='string')
-return $.datepicker['_'+options+'Datepicker'].apply($.datepicker,[this[0]].concat(otherArgs));return this.each(function(){typeof options=='string'?$.datepicker['_'+options+'Datepicker'].apply($.datepicker,[this].concat(otherArgs)):$.datepicker._attachDatepicker(this,options);});};$.datepicker=new Datepicker();$.datepicker.initialized=false;$.datepicker.uuid=new Date().getTime();$.datepicker.version="1.7.2";window.DP_jQuery=$;})(jQuery);if(!gMsg)var gMsg={};function loadGM(msgSet){for(var i in msgSet){gMsg[i]=msgSet[i];}}
+return $.datepicker['_'+options+'Datepicker'].apply($.datepicker,[this[0]].concat(otherArgs));return this.each(function(){typeof options=='string'?$.datepicker['_'+options+'Datepicker'].apply($.datepicker,[this].concat(otherArgs)):$.datepicker._attachDatepicker(this,options);});};$.datepicker=new Datepicker();$.datepicker.initialized=false;$.datepicker.uuid=new Date().getTime();$.datepicker.version="1.7.2";window.DP_jQuery=$;})(jQuery);$j=jQuery.noConflict();if(typeof mw=='undefined'||!mw){mw={};mw.addOnloadHook=function(func){$j(document).ready(func);}
+mw.load=function(deps,callback){callback();};if(!gMsg)var gMsg={};mw.addMessages=function(msgSet){for(var i in msgSet){gMsg[i]=msgSet[i];}}
 function gM(key,args){var ms='';if(key in gMsg){ms=gMsg[key];if(typeof args=='object'||typeof args=='array'){for(var v in args){var rep='\$'+(parseInt(v)+1);ms=ms.replace(rep,args[v]);}}else if(typeof args=='string'||typeof args=='number'){ms=ms.replace(/\$1/,args);}
-return ms;}else{return'['+key+']';}}
-$j=jQuery.noConflict();function js2AddOnloadHook(func){$j(document).ready(func);}
-mvJsLoader={doLoad:function(deps,callback){callback();}};
\ No newline at end of file
+return ms;}else{return'['+key+']';}}}
\ No newline at end of file