<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[18766] trunk: Fix wplink when TinyMCE is not loaded, fix image insertion when wpActiveEditor is not set, see #17144</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg > ul, #logmsg > ol { margin-left: 0; margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://core.trac.wordpress.org/changeset/18766">18766</a></dd>
<dt>Author</dt> <dd>azaozz</dd>
<dt>Date</dt> <dd>2011-09-24 04:43:19 +0000 (Sat, 24 Sep 2011)</dd>
</dl>

<h3>Log Message</h3>
<pre>Fix wplink when TinyMCE is not loaded, fix image insertion when wpActiveEditor is not set, see <a href="http://core.trac.wordpress.org/ticket/17144">#17144</a></pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkwpadminjsmediauploaddevjs">trunk/wp-admin/js/media-upload.dev.js</a></li>
<li><a href="#trunkwpadminjsmediauploadjs">trunk/wp-admin/js/media-upload.js</a></li>
<li><a href="#trunkwpincludesclasswpeditorphp">trunk/wp-includes/class-wp-editor.php</a></li>
<li><a href="#trunkwpincludesjsquicktagsdevjs">trunk/wp-includes/js/quicktags.dev.js</a></li>
<li><a href="#trunkwpincludesjsquicktagsjs">trunk/wp-includes/js/quicktags.js</a></li>
<li><a href="#trunkwpincludesjstinymcethemesadvancedskinswp_themecontentcss">trunk/wp-includes/js/tinymce/themes/advanced/skins/wp_theme/content.css</a></li>
<li><a href="#trunkwpincludesscriptloaderphp">trunk/wp-includes/script-loader.php</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkwpadminjsmediauploaddevjs"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/js/media-upload.dev.js (18765 => 18766)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/js/media-upload.dev.js        2011-09-24 04:18:44 UTC (rev 18765)
+++ trunk/wp-admin/js/media-upload.dev.js        2011-09-24 04:43:19 UTC (rev 18766)
</span><span class="lines">@@ -3,18 +3,18 @@
</span><span class="cx"> var wpActiveEditor;
</span><span class="cx"> 
</span><span class="cx"> function send_to_editor(h) {
</span><del>-        var ed;
</del><ins>+        var ed, mce = typeof(tinymce) != 'undefined', qt = typeof(QTags) != 'undefined';
</ins><span class="cx"> 
</span><span class="cx">         if ( !wpActiveEditor ) {
</span><del>-                if ( typeof(tinymce) != 'undefined' &amp;&amp; tinymce.activeEditor ) {
</del><ins>+                if ( mce &amp;&amp; tinymce.activeEditor ) {
</ins><span class="cx">                         ed = tinymce.activeEditor;
</span><span class="cx">                         wpActiveEditor = ed.id;
</span><del>-                } else {
</del><ins>+                } else if ( !qt ) {
</ins><span class="cx">                         return false;
</span><span class="cx">                 }
</span><span class="cx">         } 
</span><span class="cx"> 
</span><del>-        if ( !ed &amp;&amp; typeof(tinymce) != 'undefined' &amp;&amp; wpActiveEditor )
</del><ins>+        if ( !ed &amp;&amp; mce &amp;&amp; wpActiveEditor )
</ins><span class="cx">                 ed = tinymce.get(wpActiveEditor);
</span><span class="cx"> 
</span><span class="cx">         if ( ed &amp;&amp; !ed.isHidden() ) {
</span><span class="lines">@@ -34,13 +34,13 @@
</span><span class="cx">                 }
</span><span class="cx"> 
</span><span class="cx">                 ed.execCommand('mceInsertContent', false, h);
</span><del>-        } else if ( typeof(QTags) != 'undefined' ) {
</del><ins>+        } else if ( qt ) {
</ins><span class="cx">                 QTags.insertContent(h);
</span><span class="cx">         } else {
</span><span class="cx">                 document.getElementById(wpActiveEditor).value += h;
</span><span class="cx">         }
</span><span class="cx"> 
</span><del>-        tb_remove();
</del><ins>+        try{tb_remove();}catch(e){};
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> // thickbox settings
</span></span></pre></div>
<a id="trunkwpadminjsmediauploadjs"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/js/media-upload.js (18765 => 18766)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/js/media-upload.js        2011-09-24 04:18:44 UTC (rev 18765)
+++ trunk/wp-admin/js/media-upload.js        2011-09-24 04:43:19 UTC (rev 18766)
</span><span class="lines">@@ -1 +1 @@
</span><del>-var wpActiveEditor;function send_to_editor(b){var a;if(!wpActiveEditor){if(typeof(tinymce)!=&quot;undefined&quot;&amp;&amp;tinymce.activeEditor){a=tinymce.activeEditor;wpActiveEditor=a.id}else{return false}}if(!a&amp;&amp;typeof(tinymce)!=&quot;undefined&quot;&amp;&amp;wpActiveEditor){a=tinymce.get(wpActiveEditor)}if(a&amp;&amp;!a.isHidden()){if(tinymce.isIE&amp;&amp;a.windowManager.insertimagebookmark){a.selection.moveToBookmark(a.windowManager.insertimagebookmark)}if(b.indexOf(&quot;[caption&quot;)===0){if(a.plugins.wpeditimage){b=a.plugins.wpeditimage._do_shcode(b)}}else{if(b.indexOf(&quot;[gallery&quot;)===0){if(a.plugins.wpgallery){b=a.plugins.wpgallery._do_gallery(b)}}else{if(b.indexOf(&quot;[embed&quot;)===0){if(a.plugins.wordpress){b=a.plugins.wordpress._setEmbed(b)}}}}a.execCommand(&quot;mceInsertContent&quot;,false,b)}else{if(typeof(QTags)!=&quot;undefined&quot;){QTags.insertContent(b)}else{document.getElementById(wpActiveEditor).value+=b}}tb_remove()}v
 ar tb_position;(function(a){tb_position=function(){var f=a(&quot;#TB_window&quot;),e=a(window).width(),d=a(window).height(),c=(720&lt;e)?720:e,b=0;if(a(&quot;body.admin-bar&quot;).length){b=28}if(f.size()){f.width(c-50).height(d-45-b);a(&quot;#TB_iframeContent&quot;).width(c-50).height(d-75-b);f.css({&quot;margin-left&quot;:&quot;-&quot;+parseInt(((c-50)/2),10)+&quot;px&quot;});if(typeof document.body.style.maxWidth!=&quot;undefined&quot;){f.css({top:20+b+&quot;px&quot;,&quot;margin-top&quot;:&quot;0&quot;})}}return a(&quot;a.thickbox&quot;).each(function(){var g=a(this).attr(&quot;href&quot;);if(!g){return}g=g.replace(/&amp;width=[0-9]+/g,&quot;&quot;);g=g.replace(/&amp;height=[0-9]+/g,&quot;&quot;);a(this).attr(&quot;href&quot;,g+&quot;&amp;width=&quot;+(c-80)+&quot;&amp;height=&quot;+(d-85-b))})};a(window).resize(function(){tb_position()});a(document).ready(function(b){b(&quot;a.thickbox&quot;).click(function(){var c;if(typeof(tinymce)!=&quot;undefined&quot;&amp;&amp;tiny
 mce.isIE&amp;&amp;(c=tinymce.get(wpActiveEditor))&amp;&amp;!c.isHidden()){c.focus();c.windowManager.insertimagebookmark=c.selection.getBookmark()}})})})(jQuery);
</del><span class="cx">\ No newline at end of file
</span><ins>+var wpActiveEditor;function send_to_editor(c){var b,a=typeof(tinymce)!=&quot;undefined&quot;,f=typeof(QTags)!=&quot;undefined&quot;;if(!wpActiveEditor){if(a&amp;&amp;tinymce.activeEditor){b=tinymce.activeEditor;wpActiveEditor=b.id}else{if(!f){return false}}}if(!b&amp;&amp;a&amp;&amp;wpActiveEditor){b=tinymce.get(wpActiveEditor)}if(b&amp;&amp;!b.isHidden()){if(tinymce.isIE&amp;&amp;b.windowManager.insertimagebookmark){b.selection.moveToBookmark(b.windowManager.insertimagebookmark)}if(c.indexOf(&quot;[caption&quot;)===0){if(b.plugins.wpeditimage){c=b.plugins.wpeditimage._do_shcode(c)}}else{if(c.indexOf(&quot;[gallery&quot;)===0){if(b.plugins.wpgallery){c=b.plugins.wpgallery._do_gallery(c)}}else{if(c.indexOf(&quot;[embed&quot;)===0){if(b.plugins.wordpress){c=b.plugins.wordpress._setEmbed(c)}}}}b.execCommand(&quot;mceInsertContent&quot;,false,c)}else{if(f){QTags.insertContent(c)}else{document.getElementById(wpActiveEditor).value+=c}}try{tb_remove()}catch(d){}}var tb_
 position;(function(a){tb_position=function(){var f=a(&quot;#TB_window&quot;),e=a(window).width(),d=a(window).height(),c=(720&lt;e)?720:e,b=0;if(a(&quot;body.admin-bar&quot;).length){b=28}if(f.size()){f.width(c-50).height(d-45-b);a(&quot;#TB_iframeContent&quot;).width(c-50).height(d-75-b);f.css({&quot;margin-left&quot;:&quot;-&quot;+parseInt(((c-50)/2),10)+&quot;px&quot;});if(typeof document.body.style.maxWidth!=&quot;undefined&quot;){f.css({top:20+b+&quot;px&quot;,&quot;margin-top&quot;:&quot;0&quot;})}}return a(&quot;a.thickbox&quot;).each(function(){var g=a(this).attr(&quot;href&quot;);if(!g){return}g=g.replace(/&amp;width=[0-9]+/g,&quot;&quot;);g=g.replace(/&amp;height=[0-9]+/g,&quot;&quot;);a(this).attr(&quot;href&quot;,g+&quot;&amp;width=&quot;+(c-80)+&quot;&amp;height=&quot;+(d-85-b))})};a(window).resize(function(){tb_position()});a(document).ready(function(b){b(&quot;a.thickbox&quot;).click(function(){var c;if(typeof(tinymce)!=&quot;undefined&quot;&amp;&amp;tinymce.is
 IE&amp;&amp;(c=tinymce.get(wpActiveEditor))&amp;&amp;!c.isHidden()){c.focus();c.windowManager.insertimagebookmark=c.selection.getBookmark()}})})})(jQuery);
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkwpincludesclasswpeditorphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/class-wp-editor.php (18765 => 18766)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/class-wp-editor.php        2011-09-24 04:18:44 UTC (rev 18765)
+++ trunk/wp-includes/class-wp-editor.php        2011-09-24 04:43:19 UTC (rev 18766)
</span><span class="lines">@@ -1,6 +1,6 @@
</span><span class="cx"> &lt;?php
</span><span class="cx"> /**
</span><del>- * Adds the TinyMCE editor used on the Write and Edit screens.
</del><ins>+ * Adds the WordPress editor used on the Write and Edit screens.
</ins><span class="cx">  *
</span><span class="cx">  * @package WordPress
</span><span class="cx">  * @since 3.3
</span><span class="lines">@@ -16,6 +16,7 @@
</span><span class="cx">         var $mce_settings = array();
</span><span class="cx">         var $qt_settings = array();
</span><span class="cx">         var $plugins = array();
</span><ins>+        var $qt_buttons = array();
</ins><span class="cx">         var $mce_locale;
</span><span class="cx">         var $ext_plugins;
</span><span class="cx">         var $baseurl;
</span><span class="lines">@@ -48,7 +49,7 @@
</span><span class="cx">                         'editor_css' =&gt; '', // intended for extra styles for both visual and HTML editors buttons, needs to include the &lt;style&gt; tags, can use &quot;scoped&quot;.
</span><span class="cx">                         'editor_class' =&gt; '', // add extra class(es) to the editor textarea
</span><span class="cx">                         'teeny' =&gt; false, // output the minimal editor config used in Press This
</span><del>-                        'dfw' =&gt; false, // replace the default fullscreen with DFW (needs specific css)
</del><ins>+                        'dfw' =&gt; false, // replace the default fullscreen with DFW (needs specific DOM elements and css)
</ins><span class="cx">                         'tinymce' =&gt; true, // load TinyMCE, can be used to pass settings directly to TinyMCE using an array()
</span><span class="cx">                         'quicktags' =&gt; true // load Quicktags, can be used to pass settings directly to Quicktags using an array()
</span><span class="cx">                 ) );
</span><span class="lines">@@ -64,7 +65,7 @@
</span><span class="cx">                 if ( !current_user_can( 'upload_files' ) )
</span><span class="cx">                         $set['media_buttons'] = false;
</span><span class="cx"> 
</span><del>-                if ( $this-&gt;can_richedit &amp;&amp; $this-&gt;this_quicktags &amp;&amp; $this-&gt;this_tinymce ) {
</del><ins>+                if ( $this-&gt;this_quicktags &amp;&amp; $this-&gt;this_tinymce ) {
</ins><span class="cx">                         $switch_class = 'html-active';
</span><span class="cx"> 
</span><span class="cx">                         if ( 'html' == $this-&gt;default_editor ) {
</span><span class="lines">@@ -98,7 +99,7 @@
</span><span class="cx">                         echo &quot;&lt;/div&gt;\n&quot;;
</span><span class="cx">                 }
</span><span class="cx"> 
</span><del>-                $the_editor = apply_filters('the_editor', '&lt;div id=&quot;wp-' . $editor_id . '-editor-container&quot; class=&quot;wp-editor-container&quot;&gt;&lt;textarea' . $editor_class . $rows . $tabindex . '&quot; cols=&quot;40&quot; name=&quot;' . $set['textarea_name'] . '&quot; id=&quot;' . $editor_id . '&quot;&gt;%s&lt;/textarea&gt;&lt;/div&gt;');
</del><ins>+                $the_editor = apply_filters('the_editor', '&lt;div id=&quot;wp-' . $editor_id . '-editor-container&quot; class=&quot;wp-editor-container&quot;&gt;&lt;textarea' . $editor_class . $rows . $tabindex . ' cols=&quot;40&quot; name=&quot;' . $set['textarea_name'] . '&quot; id=&quot;' . $editor_id . '&quot;&gt;%s&lt;/textarea&gt;&lt;/div&gt;');
</ins><span class="cx">                 $content = apply_filters('the_editor_content', $content);
</span><span class="cx"> 
</span><span class="cx">                 printf($the_editor, $content);
</span><span class="lines">@@ -114,24 +115,40 @@
</span><span class="cx">                 $this-&gt;editor_settings($editor_id, $set);
</span><span class="cx">         }
</span><span class="cx"> 
</span><del>-        function editor_settings($editor_id, $settings) {
</del><ins>+        function editor_settings($editor_id, $set) {
</ins><span class="cx">                 global $editor_styles;
</span><span class="cx">                 $first_run = false;
</span><span class="cx"> 
</span><span class="cx">                 if ( $this-&gt;this_quicktags ) {
</span><del>-                        $qtbuttons = apply_filters( 'quicktags_buttons', array(), $editor_id );
-                        $qtbuttons_disabled = apply_filters( 'quicktags_disabled_buttons', array(), $editor_id );
</del><ins>+                        $qt_buttons = array();
</ins><span class="cx"> 
</span><span class="cx">                         $qtInit = array(
</span><span class="cx">                                 'id' =&gt; $editor_id,
</span><del>-                                'buttons' =&gt; implode($qtbuttons, ','),
-                                'disabled_buttons' =&gt; implode($qtbuttons_disabled, ',')
</del><ins>+                                'buttons' =&gt; '',
+                                'disabled_buttons' =&gt; ''
</ins><span class="cx">                         );
</span><span class="cx"> 
</span><del>-                        if ( is_array($settings['quicktags']) )
-                                $qtInit = array_merge($qtInit, $settings['quicktags']);
</del><ins>+                        if ( is_array($set['quicktags']) )
+                                $qtInit = array_merge($qtInit, $set['quicktags']);
</ins><span class="cx"> 
</span><ins>+                        $qtInit = apply_filters( 'quicktags_settings', $qtInit, $editor_id );
+
</ins><span class="cx">                         $this-&gt;qt_settings[$editor_id] = $qtInit;
</span><ins>+
+                        if ( !empty($qtInit['buttons']) || !empty($qtInit['disabled_buttons']) ) {
+                                if ( strpos( ',' . $qtInit['buttons'] . ',', ',link,' ) !== false )
+                                        $qt_buttons[] = 'link';
+
+                                if ( strpos( ',' . $qtInit['disabled_buttons'] . ',', ',link,' ) !== false )
+                                        $qt_buttons = array();
+                        } else {
+                                $qt_buttons[] = 'link';
+                        }
+
+                        if ( $set['dfw'] )
+                                $qt_buttons[] = 'fullscreen';
+
+                        $this-&gt;qt_buttons = array_merge( $this-&gt;qt_buttons, $qt_buttons );
</ins><span class="cx">                 }
</span><span class="cx"> 
</span><span class="cx">                 if ( $this-&gt;this_tinymce ) {
</span><span class="lines">@@ -143,7 +160,7 @@
</span><span class="cx">                                 $plugins = array( 'inlinepopups', 'spellchecker', 'tabfocus', 'paste', 'media', 'fullscreen', 'wordpress', 'wpeditimage', 'wpgallery', 'wplink', 'wpdialogs' );
</span><span class="cx">                                 $first_run = true;
</span><span class="cx"> 
</span><del>-                                if ( $settings['teeny'] ) {
</del><ins>+                                if ( $set['teeny'] ) {
</ins><span class="cx">                                         $this-&gt;plugins = $plugins = apply_filters( 'teeny_mce_plugins', array('inlinepopups', 'fullscreen', 'wordpress', 'wplink', 'wpdialogs'), $editor_id );
</span><span class="cx">                                         $ext_plugins = '';
</span><span class="cx">                                 } else {
</span><span class="lines">@@ -192,7 +209,7 @@
</span><span class="cx">                                                         $plugurl = dirname($url);
</span><span class="cx">                                                         $strings = $str1 = $str2 = '';
</span><span class="cx">                                                         if ( ! in_array($name, $loaded_langs) ) {
</span><del>-                                                                $path = str_replace( WP_CONTENT_URL, '', $plugurl );
</del><ins>+                                                                $path = str_replace( content_url(), '', $plugurl );
</ins><span class="cx">                                                                 $path = WP_CONTENT_DIR . $path . '/langs/';
</span><span class="cx"> 
</span><span class="cx">                                                                 if ( function_exists('realpath') )
</span><span class="lines">@@ -230,7 +247,7 @@
</span><span class="cx">                                         $plugins = array_unique( apply_filters('tiny_mce_plugins', $plugins) );
</span><span class="cx">                                 }
</span><span class="cx"> 
</span><del>-                                if ( $settings['dfw'] )
</del><ins>+                                if ( $set['dfw'] )
</ins><span class="cx">                                         $plugins[] = 'wpfullscreen';
</span><span class="cx"> 
</span><span class="cx">                                 $this-&gt;plugins = $plugins;
</span><span class="lines">@@ -325,7 +342,7 @@
</span><span class="cx">                                         $this-&gt;first_init['content_css'] = $mce_css;
</span><span class="cx">                         }
</span><span class="cx"> 
</span><del>-                        if ( $settings['teeny'] ) {
</del><ins>+                        if ( $set['teeny'] ) {
</ins><span class="cx">                                 $mce_buttons = apply_filters( 'teeny_mce_buttons', array('bold', 'italic', 'underline', 'blockquote', 'separator', 'strikethrough', 'bullist', 'numlist', 'justifyleft', 'justifycenter', 'justifyright', 'undo', 'redo', 'link', 'unlink', 'fullscreen'), $editor_id );
</span><span class="cx">                                 $mce_buttons_2 = $mce_buttons_3 = $mce_buttons_4 = array();
</span><span class="cx">                         } else {
</span><span class="lines">@@ -335,7 +352,7 @@
</span><span class="cx">                                 $mce_buttons_4 = apply_filters('mce_buttons_4', array(), $editor_id);
</span><span class="cx">                         }
</span><span class="cx"> 
</span><del>-                        if ( $settings['dfw'] ) {
</del><ins>+                        if ( $set['dfw'] ) {
</ins><span class="cx">                                 function replace_fullscreen(&amp;$val) {
</span><span class="cx">                                         if ( $val == 'fullscreen' )
</span><span class="cx">                                                 $val = 'wp_fullscreen';
</span><span class="lines">@@ -349,9 +366,9 @@
</span><span class="cx"> 
</span><span class="cx">                         $mceInit = array (
</span><span class="cx">                                 'elements' =&gt; $editor_id,
</span><del>-                                'wpautop' =&gt; (bool) $settings['wpautop'],
-                                'remove_linebreaks' =&gt; (bool) $settings['wpautop'],
-                                'apply_source_formatting' =&gt; (bool) !$settings['wpautop'],
</del><ins>+                                'wpautop' =&gt; (bool) $set['wpautop'],
+                                'remove_linebreaks' =&gt; (bool) $set['wpautop'],
+                                'apply_source_formatting' =&gt; (bool) !$set['wpautop'],
</ins><span class="cx">                                 'theme_advanced_buttons1' =&gt; implode($mce_buttons, ','),
</span><span class="cx">                                 'theme_advanced_buttons2' =&gt; implode($mce_buttons_2, ','),
</span><span class="cx">                                 'theme_advanced_buttons3' =&gt; implode($mce_buttons_3, ','),
</span><span class="lines">@@ -361,14 +378,14 @@
</span><span class="cx">                         if ( $first_run )
</span><span class="cx">                                 $mceInit = array_merge($this-&gt;first_init, $mceInit);
</span><span class="cx"> 
</span><del>-                        if ( is_array($settings['tinymce']) )
-                                $mceInit = array_merge($mceInit, $settings['tinymce']);
</del><ins>+                        if ( is_array($set['tinymce']) )
+                                $mceInit = array_merge($mceInit, $set['tinymce']);
</ins><span class="cx"> 
</span><span class="cx">                         // For people who really REALLY know what they're doing with TinyMCE
</span><span class="cx">                         // You can modify initArray to add, remove, change elements of the config before tinyMCE.init
</span><span class="cx">                         // Setting &quot;valid_elements&quot;, &quot;invalid_elements&quot; and &quot;extended_valid_elements&quot; can be done through this filter.
</span><span class="cx">                         // Best is to use the default cleanup by not specifying valid_elements, as TinyMCE contains full set of XHTML 1.0.
</span><del>-                        if ( $settings['teeny'] ) {
</del><ins>+                        if ( $set['teeny'] ) {
</ins><span class="cx">                                 $mceInit = apply_filters('teeny_mce_before_init', $mceInit, $editor_id);
</span><span class="cx">                         } else {
</span><span class="cx">                                 $mceInit = apply_filters('tiny_mce_before_init', $mceInit, $editor_id);
</span><span class="lines">@@ -422,16 +439,22 @@
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="cx">         function enqueue_scripts() {
</span><del>-                wp_enqueue_script('quicktags');
</del><span class="cx">                 wp_enqueue_script('word-count');
</span><del>-                wp_enqueue_script('wplink');
-                wp_enqueue_script('editor');
</del><span class="cx">                 wp_enqueue_style('editor-buttons');
</span><span class="cx"> 
</span><del>-                wp_enqueue_script('wpdialogs-popup');
-                wp_enqueue_style('wp-jquery-ui-dialog');
</del><ins>+                if ( $this-&gt;this_tinymce )
+                        wp_enqueue_script('editor');
</ins><span class="cx"> 
</span><del>-                if ( in_array('wpfullscreen', $this-&gt;plugins, true) )
</del><ins>+                if ( $this-&gt;this_quicktags )
+                        wp_enqueue_script('quicktags');
+
+                if ( in_array('wplink', $this-&gt;plugins, true) || in_array('link', $this-&gt;qt_buttons, true) ) {
+                        wp_enqueue_script('wplink');
+                        wp_enqueue_script('wpdialogs-popup');
+                        wp_enqueue_style('wp-jquery-ui-dialog');
+                }
+
+                if ( in_array('wpfullscreen', $this-&gt;plugins, true) || in_array('fullscreen', $this-&gt;qt_buttons, true) )
</ins><span class="cx">                         wp_enqueue_script('wp-fullscreen');
</span><span class="cx"> 
</span><span class="cx">                 add_thickbox();
</span><span class="lines">@@ -464,9 +487,9 @@
</span><span class="cx">                 if ( $tmce_on ) {
</span><span class="cx">                         foreach ( $this-&gt;mce_settings as $editor_id =&gt; $init ) {
</span><span class="cx">                                 $options = $this-&gt;_parse_init( $init );
</span><del>-                                $mceInit .= &quot;'$editor_id':{$options},\n&quot;;
</del><ins>+                                $mceInit .= &quot;'$editor_id':{$options},&quot;;
</ins><span class="cx">                         }
</span><del>-                        $mceInit = '{' . trim($mceInit, '\n,') . '}';
</del><ins>+                        $mceInit = '{' . trim($mceInit, ',') . '}';
</ins><span class="cx">                 } else {
</span><span class="cx">                         $mceInit = '{}';
</span><span class="cx">                 }
</span><span class="lines">@@ -474,9 +497,9 @@
</span><span class="cx">                 if ( !empty($this-&gt;qt_settings) ) {
</span><span class="cx">                         foreach ( $this-&gt;qt_settings as $editor_id =&gt; $init ) {
</span><span class="cx">                                 $options = $this-&gt;_parse_init( $init );
</span><del>-                                $qtInit .= &quot;'$editor_id':{$options},\n&quot;;
</del><ins>+                                $qtInit .= &quot;'$editor_id':{$options},&quot;;
</ins><span class="cx">                         }
</span><del>-                        $qtInit = '{' . trim($qtInit, '\n,') . '}';
</del><ins>+                        $qtInit = '{' . trim($qtInit, ',') . '}';
</ins><span class="cx">                 } else {
</span><span class="cx">                         $qtInit = '{}';
</span><span class="cx">                 }
</span><span class="lines">@@ -563,10 +586,10 @@
</span><span class="cx">         &lt;/script&gt;
</span><span class="cx"> &lt;?php
</span><span class="cx"> 
</span><del>-                if ( in_array( 'wplink', $this-&gt;plugins, true ) )
</del><ins>+                if ( in_array('wplink', $this-&gt;plugins, true) || in_array('link', $this-&gt;qt_buttons, true) )
</ins><span class="cx">                         $this-&gt;wp_link_dialog();
</span><span class="cx"> 
</span><del>-                if ( in_array( 'wpfullscreen', $this-&gt;plugins, true ) )
</del><ins>+                if ( in_array('wpfullscreen', $this-&gt;plugins, true) || in_array('fullscreen', $this-&gt;qt_buttons, true) )
</ins><span class="cx">                         $this-&gt;wp_fullscreen_html();
</span><span class="cx"> 
</span><span class="cx">                 do_action('after_wp_tiny_mce', $this-&gt;mce_settings);
</span></span></pre></div>
<a id="trunkwpincludesjsquicktagsdevjs"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/js/quicktags.dev.js (18765 => 18766)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/js/quicktags.dev.js        2011-09-24 04:18:44 UTC (rev 18765)
+++ trunk/wp-includes/js/quicktags.dev.js        2011-09-24 04:43:19 UTC (rev 18766)
</span><span class="lines">@@ -26,9 +26,28 @@
</span><span class="cx"> // by Alex King
</span><span class="cx"> // http://www.alexking.org/
</span><span class="cx"> 
</span><del>-var QTags, edButtons = [], edCanvas;
</del><ins>+var QTags, edButtons = [], edCanvas,
</ins><span class="cx"> 
</span><span class="cx"> /**
</span><ins>+ * Back-compat
+ *
+ * Define all former global functions so plugins that hack quicktags.js directly don't cause fatal errors.
+ */
+edAddTag = function(){},
+edCheckOpenTags = function(){},
+edCloseAllTags = function(){},
+edInsertImage = function(){},
+edInsertLink = function(){},
+edInsertTag = function(){},
+edLink = function(){},
+edQuickLink = function(){},
+edRemoveTag = function(){},
+edShowButton = function(){},
+edShowLinks = function(){},
+edSpell = function(){},
+edToolbar = function(){};
+
+/**
</ins><span class="cx">  * Initialize new instance of the Quicktags editor
</span><span class="cx">  */
</span><span class="cx"> function quicktags(settings) {
</span><span class="lines">@@ -55,25 +74,6 @@
</span><span class="cx">         return QTags.addButton( id, display, tagStart, tagEnd, access, '', -1 );        
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-/**
- * Back-compat
- *
- * Define all former global functions so plugins that hack quicktags.js directly don't cause fatal errors.
- */
-var edAddTag = function(){},
-edCheckOpenTags = function(){},
-edCloseAllTags = function(){},
-edInsertImage = function(){},
-edInsertLink = function(){},
-edInsertTag = function(){},
-edLink = function(){},
-edQuickLink = function(){},
-edRemoveTag = function(){},
-edShowButton = function(){},
-edShowLinks = function(){},
-edSpell = function(){},
-edToolbar = function(){};
-
</del><span class="cx"> (function(){
</span><span class="cx">         // private stuff is prefixed with an underscore
</span><span class="cx">         var _domReady = function(func) {
</span></span></pre></div>
<a id="trunkwpincludesjsquicktagsjs"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/js/quicktags.js (18765 => 18766)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/js/quicktags.js        2011-09-24 04:18:44 UTC (rev 18765)
+++ trunk/wp-includes/js/quicktags.js        2011-09-24 04:43:19 UTC (rev 18766)
</span><span class="lines">@@ -1 +1 @@
</span><del>-var QTags,edButtons=[],edCanvas;function quicktags(a){return new QTags(a)}function edInsertContent(b,a){return QTags.insertContent(a)}function edButton(f,e,c,b,a,d){return QTags.addButton(f,e,c,b,a,&quot;&quot;,-1)}var edAddTag=function(){},edCheckOpenTags=function(){},edCloseAllTags=function(){},edInsertImage=function(){},edInsertLink=function(){},edInsertTag=function(){},edLink=function(){},edQuickLink=function(){},edRemoveTag=function(){},edShowButton=function(){},edShowLinks=function(){},edSpell=function(){},edToolbar=function(){};(function(){var c=function(h){var g,f,e;if(typeof jQuery!=&quot;undefined&quot;){jQuery(document).ready(h)}else{g=c;g.funcs=[];g.ready=function(){if(!g.isReady){g.isReady=true;for(f=0;f&lt;g.funcs.length;f++){g.funcs[f]()}}};if(g.isReady){h()}else{g.funcs.push(h)}if(!g.eventAttached){if(document.addEventListener){e=function(){document.removeEventListener(&quot;DOMContentLoaded&quot;,e,false);g.ready()};document.addEventListener(&quo
 t;DOMContentLoaded&quot;,e,false);window.addEventListener(&quot;load&quot;,g.ready,false)}else{if(document.attachEvent){e=function(){if(document.readyState===&quot;complete&quot;){document.detachEvent(&quot;onreadystatechange&quot;,e);g.ready()}};document.attachEvent(&quot;onreadystatechange&quot;,e);window.attachEvent(&quot;onload&quot;,g.ready);(function(){try{document.documentElement.doScroll(&quot;left&quot;)}catch(i){setTimeout(arguments.callee,50);return}g.ready()})()}}g.eventAttached=true}}},a=(function(){var e=new Date(),f;f=function(g){var h=g.toString();if(h.length&lt;2){h=&quot;0&quot;+h}return h};return e.getUTCFullYear()+&quot;-&quot;+f(e.getUTCMonth()+1)+&quot;-&quot;+f(e.getUTCDate())+&quot;T&quot;+f(e.getUTCHours())+&quot;:&quot;+f(e.getUTCMinutes())+&quot;:&quot;+f(e.getUTCSeconds())+&quot;+00:00&quot;})(),b={},d;d=QTags=function(k){if(typeof(k)==&quot;string&quot;){k={id:k}}else{if(typeof(k)!=&quot;object&quot;){return false}}var j=this,l=k.id,i=document.ge
 tElementById(l),h=&quot;qt_&quot;+l,e,g,f;if(!l||!i){return false}j.name=h;j.id=l;j.canvas=i;j.settings=k;if(l==&quot;content&quot;&amp;&amp;typeof(adminpage)==&quot;string&quot;&amp;&amp;(adminpage==&quot;post-new-php&quot;||adminpage==&quot;post-php&quot;)){edCanvas=i;f=&quot;ed_toolbar&quot;}else{f=h+&quot;_toolbar&quot;}e=document.createElement(&quot;div&quot;);e.id=f;e.className=&quot;quicktags-toolbar&quot;;i.parentNode.insertBefore(e,i);j.toolbar=e;g=function(o){o=o||window.event;var n=o.target||o.srcElement,m;if(/\s+ed_button\s+/.test(&quot; &quot;+n.className+&quot; &quot;)){j.canvas=i=document.getElementById(l);m=n.id.replace(h+&quot;_&quot;,&quot;&quot;);if(j.theButtons[m]){j.theButtons[m].callback.call(j.theButtons[m],n,i,j)}}};if(e.addEventListener){e.addEventListener(&quot;click&quot;,g,false)}else{if(e.attachEvent){e.attachEvent(&quot;onclick&quot;,g)}}j.getButton=function(m){return j.theButtons[m]};j.getButtonElement=function(m){return document.getElementById
 (h+&quot;_&quot;+m)};d.instances[l]=j;if(!d.instances[0]){d.instances[0]=d.instances[l];c(function(){d._buttonsInit()})}};d.instances={};d.registerButton=function(f,e){b[f]=e};d.getInstance=function(e){return d.instances[e]};d._buttonsInit=function(){var q=this,p,h,e,j,o,n,m,f,l,k,g;for(f in q.instances){if(f==0){continue}p=q.instances[f];h=p.canvas;e=p.name;j=p.settings;m=&quot;&quot;;o={};n={};for(l in edButtons){if(!edButtons[l]){continue}o[edButtons[l].id]=edButtons[l]}if(f==&quot;content&quot;&amp;&amp;typeof(adminpage)==&quot;string&quot;&amp;&amp;(adminpage==&quot;post-new-php&quot;||adminpage==&quot;post-php&quot;)){o.fullscreen=new d.FullscreenButton()}for(l in q._customButtons){if(!o[l]){o[l]=new q._customButtons[l]()}}if(j.buttons){k=j.buttons.split(&quot;,&quot;);for(l in k){g=k[l];if(o[g]){n[g]=o[g]}}}else{n=o}if(j.disabled_buttons){k=j.disabled_buttons.split(&quot;,&quot;);for(l in k){g=k[l];if(n[g]){delete (n[g])}}}for(l in n){if(!n[l]||!n[l].html){continue}m+
 =n[l].html(e+&quot;_&quot;)}p.toolbar.innerHTML=m;p.theButtons=n}q.buttonsInitDone=true};d.addButton=function(l,j,f,e,i,k,h){var g;if(!l||!j){return}h=h||0;e=e||&quot;&quot;;if(typeof(f)===&quot;function&quot;){g=new d.Button(l,j,i,k);g.callback=f}else{if(typeof(f)===&quot;string&quot;){g=new d.TagButton(l,j,f,e,i,k)}else{return}}if(h==-1){return g}if(h&gt;0){while(typeof(edButtons[h])!=&quot;undefined&quot;){h++}edButtons[h]=g}else{edButtons[edButtons.length]=g}if(this.buttonsInitDone){this._buttonsInit()}};d.insertContent=function(h){var i,g,f,j,k,e=document.getElementById(wpActiveEditor);if(!e){return false}if(document.selection){e.focus();i=document.selection.createRange();i.text=h;e.focus()}else{if(e.selectionStart||e.selectionStart==&quot;0&quot;){k=e.value;g=e.selectionStart;f=e.selectionEnd;j=e.scrollTop;e.value=k.substring(0,g)+h+k.substring(f,k.length);e.focus();e.selectionStart=g+h.length;e.selectionEnd=g+h.length;e.scrollTop=j}else{e.value+=h;e.focus()}}return tr
 ue};d.Button=function(i,g,e,h){var f=this;f.id=i;f.display=g;f.access=e;f.title=h||&quot;&quot;};d.Button.prototype.html=function(f){var e=this.access?' accesskey=&quot;'+this.access+'&quot;':&quot;&quot;;return'&lt;input type=&quot;button&quot; id=&quot;'+f+this.id+'&quot;'+e+' class=&quot;ed_button&quot; title=&quot;'+this.title+'&quot; value=&quot;'+this.display+'&quot; /&gt;'};d.Button.prototype.callback=function(){};d.TagButton=function(k,i,g,f,e,j){var h=this;d.Button.call(h,k,i,e,j);h.tagStart=g;h.tagEnd=f};d.TagButton.prototype=new d.Button();d.TagButton.prototype.openTag=function(h,f){var g=this;if(!f.openTags){f.openTags=[]}if(g.tagEnd){f.openTags.push(g.id);h.value=&quot;/&quot;+h.value}};d.TagButton.prototype.closeTag=function(j,f){var h=this,g=h.isOpen(f);if(g!==false){f.openTags.splice(g,1)}j.value=h.display};d.TagButton.prototype.isOpen=function(e){var h=this,g=0,f=false;if(e.openTags){while(f===false&amp;&amp;g&lt;e.openTags.length){f=e.openTags[g]==h.id?g:fa
 lse;g++}}else{f=false}return f};d.TagButton.prototype.callback=function(p,j,q){var w=this,s,f,n,h,u=j.value,k,e,o,g,m=u?w.tagEnd:&quot;&quot;;if(document.selection){j.focus();g=document.selection.createRange();if(g.text.length&gt;0){if(!w.tagEnd){g.text=g.text+w.tagStart}else{g.text=w.tagStart+g.text+m}}else{if(!w.tagEnd){g.text=w.tagStart}else{if(w.isOpen(q)===false){g.text=w.tagStart;w.openTag(p,q)}else{g.text=m;w.closeTag(p,q)}}}j.focus()}else{if(j.selectionStart||j.selectionStart==&quot;0&quot;){s=j.selectionStart;f=j.selectionEnd;n=f;h=j.scrollTop;k=u.substring(0,s);e=u.substring(f,u.length);o=u.substring(s,f);if(s!=f){if(!w.tagEnd){j.value=k+o+w.tagStart+e;n+=w.tagStart.length}else{j.value=k+w.tagStart+o+m+e;n+=w.tagStart.length+m.length}}else{if(!w.tagEnd){j.value=k+w.tagStart+e;n=s+w.tagStart.length}else{if(w.isOpen(q)===false){j.value=k+w.tagStart+e;w.openTag(p,q);n=s+w.tagStart.length}else{j.value=k+m+e;n=s+m.length;w.closeTag(p,q)}}}j.focus();j.selectionStart=n;j.
 selectionEnd=n;j.scrollTop=h}else{if(!m){j.value+=w.tagStart}else{if(w.isOpen(q)!==false){j.value+=w.tagStart;w.openTag(p,q)}else{j.value+=m;w.closeTag(p,q)}}j.focus()}}};d.SpellButton=function(){d.Button.call(this,&quot;spell&quot;,quicktagsL10n.lookup,&quot;&quot;,quicktagsL10n.dictionaryLookup)};d.SpellButton.prototype=new d.Button();d.SpellButton.prototype.callback=function(i,h,e){var k=&quot;&quot;,j,g,f;if(document.selection){h.focus();j=document.selection.createRange();if(j.text.length&gt;0){k=j.text}}else{if(h.selectionStart||h.selectionStart==&quot;0&quot;){g=h.selectionStart;f=h.selectionEnd;if(g!=f){k=h.value.substring(g,f)}}}if(k===&quot;&quot;){k=prompt(quicktagsL10n.wordLookup,&quot;&quot;)}if(k!==null&amp;&amp;/^\w[\w ]*$/.test(k)){window.open(&quot;http://www.answers.com/&quot;+encodeURIComponent(k))}};d.CloseButton=function(){d.Button.call(this,&quot;close&quot;,quicktagsL10n.closeTags,&quot;&quot;,quicktagsL10n.closeAllOpenTags)};d.CloseButton.prototype=new
  d.Button();d._close=function(j,k,f){var h,g,i=f.openTags;if(i){while(i.length&gt;0){h=f.getButton(i[i.length-1]);g=document.getElementById(f.name+&quot;_&quot;+h.id);h.callback.call(h,g,k,f)}}};d.CloseButton.prototype.callback=d._close;d.closeAllTags=function(f){var e=this.getInstance(f);d._close(&quot;&quot;,e.canvas,e)};d.LinkButton=function(){d.TagButton.call(this,&quot;link&quot;,&quot;link&quot;,&quot;&quot;,&quot;&lt;/a&gt;&quot;,&quot;a&quot;)};d.LinkButton.prototype=new d.TagButton();d.LinkButton.prototype.callback=function(j,k,h,g){var f,i=this;if(typeof(wpLink)!=&quot;undefined&quot;){wpLink.open();return}if(!g){g=&quot;http://&quot;}if(i.isOpen(h)===false){f=prompt(quicktagsL10n.enterURL,g);if(f){i.tagStart='&lt;a href=&quot;'+f+'&quot;&gt;';d.TagButton.prototype.callback.call(i,j,k,h)}}else{d.TagButton.prototype.callback.call(i,j,k,h)}};d.ImgButton=function(){d.TagButton.call(this,&quot;img&quot;,&quot;img&quot;,&quot;&quot;,&quot;&quot;,&quot;m&quot;)};d.ImgBut
 ton.prototype=new d.TagButton();d.ImgButton.prototype.callback=function(i,k,g,f){if(!f){f=&quot;http://&quot;}var j=prompt(quicktagsL10n.enterImageURL,f),h;if(j){h=prompt(quicktagsL10n.enterImageDescription,&quot;&quot;);this.tagStart='&lt;img src=&quot;'+j+'&quot; alt=&quot;'+h+'&quot; /&gt;';d.TagButton.prototype.callback.call(this,i,k,g)}};d.FullscreenButton=function(){d.Button.call(this,&quot;fullscreen&quot;,quicktagsL10n.fullscreen,&quot;f&quot;,quicktagsL10n.toggleFullscreen)};d.FullscreenButton.prototype=new d.Button();d.FullscreenButton.prototype.callback=function(f,g){if(g.id!=&quot;content&quot;||typeof(fullscreen)==&quot;undefined&quot;){return}fullscreen.on()};edButtons[10]=new d.TagButton(&quot;strong&quot;,&quot;b&quot;,&quot;&lt;strong&gt;&quot;,&quot;&lt;/strong&gt;&quot;,&quot;b&quot;);edButtons[20]=new d.TagButton(&quot;em&quot;,&quot;i&quot;,&quot;&lt;em&gt;&quot;,&quot;&lt;/em&gt;&quot;,&quot;i&quot;),edButtons[30]=new d.LinkButton(),edButtons[40]=new d.
 TagButton(&quot;block&quot;,&quot;b-quote&quot;,&quot;\n\n&lt;blockquote&gt;&quot;,&quot;&lt;/blockquote&gt;\n\n&quot;,&quot;q&quot;),edButtons[50]=new d.TagButton(&quot;del&quot;,&quot;del&quot;,'&lt;del datetime=&quot;'+a+'&quot;&gt;',&quot;&lt;/del&gt;&quot;,&quot;d&quot;),edButtons[60]=new d.TagButton(&quot;ins&quot;,&quot;ins&quot;,'&lt;ins datetime=&quot;'+a+'&quot;&gt;',&quot;&lt;/ins&gt;&quot;,&quot;s&quot;),edButtons[70]=new d.ImgButton(),edButtons[80]=new d.TagButton(&quot;ul&quot;,&quot;ul&quot;,&quot;&lt;ul&gt;\n&quot;,&quot;&lt;/ul&gt;\n\n&quot;,&quot;u&quot;),edButtons[90]=new d.TagButton(&quot;ol&quot;,&quot;ol&quot;,&quot;&lt;ol&gt;\n&quot;,&quot;&lt;/ol&gt;\n\n&quot;,&quot;o&quot;),edButtons[100]=new d.TagButton(&quot;li&quot;,&quot;li&quot;,&quot;\t&lt;li&gt;&quot;,&quot;&lt;/li&gt;\n&quot;,&quot;l&quot;),edButtons[110]=new d.TagButton(&quot;code&quot;,&quot;code&quot;,&quot;&lt;code&gt;&quot;,&quot;&lt;/code&gt;&quot;,&quot;c&quot;),edButtons[120]=new d.Ta
 gButton(&quot;more&quot;,&quot;more&quot;,&quot;&lt;!--more--&gt;&quot;,&quot;&quot;,&quot;t&quot;),edButtons[130]=new d.SpellButton(),edButtons[140]=new d.CloseButton()})();
</del><span class="cx">\ No newline at end of file
</span><ins>+var QTags,edButtons=[],edCanvas,edAddTag=function(){},edCheckOpenTags=function(){},edCloseAllTags=function(){},edInsertImage=function(){},edInsertLink=function(){},edInsertTag=function(){},edLink=function(){},edQuickLink=function(){},edRemoveTag=function(){},edShowButton=function(){},edShowLinks=function(){},edSpell=function(){},edToolbar=function(){};function quicktags(a){return new QTags(a)}function edInsertContent(b,a){return QTags.insertContent(a)}function edButton(f,e,c,b,a,d){return QTags.addButton(f,e,c,b,a,&quot;&quot;,-1)}(function(){var c=function(h){var g,f,e;if(typeof jQuery!=&quot;undefined&quot;){jQuery(document).ready(h)}else{g=c;g.funcs=[];g.ready=function(){if(!g.isReady){g.isReady=true;for(f=0;f&lt;g.funcs.length;f++){g.funcs[f]()}}};if(g.isReady){h()}else{g.funcs.push(h)}if(!g.eventAttached){if(document.addEventListener){e=function(){document.removeEventListener(&quot;DOMContentLoaded&quot;,e,false);g.ready()};document.addEventListener(&quot;DO
 MContentLoaded&quot;,e,false);window.addEventListener(&quot;load&quot;,g.ready,false)}else{if(document.attachEvent){e=function(){if(document.readyState===&quot;complete&quot;){document.detachEvent(&quot;onreadystatechange&quot;,e);g.ready()}};document.attachEvent(&quot;onreadystatechange&quot;,e);window.attachEvent(&quot;onload&quot;,g.ready);(function(){try{document.documentElement.doScroll(&quot;left&quot;)}catch(i){setTimeout(arguments.callee,50);return}g.ready()})()}}g.eventAttached=true}}},a=(function(){var e=new Date(),f;f=function(g){var h=g.toString();if(h.length&lt;2){h=&quot;0&quot;+h}return h};return e.getUTCFullYear()+&quot;-&quot;+f(e.getUTCMonth()+1)+&quot;-&quot;+f(e.getUTCDate())+&quot;T&quot;+f(e.getUTCHours())+&quot;:&quot;+f(e.getUTCMinutes())+&quot;:&quot;+f(e.getUTCSeconds())+&quot;+00:00&quot;})(),b={},d;d=QTags=function(k){if(typeof(k)==&quot;string&quot;){k={id:k}}else{if(typeof(k)!=&quot;object&quot;){return false}}var j=this,l=k.id,i=document.getEle
 mentById(l),h=&quot;qt_&quot;+l,e,g,f;if(!l||!i){return false}j.name=h;j.id=l;j.canvas=i;j.settings=k;if(l==&quot;content&quot;&amp;&amp;typeof(adminpage)==&quot;string&quot;&amp;&amp;(adminpage==&quot;post-new-php&quot;||adminpage==&quot;post-php&quot;)){edCanvas=i;f=&quot;ed_toolbar&quot;}else{f=h+&quot;_toolbar&quot;}e=document.createElement(&quot;div&quot;);e.id=f;e.className=&quot;quicktags-toolbar&quot;;i.parentNode.insertBefore(e,i);j.toolbar=e;g=function(o){o=o||window.event;var n=o.target||o.srcElement,m;if(/\s+ed_button\s+/.test(&quot; &quot;+n.className+&quot; &quot;)){j.canvas=i=document.getElementById(l);m=n.id.replace(h+&quot;_&quot;,&quot;&quot;);if(j.theButtons[m]){j.theButtons[m].callback.call(j.theButtons[m],n,i,j)}}};if(e.addEventListener){e.addEventListener(&quot;click&quot;,g,false)}else{if(e.attachEvent){e.attachEvent(&quot;onclick&quot;,g)}}j.getButton=function(m){return j.theButtons[m]};j.getButtonElement=function(m){return document.getElementById(h+&
 quot;_&quot;+m)};d.instances[l]=j;if(!d.instances[0]){d.instances[0]=d.instances[l];c(function(){d._buttonsInit()})}};d.instances={};d.registerButton=function(f,e){b[f]=e};d.getInstance=function(e){return d.instances[e]};d._buttonsInit=function(){var q=this,p,h,e,j,o,n,m,f,l,k,g;for(f in q.instances){if(f==0){continue}p=q.instances[f];h=p.canvas;e=p.name;j=p.settings;m=&quot;&quot;;o={};n={};for(l in edButtons){if(!edButtons[l]){continue}o[edButtons[l].id]=edButtons[l]}if(f==&quot;content&quot;&amp;&amp;typeof(adminpage)==&quot;string&quot;&amp;&amp;(adminpage==&quot;post-new-php&quot;||adminpage==&quot;post-php&quot;)){o.fullscreen=new d.FullscreenButton()}for(l in q._customButtons){if(!o[l]){o[l]=new q._customButtons[l]()}}if(j.buttons){k=j.buttons.split(&quot;,&quot;);for(l in k){g=k[l];if(o[g]){n[g]=o[g]}}}else{n=o}if(j.disabled_buttons){k=j.disabled_buttons.split(&quot;,&quot;);for(l in k){g=k[l];if(n[g]){delete (n[g])}}}for(l in n){if(!n[l]||!n[l].html){continue}m+=n[l
 ].html(e+&quot;_&quot;)}p.toolbar.innerHTML=m;p.theButtons=n}q.buttonsInitDone=true};d.addButton=function(l,j,f,e,i,k,h){var g;if(!l||!j){return}h=h||0;e=e||&quot;&quot;;if(typeof(f)===&quot;function&quot;){g=new d.Button(l,j,i,k);g.callback=f}else{if(typeof(f)===&quot;string&quot;){g=new d.TagButton(l,j,f,e,i,k)}else{return}}if(h==-1){return g}if(h&gt;0){while(typeof(edButtons[h])!=&quot;undefined&quot;){h++}edButtons[h]=g}else{edButtons[edButtons.length]=g}if(this.buttonsInitDone){this._buttonsInit()}};d.insertContent=function(h){var i,g,f,j,k,e=document.getElementById(wpActiveEditor);if(!e){return false}if(document.selection){e.focus();i=document.selection.createRange();i.text=h;e.focus()}else{if(e.selectionStart||e.selectionStart==&quot;0&quot;){k=e.value;g=e.selectionStart;f=e.selectionEnd;j=e.scrollTop;e.value=k.substring(0,g)+h+k.substring(f,k.length);e.focus();e.selectionStart=g+h.length;e.selectionEnd=g+h.length;e.scrollTop=j}else{e.value+=h;e.focus()}}return true};
 d.Button=function(i,g,e,h){var f=this;f.id=i;f.display=g;f.access=e;f.title=h||&quot;&quot;};d.Button.prototype.html=function(f){var e=this.access?' accesskey=&quot;'+this.access+'&quot;':&quot;&quot;;return'&lt;input type=&quot;button&quot; id=&quot;'+f+this.id+'&quot;'+e+' class=&quot;ed_button&quot; title=&quot;'+this.title+'&quot; value=&quot;'+this.display+'&quot; /&gt;'};d.Button.prototype.callback=function(){};d.TagButton=function(k,i,g,f,e,j){var h=this;d.Button.call(h,k,i,e,j);h.tagStart=g;h.tagEnd=f};d.TagButton.prototype=new d.Button();d.TagButton.prototype.openTag=function(h,f){var g=this;if(!f.openTags){f.openTags=[]}if(g.tagEnd){f.openTags.push(g.id);h.value=&quot;/&quot;+h.value}};d.TagButton.prototype.closeTag=function(j,f){var h=this,g=h.isOpen(f);if(g!==false){f.openTags.splice(g,1)}j.value=h.display};d.TagButton.prototype.isOpen=function(e){var h=this,g=0,f=false;if(e.openTags){while(f===false&amp;&amp;g&lt;e.openTags.length){f=e.openTags[g]==h.id?g:false;
 g++}}else{f=false}return f};d.TagButton.prototype.callback=function(p,j,q){var w=this,s,f,n,h,u=j.value,k,e,o,g,m=u?w.tagEnd:&quot;&quot;;if(document.selection){j.focus();g=document.selection.createRange();if(g.text.length&gt;0){if(!w.tagEnd){g.text=g.text+w.tagStart}else{g.text=w.tagStart+g.text+m}}else{if(!w.tagEnd){g.text=w.tagStart}else{if(w.isOpen(q)===false){g.text=w.tagStart;w.openTag(p,q)}else{g.text=m;w.closeTag(p,q)}}}j.focus()}else{if(j.selectionStart||j.selectionStart==&quot;0&quot;){s=j.selectionStart;f=j.selectionEnd;n=f;h=j.scrollTop;k=u.substring(0,s);e=u.substring(f,u.length);o=u.substring(s,f);if(s!=f){if(!w.tagEnd){j.value=k+o+w.tagStart+e;n+=w.tagStart.length}else{j.value=k+w.tagStart+o+m+e;n+=w.tagStart.length+m.length}}else{if(!w.tagEnd){j.value=k+w.tagStart+e;n=s+w.tagStart.length}else{if(w.isOpen(q)===false){j.value=k+w.tagStart+e;w.openTag(p,q);n=s+w.tagStart.length}else{j.value=k+m+e;n=s+m.length;w.closeTag(p,q)}}}j.focus();j.selectionStart=n;j.sele
 ctionEnd=n;j.scrollTop=h}else{if(!m){j.value+=w.tagStart}else{if(w.isOpen(q)!==false){j.value+=w.tagStart;w.openTag(p,q)}else{j.value+=m;w.closeTag(p,q)}}j.focus()}}};d.SpellButton=function(){d.Button.call(this,&quot;spell&quot;,quicktagsL10n.lookup,&quot;&quot;,quicktagsL10n.dictionaryLookup)};d.SpellButton.prototype=new d.Button();d.SpellButton.prototype.callback=function(i,h,e){var k=&quot;&quot;,j,g,f;if(document.selection){h.focus();j=document.selection.createRange();if(j.text.length&gt;0){k=j.text}}else{if(h.selectionStart||h.selectionStart==&quot;0&quot;){g=h.selectionStart;f=h.selectionEnd;if(g!=f){k=h.value.substring(g,f)}}}if(k===&quot;&quot;){k=prompt(quicktagsL10n.wordLookup,&quot;&quot;)}if(k!==null&amp;&amp;/^\w[\w ]*$/.test(k)){window.open(&quot;http://www.answers.com/&quot;+encodeURIComponent(k))}};d.CloseButton=function(){d.Button.call(this,&quot;close&quot;,quicktagsL10n.closeTags,&quot;&quot;,quicktagsL10n.closeAllOpenTags)};d.CloseButton.prototype=new d.B
 utton();d._close=function(j,k,f){var h,g,i=f.openTags;if(i){while(i.length&gt;0){h=f.getButton(i[i.length-1]);g=document.getElementById(f.name+&quot;_&quot;+h.id);h.callback.call(h,g,k,f)}}};d.CloseButton.prototype.callback=d._close;d.closeAllTags=function(f){var e=this.getInstance(f);d._close(&quot;&quot;,e.canvas,e)};d.LinkButton=function(){d.TagButton.call(this,&quot;link&quot;,&quot;link&quot;,&quot;&quot;,&quot;&lt;/a&gt;&quot;,&quot;a&quot;)};d.LinkButton.prototype=new d.TagButton();d.LinkButton.prototype.callback=function(j,k,h,g){var f,i=this;if(typeof(wpLink)!=&quot;undefined&quot;){wpLink.open();return}if(!g){g=&quot;http://&quot;}if(i.isOpen(h)===false){f=prompt(quicktagsL10n.enterURL,g);if(f){i.tagStart='&lt;a href=&quot;'+f+'&quot;&gt;';d.TagButton.prototype.callback.call(i,j,k,h)}}else{d.TagButton.prototype.callback.call(i,j,k,h)}};d.ImgButton=function(){d.TagButton.call(this,&quot;img&quot;,&quot;img&quot;,&quot;&quot;,&quot;&quot;,&quot;m&quot;)};d.ImgButton.
 prototype=new d.TagButton();d.ImgButton.prototype.callback=function(i,k,g,f){if(!f){f=&quot;http://&quot;}var j=prompt(quicktagsL10n.enterImageURL,f),h;if(j){h=prompt(quicktagsL10n.enterImageDescription,&quot;&quot;);this.tagStart='&lt;img src=&quot;'+j+'&quot; alt=&quot;'+h+'&quot; /&gt;';d.TagButton.prototype.callback.call(this,i,k,g)}};d.FullscreenButton=function(){d.Button.call(this,&quot;fullscreen&quot;,quicktagsL10n.fullscreen,&quot;f&quot;,quicktagsL10n.toggleFullscreen)};d.FullscreenButton.prototype=new d.Button();d.FullscreenButton.prototype.callback=function(f,g){if(g.id!=&quot;content&quot;||typeof(fullscreen)==&quot;undefined&quot;){return}fullscreen.on()};edButtons[10]=new d.TagButton(&quot;strong&quot;,&quot;b&quot;,&quot;&lt;strong&gt;&quot;,&quot;&lt;/strong&gt;&quot;,&quot;b&quot;);edButtons[20]=new d.TagButton(&quot;em&quot;,&quot;i&quot;,&quot;&lt;em&gt;&quot;,&quot;&lt;/em&gt;&quot;,&quot;i&quot;),edButtons[30]=new d.LinkButton(),edButtons[40]=new d.TagB
 utton(&quot;block&quot;,&quot;b-quote&quot;,&quot;\n\n&lt;blockquote&gt;&quot;,&quot;&lt;/blockquote&gt;\n\n&quot;,&quot;q&quot;),edButtons[50]=new d.TagButton(&quot;del&quot;,&quot;del&quot;,'&lt;del datetime=&quot;'+a+'&quot;&gt;',&quot;&lt;/del&gt;&quot;,&quot;d&quot;),edButtons[60]=new d.TagButton(&quot;ins&quot;,&quot;ins&quot;,'&lt;ins datetime=&quot;'+a+'&quot;&gt;',&quot;&lt;/ins&gt;&quot;,&quot;s&quot;),edButtons[70]=new d.ImgButton(),edButtons[80]=new d.TagButton(&quot;ul&quot;,&quot;ul&quot;,&quot;&lt;ul&gt;\n&quot;,&quot;&lt;/ul&gt;\n\n&quot;,&quot;u&quot;),edButtons[90]=new d.TagButton(&quot;ol&quot;,&quot;ol&quot;,&quot;&lt;ol&gt;\n&quot;,&quot;&lt;/ol&gt;\n\n&quot;,&quot;o&quot;),edButtons[100]=new d.TagButton(&quot;li&quot;,&quot;li&quot;,&quot;\t&lt;li&gt;&quot;,&quot;&lt;/li&gt;\n&quot;,&quot;l&quot;),edButtons[110]=new d.TagButton(&quot;code&quot;,&quot;code&quot;,&quot;&lt;code&gt;&quot;,&quot;&lt;/code&gt;&quot;,&quot;c&quot;),edButtons[120]=new d.TagBut
 ton(&quot;more&quot;,&quot;more&quot;,&quot;&lt;!--more--&gt;&quot;,&quot;&quot;,&quot;t&quot;),edButtons[130]=new d.SpellButton(),edButtons[140]=new d.CloseButton()})();
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkwpincludesjstinymcethemesadvancedskinswp_themecontentcss"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/js/tinymce/themes/advanced/skins/wp_theme/content.css (18765 => 18766)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/js/tinymce/themes/advanced/skins/wp_theme/content.css        2011-09-24 04:18:44 UTC (rev 18765)
+++ trunk/wp-includes/js/tinymce/themes/advanced/skins/wp_theme/content.css        2011-09-24 04:43:19 UTC (rev 18766)
</span><span class="lines">@@ -62,9 +62,7 @@
</span><span class="cx">         text-align: center;
</span><span class="cx">         background-color: #f3f3f3;
</span><span class="cx">         padding-top: 4px;
</span><del>-        margin: 10px;
-        -moz-border-radius: 3px;
-        -khtml-border-radius: 3px;
</del><ins>+        margin: 10px 0;
</ins><span class="cx">         -webkit-border-radius: 3px;
</span><span class="cx">         border-radius: 3px;
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkwpincludesscriptloaderphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/script-loader.php (18765 => 18766)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/script-loader.php        2011-09-24 04:18:44 UTC (rev 18765)
+++ trunk/wp-includes/script-loader.php        2011-09-24 04:43:19 UTC (rev 18766)
</span><span class="lines">@@ -276,7 +276,7 @@
</span><span class="cx"> 
</span><span class="cx">         $scripts-&gt;add( 'word-count', &quot;/wp-admin/js/word-count$suffix.js&quot;, array( 'jquery' ), '20110515', 1 );
</span><span class="cx"> 
</span><del>-        $scripts-&gt;add( 'media-upload', &quot;/wp-admin/js/media-upload$suffix.js&quot;, array( 'thickbox' ), '20110805', 1 );
</del><ins>+        $scripts-&gt;add( 'media-upload', &quot;/wp-admin/js/media-upload$suffix.js&quot;, array( 'thickbox' ), '20110922', 1 );
</ins><span class="cx"> 
</span><span class="cx">         if ( is_admin() ) {
</span><span class="cx">                 $scripts-&gt;add( 'ajaxcat', &quot;/wp-admin/js/cat$suffix.js&quot;, array( 'wp-lists' ), '20090102' );
</span></span></pre>
</div>
</div>

</body>
</html>