* initial configuration via jQuery.extend in mv_embed
authorMichael Dale <dale@users.mediawiki.org>
Fri, 11 Sep 2009 18:00:09 +0000 (18:00 +0000)
committerMichael Dale <dale@users.mediawiki.org>
Fri, 11 Sep 2009 18:00:09 +0000 (18:00 +0000)
* re-added example_folder (removed all non-commons external javascript and images calls)
** (The only external js is the commons api query)
** Theme based javascript include request changed to link to external site to install bookmarklet
** Timed text example removed (did jsonp call to get text)
*** Will re-add local file based timed text example shortly.

js2/mwEmbed/example_usage/Add_Media_Wizard.html [new file with mode: 0644]
js2/mwEmbed/example_usage/Firefogg_Make_Advanced.html [new file with mode: 0644]
js2/mwEmbed/example_usage/Player_RelatedVideos.html [new file with mode: 0644]
js2/mwEmbed/example_usage/Player_Simple_Themable.html [new file with mode: 0644]
js2/mwEmbed/example_usage/Sequence_Editor.html [new file with mode: 0644]
js2/mwEmbed/example_usage/media/sample_smil.xml [new file with mode: 0644]
js2/mwEmbed/libAddMedia/remoteSearchDriver.js
js2/mwEmbed/libAddMedia/seqRemoteSearchDriver.js
js2/mwEmbed/libSequencer/mvSequencer.js
js2/mwEmbed/mv_embed.js

diff --git a/js2/mwEmbed/example_usage/Add_Media_Wizard.html b/js2/mwEmbed/example_usage/Add_Media_Wizard.html
new file mode 100644 (file)
index 0000000..898c786
--- /dev/null
@@ -0,0 +1,50 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
+"http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<head>
+       <title>sample mv embed</title>
+       <style type="text/css">
+               body{
+                       font-size:80%;
+               }
+               img  {
+                       border:medium none;
+               }
+       </style>
+       <script type="text/javascript" src="../mv_embed.js?debug=true"></script>                 
+       <script type="text/javascript">
+       mwAddOnloadHook(function(){
+               $j('#add_media_link').addMediaWiz( {
+                       'profile':'html_edit',                  
+                       'target_textbox': '#wpTextbox1',
+                       'target_render_area':'#inline_append',                  
+                       'import_url_mode':'remote_link',        
+                       //note selections in the textbox will take over the default query
+                       'default_query': 'fish',        
+                       
+                       //we only enabled commons
+               //(since javascript includes from other servers would be problamatic ) in a default install
+            //** but you can set this to 'all' to pull from multiple repositories  
+            'enabled_cps':['wiki_commons'],            
+                       
+                       //the local wiki api url: 
+                       'local_wiki_api_url': 'none'
+               });                     
+       });     
+       
+       </script> 
+</head>
+<body>
+<h3> Sample Add Media Wizard </h3>
+
+<a id="add_media_link" href="#">Add Media</a><br>
+<b>note</b> only commons is enabled by default. For more options see source code.<br><br> 
+<table border="1" width="800">
+<tr>
+<td valign="top" width="50%" id="inline_append">Asset Output</td>
+<td  valign="top" width="50%" >Html Output:<textarea id="wpTextbox1" cols="60" rows="6" id="code_append" name="wpTextbox1" tabindex="3"/></textarea></td>
+</tr>
+</table>
+</body>
+</html>
+
diff --git a/js2/mwEmbed/example_usage/Firefogg_Make_Advanced.html b/js2/mwEmbed/example_usage/Firefogg_Make_Advanced.html
new file mode 100644 (file)
index 0000000..4eb0dd0
--- /dev/null
@@ -0,0 +1,92 @@
+<!DOCTYPE HTML>
+<html><head>
+<meta http-equiv="content-type" content="text/html; charset=UTF-8">
+    <title>Firefogg - Make Ogg Video in your Browser</title>
+       <script type="text/javascript" src="../jsScriptLoader.php?urid=18&class=mv_embed,window.jQuery,mvBaseUploadInterface,mvFirefogg,mvAdvFirefogg,$j.ui,$j.ui.progressbar,$j.ui.dialog,$j.cookie,$j.ui.accordion,$j.ui.slider,$j.ui.datepicker"></script>
+       <!-- <script type="text/javascript" src="../mv_embed.js"></script> -->
+<style type="text/css" media="all">body {
+  margin: 0;
+  padding: 0;
+  font-family: Vera Sans, sans-serif;
+  font-size: 12px;
+  color: #000;
+  background: #fff;
+}
+
+a {
+  color: #000;
+}
+img {
+  border: 0;
+}
+h1, h2 {
+  text-align: center;
+}
+h1 {
+  font-size: 48px;
+  letter-spacing: 0.25em;
+  margin-bottom: 0;
+  line-height: 0.8em;
+}
+h2 {
+  margin-left: -11px;
+  font-size: 12px;
+  font-weight: normal;
+  letter-spacing: 0.1em;
+}
+
+#main {
+  margin-top: 10px;
+}
+
+.install {
+  margin-left: auto;
+  margin-right: auto;
+  width: 180px;
+  padding: 8px;
+  background-color: #fe0000;
+  font-size: 12px;
+  font-weight: bold;
+  text-align: center;
+}
+
+.install a {
+  color: #000;
+}
+
+#nav {
+  margin-left: -11px;
+  text-align: center;
+  padding-bottom: 20px;
+}
+</style>
+<style type="text/css" media="all">
+.install{
+display:none;
+}
+</style>
+<script type="text/javascript">
+mwAddOnloadHook(function(){
+       $j('#firefogg_app').firefogg({
+                       'encoder_interface'     : true,
+                       'encode_local'          : true
+       },function(){
+               $j('#loadFogg').hide();
+       });
+});
+</script>
+</head><body>
+<div id="main">
+  <h1>Make Ogg Video</h1>
+<br>   
+       <br>
+       <div style="margin-right:auto;margin-left:auto;width:500px;" id="loadFogg">Loading firefogg<blink>...</blink></div>     
+       <div style="margin-right:auto;margin-left:auto;width:500px;height:230px"  id="firefogg_app"></div>
+       
+       <div style="height:295px"></div>
+       <center><span style="font:size:80%">Built using <a href="http://firefogg.org">firefogg</a>, <a href="http://www.mediawiki.org/wiki/Media_Projects_Overview#MwEmbed">MwEmbed</a> and <a href="http://jqueryui.com/">jquery.ui</a>. Supports  
+               custom themes via the <a href="http://jqueryui.com/themeroller/developertool/">ThemeRoller Dev Tool</a>
+       </span>
+       </center>
+</body></html>
+
diff --git a/js2/mwEmbed/example_usage/Player_RelatedVideos.html b/js2/mwEmbed/example_usage/Player_RelatedVideos.html
new file mode 100644 (file)
index 0000000..f365225
--- /dev/null
@@ -0,0 +1,29 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
+"http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<head>
+       <title>Simple Video Tag Usage</title>
+       <script type="text/javascript" src="../mv_embed.js?debug=true"></script>
+</head>
+<body>
+<h3> Simple Video Relational Audio and Video the Commons </h3>
+This Example search primitive video in the Wikimedia Commons
+<span id="default_attr">
+</span> <br />
+<br />
+  <table border="1" cellpadding="6" width="600">
+                   <tr>
+             <td valign="top"> 
+             <video wikiTitleKey="File:B-36_bomber.ogg" durationHint="2" poster="http://upload.wikimedia.org/wikipedia/commons/thumb/0/0d/B-36_bomber.ogg/mid-B-36_bomber.ogg.jpg&size=400x300" src="http://upload.wikimedia.org/wikipedia/commons/0/0d/B-36_bomber.ogg"></video></td>
+             <td valign="top"><b>Sample Relational Video And Audio</b><br />
+               <pre>The Example Code ::: </pre>
+               &lt;video wikiTitleKey="File:B-36_bomber.ogg" durationHint="2"
+                    poster="http://upload.wikimedia.org/wikipedia/commons/thumb/0/0d/B-36_bomber.ogg/mid-B-36_bomber.ogg.jpg&size=400x300"
+               src="http://upload.wikimedia.org/wikipedia/commons/0/0d/B-36_bomber.ogg"&gt;&lt;/video&gt;
+               </br>
+             </td>
+             </table>
+       <br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br />&nbsp;
+  </body>
+</html>        
+
diff --git a/js2/mwEmbed/example_usage/Player_Simple_Themable.html b/js2/mwEmbed/example_usage/Player_Simple_Themable.html
new file mode 100644 (file)
index 0000000..9795046
--- /dev/null
@@ -0,0 +1,23 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
+"http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<head>
+       <title>Sample Themed Player</title>
+       <script type="text/javascript" src="../mv_embed.js?debug=true"></script>         
+</head>
+<script type="text/javascript">
+</script>
+<body bgcolor="#FFF">
+<h3> Sample Simple Themable Player:</h3>
+To play with dynamic Themes install <a href="http://jqueryui.com/themeroller/developertool/">Themeroller</a><p><p>
+<div style="width:450px;float:left">
+<video src="http://upload.wikimedia.org/wikipedia/commons/d/d3/Okapia_johnstoni5.ogg" 
+               thumbnail="http://upload.wikimedia.org/wikipedia/commons/thumb/d/d3/Okapia_johnstoni5.ogg/mid-Okapia_johnstoni5.ogg.jpg" durationHint="15"></video>
+               </div>  
+<div style="float:left">
+<b>Source Code used:</b><br>
+<textarea cols="50" rows="7"><video src="http://upload.wikimedia.org/wikipedia/commons/d/d3/Okapia_johnstoni5.ogg" thumbnail="http://upload.wikimedia.org/wikipedia/commons/thumb/d/d3/Okapia_johnstoni5.ogg/mid-Okapia_johnstoni5.ogg.jpg" durationHint="15"></video></textarea>
+</div>
+</body>
+</html>
+
diff --git a/js2/mwEmbed/example_usage/Sequence_Editor.html b/js2/mwEmbed/example_usage/Sequence_Editor.html
new file mode 100644 (file)
index 0000000..1b5eb7c
--- /dev/null
@@ -0,0 +1,40 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
+"http://www.w3.org/TR/html4/loose.dtd">
+<html>
+<head>
+       <title>SMIL Sequence Editor example</title>
+       <script type="text/javascript" src="../mv_embed.js?debug=true"></script>
+       <script type="text/javascript">
+               mwAddOnloadHook(function(){
+                       $j('#seqcontainer').sequencer({
+                       'mv_pl_src':'media/sample_smil.xml',
+                       //set the add media wizard to only include commons:   
+                       'amw_conf':{
+                                'enabled_cps':['wiki_commons']
+                       }               
+               });
+               });
+       </script>
+<style>
+       body {
+               font: x-small sans-serif;
+               background: #f9f9f9 url(headbg.jpg) 0 0 no-repeat;
+               color: black;
+               margin: 0;
+               padding: 0;
+       }
+       img {
+                       border:medium none;
+               }
+</style>
+       
+</head>
+<body>
+<h3> Simple SMIL example</h3>
+       <div id="seqcontainer" style="position:absolute;top:50px;bottom:10px;left:10px;right:10px;">
+               Loading sequence editor <blink>...</blink>
+       </div>
+       
+  </body>
+</html>
+
diff --git a/js2/mwEmbed/example_usage/media/sample_smil.xml b/js2/mwEmbed/example_usage/media/sample_smil.xml
new file mode 100644 (file)
index 0000000..e141b36
--- /dev/null
@@ -0,0 +1,45 @@
+<smil xmlns="http://www.w3.org/2001/SMIL20/Language">
+  <head>
+    <meta name="title" content="Simple Crossfading Example"/>
+    
+    <transition id="fromGreen"
+       type="fade" 
+       subtype="fadeFromColor" 
+       fadeColor="#87CF87" 
+       dur="4s"/>
+       
+    <transition id="toGreen"
+       type="fade"
+       subtype="fadeToColor"
+       fadeColor="#87CF87" 
+       dur="4s"/>
+       
+    <transition id="xFade" 
+       type="fade" 
+       subtype="crossfade" 
+       dur="4s"/>
+       
+  </head>
+  <body>
+    <seq>
+
+       <video src="http://upload.wikimedia.org/wikipedia/commons/d/d3/Okapia_johnstoni5.ogg" 
+               region="video_region" 
+               transIn="fromGreen"     
+               transOut="xFade"        
+               type="video/ogg"        
+               fill="transition"
+               dur="7s"
+               poster="http://upload.wikimedia.org/wikipedia/commons/thumb/d/d3/Okapia_johnstoni5.ogg/mid-Okapia_johnstoni5.ogg.jpg"/> 
+       
+    <video src="http://upload.wikimedia.org/wikipedia/commons/0/0d/B-36_bomber.ogg" 
+               region="video_region"                           
+               fill="transition" 
+               dur="10s"
+               type="video/ogg" 
+               poster="http://upload.wikimedia.org/wikipedia/commons/thumb/0/0d/B-36_bomber.ogg/mid-B-36_bomber.ogg.jpg"/>     
+    </seq>
+  </body>
+</smil>
+
+
index 3384abb..cb822da 100644 (file)
@@ -73,9 +73,12 @@ var default_remote_search_options = {
        'p_seq':null,
        'cFileNS':'File', //What is the canonical namespace prefix for images
                                          //@@todo (should get that from the api or in-page vars)
-
-       'enable_upload_tab':true, // if we want to enable an uploads tab:
-       'upload_api_target'        : 'http://localhost/wiki_trunk/api.php' // can be local or the url of the upload api.
+       
+       'upload_api_target': 'http://localhost/wiki_trunk/api.php', // can be local or the url of the upload api.
+       
+       'enabled_cps':'all', //can be keyword 'all' or an array of enabled content provider keys
+               
+       'disp_item':'wiki_commons' //sets the default display item:
 }
 
 if(typeof wgServer == 'undefined')
@@ -101,12 +104,7 @@ remoteSearchDriver.prototype = {
                'advanced_search':{
                        'title': 'Advanced Options'
                }
-       },
-       /*
-        * sets the default display item:
-        * can be any content_providers key or 'all'
-        */
-       disp_item : 'wiki_commons',
+       },      
        /** the default content providers list.
         *
         * (should be note that special tabs like "upload" and "combined" don't go into the content proviers list:
@@ -203,6 +201,12 @@ remoteSearchDriver.prototype = {
                        'remote_embed_ext': false, //if running the remoteEmbed extension no need to copy local
                                                                           //syntax will be [remoteEmbed:roe_url link title]
                        'tab_img':true
+               },
+               //special cp "upload"
+               'upload':{
+                       'enabled':1,
+                       'checked':1,
+                       'title' :'Upload'                       
                }
        },
        //define the licenses
@@ -310,7 +314,7 @@ remoteSearchDriver.prototype = {
                };
        },
        //some default layout values:
-       thumb_width              : 80,
+       thumb_width                     : 80,
        image_edit_width        : 400,
        video_edit_width        : 400,
        insert_text_pos         : 0,      //insert at the start (will be overwritten by the user cursor pos)
@@ -320,42 +324,29 @@ remoteSearchDriver.prototype = {
        cEdit                           : null,
        dmodalCss                       : {},
 
-       init: function( iObj ){
+       init: function( options ){
                var _this = this;
                js_log('remoteSearchDriver:init');
-               for( var i in default_remote_search_options ) {
-                       if( iObj[i]){
-                               this[ i ] = iObj[i];
-                       }else{
-                               this[ i ] = default_remote_search_options[i];
-                       }
-               }
+               
+               //merge in the options:  
+               //@@todo for cleaner config we should set _this.opt to the provided options) 
+               $j.extend( _this, default_remote_search_options, options);
+               
                //update the base text:
                if(_this.target_textbox)
                   _this.getTexboxSelection();
 
-               //set up the content provider config:
-               if( this.cpconfig ){
-                       for(var cpc in cpconfig){
-                               for(var cinx in this.cpconfig[cpc]){
-                                       if( this.content_providers[cpc] )
-                                               this.content_providers[ cpc ][ cinx ] = this.cpconfig[cpc][ cinx];
-                               }
-                       }
-               }
-
-               //make sure the selected cp has an api to query against (if its a content_provider
-               if( this.content_providers[ this.disp_item ] &&
-                       !this.content_providers[ this.disp_item ].api_url  ){
-                       for(var inx in this.content_providers){
-                               if( this.content_providers[ inx ].api_url ){
-                                       this.disp_item = inx;
-                                       break;
+               //modify the content provider config based on options: 
+               if(_this.enabled_cps != 'all'){
+                       for(var i in this.content_providers){
+                               if( $j.inArray(i, _this.enabled_cps)!= -1){
+                                       this.content_providers[i].enabled = true;
+                               }else{
+                                       this.content_providers[i].enabled = false;
                                }
                        }
                }
 
-
                //set up the default model config:
                this.dmodalCss = {
                        'width':'auto',
@@ -602,13 +593,13 @@ remoteSearchDriver.prototype = {
                        if( parseUri( document.URL ).host == parseUri( _this.upload_api_target ).host ){
                                mvJsLoader.doLoad(['$j.fn.simpleUploadForm'],function(){
 
-                                       //get extened info about the file
+                                       //get extends info about the file
                                        var cp = _this.content_providers['this_wiki'];
                                        //check for "this_wiki" enabled
-                                       if(!cp.enabled){
+                                       /*if(!cp.enabled){
                                                $j('#tab-upload').html('error this_wiki not enabled (can\'t get uploaded file info)');
                                                return false;
-                                       }
+                                       }*/
 
                                        //load  this_wiki search system to grab the rObj
                                        _this.loadSearchLib(cp, function(){
@@ -672,15 +663,14 @@ remoteSearchDriver.prototype = {
                js_log("f:runSearch::" + this.disp_item);
                //draw_direct_flag
                var draw_direct_flag = true;
-               if( !this.content_providers[this.disp_item] ){
-                       //check if its the special upload tab case:
-                       if( this.disp_item == 'upload'){
-                               this.doUploadInteface();
-                       }else{
-                               js_log("can't run search for:" + this.disp_item);
-                       }
-                       return false;
+                       
+               //check if its the special upload tab case:
+               if( this.disp_item == 'upload'){
+                       this.doUploadInteface();
+                       return true;
                }
+               //else do runSearch                     
+               
                cp = this.content_providers[this.disp_item];
 
                //check if we need to update:
@@ -956,7 +946,8 @@ remoteSearchDriver.prototype = {
                p = rid.split('__');
                var cp_id = p[0];
                var rid = p[1];
-
+               
+               //Set the upload helper cp_id (to render recent uploads by this user)
                if(cp_id == 'upload')
                        cp_id = 'this_wiki';
 
index 90d73e2..43496f3 100644 (file)
@@ -17,7 +17,9 @@ seqRemoteSearchDriver.prototype = {
                        'local_wiki_api_url': this_seq.getLocalApiUrl(),
                        'instance_name'         : this_seq.instance_name + '.mySearch',
                        'default_query'         : this.pSeq.plObj.title
-               }
+               }               
+               if(typeof this_seq.amw_conf != 'undefined')
+                       $j.extend(iObj,  this_seq.amw_conf);
                //inherit the remoteSearchDriver properties:n
                var tmpRSD = new remoteSearchDriver( iObj );
                for(var i in tmpRSD){
index 2eecbe2..583c1df 100644 (file)
@@ -97,7 +97,9 @@ var sequencerDefaultValues = {
        sequenceEditToken:null,
        //the time the sequence was last touched (grabbed at time of startup)
        sequenceTouchedTime:null,
-
+       
+       //the default config for the add media wizard
+       amw_conf: {}, 
 
 
        //Msg are all the language specific values ...
index cc9320c..ddeffd0 100644 (file)
@@ -23,21 +23,19 @@ if( MV_EMBED_VERSION ){
 var MV_EMBED_VERSION = '1.0r19';
 
 /*
- * Configuration variables (can be set from some preceding script).
- * Set up mwConfig global, override any of the defaultMwConfig values:
- * @@ more config values on the way ;)
+ * Configuration variables should be set by extending mwConfigOptions
+ * here is the default config: 
  */
-var defaultMwConfig = {
+var mwConfig = {
        'skin_name': 'mvpcf',
        'jui_skin': 'redmond',
        'video_size':'400x300'
 }
 
-if( !mwConfig )
-       var mwConfig = {};
+if( !mwConfigOptions )
+       var mwConfigOptions = {};
 
 // Install the default config values for anything not set in mwConfig
-checkDefaultMwConfig();
 
 // Whether or not to load java from an iframe.
 // Note: this is necessary for remote embedding because of Java's security model)
@@ -85,19 +83,11 @@ parseUri.options = {
        }
 };
 
-
-
 // Get the mv_embed location if it has not been set
 if( !mv_embed_path ) {
        var mv_embed_path = getMvEmbedPath();
 }
 
-// Set up the skin path
-var mv_jquery_skin_path = mv_embed_path + 'jquery/jquery.ui/themes/' +mwConfig['jui_skin'] + '/';
-var mv_skin_img_path = mv_embed_path + 'skins/' + mwConfig['skin_name'] + '/images/';
-var mv_default_thumb_url = mv_skin_img_path + 'vid_default_thumb.jpg';
-
-
 // Init the global message table if it has not been initialised already
 if( !gMsg ) {
        var gMsg = {};
@@ -556,21 +546,35 @@ var mvJsLoader = {
         * checks for jQuery and adds the $j noConflict var
         */
        jQueryCheck: function( callback ) {
-               // Skip stuff if $j is already loaded
+               // Skip stuff if $j is already loaded:
                if( _global['$j'] && callback )
-                       callback();
+                       callback();                                     
                var _this = this;
                // Load jQuery
                _this.doLoad([
                        'window.jQuery'
                ], function() {
                        _global['$j'] = jQuery.noConflict();
+                       
+                       //setup our global settings using the (jQuery helper) 
+                       $j.extend( mwConfig, mwConfigOptions);
+                       
+                       // Set up the skin path
+                       _global['mv_jquery_skin_path'] = mv_embed_path + 'jquery/jquery.ui/themes/' +mwConfig['jui_skin'] + '/';
+                       _global['mv_skin_img_path'] = mv_embed_path + 'skins/' + mwConfig['skin_name'] + '/images/';
+                       _global['mv_default_thumb_url'] = mv_skin_img_path + 'vid_default_thumb.jpg';
+                       
+                       // Make sure the skin/style sheets are always available:
+                       loadExternalCss( mv_jquery_skin_path + 'jquery-ui-1.7.1.custom.css' );
+                       loadExternalCss( mv_embed_path + 'skins/' + mwConfig['skin_name'] + '/styles.css' );
+                       
                        // Set up AJAX to not send dynamic URLs for loading scripts (we control that with
                        // the scriptLoader)
                        $j.ajaxSetup({
                                cache: true
                        });
-                       js_log( 'jquery loaded' );
+                       
+                       js_log( 'jQuery loaded into $j' );
                        // Set up mvEmbed jQuery bindings:
                        mv_jqueryBindings();
                        // Run the callback
@@ -581,15 +585,11 @@ var mvJsLoader = {
        },
        embedVideoCheck:function( callback ) {
                var _this = this;
-               js_log( 'embedVideoCheck:' );
-               // Set videonojs to loading
-               // Issue a style sheet request to get both mv_embed and jQuery styles:
-               loadExternalCss( mv_jquery_skin_path + 'jquery-ui-1.7.1.custom.css' );
-               loadExternalCss( mv_embed_path + 'skins/'+mwConfig['skin_name'] + '/styles.css' );
-
+               js_log( 'embedVideoCheck:' );           
                // Make sure we have jQuery
                _this.jQueryCheck( function() {
                        $j('.videonojs').html( gM('mwe-loading_txt') );
+                       //Set up the embed video player class request: 
                        var depReq = [
                                [
                                        '$j.ui',
@@ -604,7 +604,7 @@ var mvJsLoader = {
                        // Add PNG fix if needed:
                        if( $j.browser.msie || $j.browser.version < 7 )
                                depReq[0].push( '$j.fn.pngFix' );
-
+                       
                        _this.doLoadDepMode( depReq, function() {
                                embedTypes.init();
                                callback();
@@ -685,11 +685,7 @@ function setSwappableToLoading( e ) {
        //}
 }
 //js2AddOnloadHook: ensure jQuery and the DOM are ready
-function js2AddOnloadHook( func ) {
-       // Make sure the skin/style sheets are always available:
-       loadExternalCss( mv_jquery_skin_path + 'jquery-ui-1.7.1.custom.css' );
-       loadExternalCss( mv_embed_path + 'skins/' + mwConfig['skin_name'] + '/styles.css' );
-
+function js2AddOnloadHook( func ) {    
        // If we have already run the DOM-ready function, just run the function directly:
        if( mvJsLoader.doneReadyEvents ) {
                // Make sure jQuery is there:
@@ -1463,14 +1459,6 @@ function js_log( string ) {
        return false;
 }
 
-function checkDefaultMwConfig() {
-       for( var i in defaultMwConfig ) {
-               if( typeof( mwConfig[i] ) == 'undefined' ) {
-                       mwConfig[i] = defaultMwConfig[i];
-               }
-       }
-}
-
 function js_error( string ) {
        alert( string );
        return false;