diff --git a/wp-includes/js/tinymce/plugins/autosave/editor_plugin.js b/wp-includes/js/tinymce/plugins/autosave/editor_plugin.js index ab0e3ad4df..9d9533e154 100644 --- a/wp-includes/js/tinymce/plugins/autosave/editor_plugin.js +++ b/wp-includes/js/tinymce/plugins/autosave/editor_plugin.js @@ -1,8 +1,8 @@ /** - * $Id: editor_plugin_src.js 126 2006-10-22 16:19:55Z spocke $ + * $Id: editor_plugin_src.js 162 2007-01-03 16:16:52Z spocke $ * * @author Moxiecode - * @copyright Copyright © 2004-2006, Moxiecode Systems AB, All rights reserved. + * @copyright Copyright © 2004-2007, Moxiecode Systems AB, All rights reserved. */ /* Import plugin specific language pack */ diff --git a/wp-includes/js/tinymce/plugins/directionality/editor_plugin.js b/wp-includes/js/tinymce/plugins/directionality/editor_plugin.js index 51eea48d93..c385116e87 100644 --- a/wp-includes/js/tinymce/plugins/directionality/editor_plugin.js +++ b/wp-includes/js/tinymce/plugins/directionality/editor_plugin.js @@ -1,8 +1,8 @@ /** - * $Id: editor_plugin_src.js 126 2006-10-22 16:19:55Z spocke $ + * $Id: editor_plugin_src.js 162 2007-01-03 16:16:52Z spocke $ * * @author Moxiecode - * @copyright Copyright © 2004-2006, Moxiecode Systems AB, All rights reserved. + * @copyright Copyright © 2004-2007, Moxiecode Systems AB, All rights reserved. */ /* Import plugin specific language pack */ diff --git a/wp-includes/js/tinymce/plugins/inlinepopups/editor_plugin.js b/wp-includes/js/tinymce/plugins/inlinepopups/editor_plugin.js index 782d0c7d18..2ecb0482b9 100644 --- a/wp-includes/js/tinymce/plugins/inlinepopups/editor_plugin.js +++ b/wp-includes/js/tinymce/plugins/inlinepopups/editor_plugin.js @@ -1,10 +1,10 @@ /** - * $Id: editor_plugin_src.js 126 2006-10-22 16:19:55Z spocke $ + * $Id: editor_plugin_src.js 172 2007-01-09 11:37:11Z spocke $ * * Moxiecode DHTML Windows script. * * @author Moxiecode - * @copyright Copyright © 2004-2006, Moxiecode Systems AB, All rights reserved. + * @copyright Copyright © 2004-2007, Moxiecode Systems AB, All rights reserved. */ // Patch openWindow, closeWindow TinyMCE functions @@ -66,13 +66,17 @@ TinyMCE_Engine.prototype.openWindow = function(template, args) { } var elm = document.getElementById(this.selectedInstance.editorId + '_parent'); - var pos = tinyMCE.getAbsPosition(elm); + + if (tinyMCE.hasPlugin('fullscreen') && this.selectedInstance.getData('fullscreen').enabled) + pos = { absLeft: 0, absTop: 0 }; + else + pos = tinyMCE.getAbsPosition(elm); // Center div in editor area pos.absLeft += Math.round((elm.firstChild.clientWidth / 2) - (width / 2)); pos.absTop += Math.round((elm.firstChild.clientHeight / 2) - (height / 2)); - url += tinyMCE.settings['imp_version'] ? (url.indexOf('?')==-1?'?':'&') + 'ver=' + tinyMCE.settings['imp_version'] : ''; + url += tinyMCE.settings['imp_version'] ? (url.indexOf('?')==-1?'?':'&') + 'ver=' + tinyMCE.settings['imp_version'] : ''; // WordPress cache buster mcWindows.open(url, mcWindows.idCounter++, "modal=yes,width=" + width+ ",height=" + height + ",resizable=" + resizable + ",scrollbars=" + scrollbars + ",statusbar=" + resizable + ",left=" + pos.absLeft + ",top=" + pos.absTop); }; @@ -111,7 +115,7 @@ function TinyMCE_Windows() { this.action = "none"; this.selectedWindow = null; this.lastSelectedWindow = null; - this.zindex = 100; + this.zindex = 1001; this.mouseDownScreenX = 0; this.mouseDownScreenY = 0; this.mouseDownLayerX = 0; @@ -323,8 +327,9 @@ TinyMCE_Windows.prototype.open = function(url, name, features) { // Blocks the document events by placing a image over the whole document TinyMCE_Windows.prototype.setDocumentLock = function(state) { + var elm = document.getElementById('mcWindowEventBlocker'); + if (state) { - var elm = document.getElementById('mcWindowEventBlocker'); if (elm == null) { elm = document.createElement("div"); @@ -348,9 +353,7 @@ TinyMCE_Windows.prototype.setDocumentLock = function(state) { elm.style.zIndex = mcWindows.zindex-1; elm.style.display = "block"; - } else { - var elm = document.getElementById('mcWindowEventBlocker'); - + } else if (elm != null) { if (mcWindows.windows.length == 0) elm.parentNode.removeChild(elm); else @@ -559,7 +562,7 @@ TinyMCE_Window.prototype.close = function() { mcWindows.setDocumentLock(false); - tinyMCE.selectedInstance.getWin().focus(); + tinyMCE.selectedInstance.getWin().focus(); // WordPress: focus on the editor after closing a popup }; TinyMCE_Window.prototype.onMouseMove = function(e) { @@ -578,23 +581,22 @@ TinyMCE_Window.prototype.onMouseMove = function(e) { width = width < 100 ? 100 : width; height = height < 100 ? 100 : height; - this.wrapperIFrameElement.style.width = width+2; - this.wrapperIFrameElement.style.height = height+2; + this.wrapperIFrameElement.style.width = (width+2) + 'px'; + this.wrapperIFrameElement.style.height = (height+2) + 'px'; this.wrapperIFrameElement.width = width+2; this.wrapperIFrameElement.height = height+2; - this.winElement.style.width = width; - this.winElement.style.height = height; + this.winElement.style.width = width + 'px'; + this.winElement.style.height = height + 'px'; height = height - this.deltaHeight; - this.containerElement.style.width = width; - - this.iframeElement.style.width = width; - this.iframeElement.style.height = height; - this.bodyElement.style.width = width; - this.bodyElement.style.height = height; - this.headElement.style.width = width; - //this.statusElement.style.width = width; + this.containerElement.style.width = width + 'px'; + this.iframeElement.style.width = width + 'px'; + this.iframeElement.style.height = height + 'px'; + this.bodyElement.style.width = width + 'px'; + this.bodyElement.style.height = height + 'px'; + this.headElement.style.width = width + 'px'; + //this.statusElement.style.width = width + 'px'; mcWindows.cancelEvent(e); break; diff --git a/wp-includes/js/tinymce/plugins/paste/editor_plugin.js b/wp-includes/js/tinymce/plugins/paste/editor_plugin.js index 1306c0bd7d..3ef1d7a40b 100644 --- a/wp-includes/js/tinymce/plugins/paste/editor_plugin.js +++ b/wp-includes/js/tinymce/plugins/paste/editor_plugin.js @@ -1,8 +1,8 @@ /** - * $Id: editor_plugin_src.js 126 2006-10-22 16:19:55Z spocke $ + * $Id: editor_plugin_src.js 162 2007-01-03 16:16:52Z spocke $ * * @author Moxiecode - * @copyright Copyright © 2004-2006, Moxiecode Systems AB, All rights reserved. + * @copyright Copyright © 2004-2007, Moxiecode Systems AB, All rights reserved. */ /* Import plugin specific language pack */ diff --git a/wp-includes/js/tinymce/themes/advanced/about.htm b/wp-includes/js/tinymce/themes/advanced/about.htm index 2a86227fbd..bb275f0a9a 100644 --- a/wp-includes/js/tinymce/themes/advanced/about.htm +++ b/wp-includes/js/tinymce/themes/advanced/about.htm @@ -21,7 +21,7 @@
Version: {$tinymce_version} ({$tinymce_releasedate})
TinyMCE is a platform independent web based Javascript HTML WYSIWYG editor control released as Open Source under LGPL by Moxiecode Systems AB. It has the ability to convert HTML TEXTAREA fields or other HTML elements to editor instances.
-Copyright © 2003-2006, Moxiecode Systems AB, All rights reserved.
+Copyright © 2003-2007, Moxiecode Systems AB, All rights reserved.
For more information about this software visit the TinyMCE website.
diff --git a/wp-includes/js/tinymce/themes/advanced/css/editor_ui.css b/wp-includes/js/tinymce/themes/advanced/css/editor_ui.css index e70405db16..58e6b8edaa 100644 --- a/wp-includes/js/tinymce/themes/advanced/css/editor_ui.css +++ b/wp-includes/js/tinymce/themes/advanced/css/editor_ui.css @@ -1,97 +1,97 @@ /* This file contains the CSS data for the editor UI of TinyMCE instances */ -.mceToolbarTop a, .mceToolbarTop a:visited, .mceToolbarTop a:hover, .mceToolbarBottom a, .mceToolbarBottom a:visited, .mceToolbarBottom a:hover {border: 0; margin: 0; padding: 0; background: transparent;} +.mceToolbarTop a, .mceToolbarTop a:visited, .mceToolbarTop a:hover, .mceToolbarBottom a, .mceToolbarBottom a:visited, .mceToolbarBottom a:hover {border: 0; margin: 0; padding: 0; background: transparent;} .mceSeparatorLine {border: 0; padding: 0; margin-left: 4px; margin-right: 2px;} .mceSelectList {font-family: 'MS Sans Serif', sans-serif, Verdana, Arial; font-size: 7pt !important; font-weight: normal; margin-top: 3px; padding: 0; display: inline; vertical-align: top; background-color: #F0F0EE;} .mceLabel, .mceLabelDisabled {font-family: 'MS Sans Serif', sans-serif, Verdana, Arial; font-size: 9pt;} .mceLabel {color: #000000;} -.mceLabelDisabled {cursor: text; color: #999999;} -.mceEditor {background: #F0F0EE; border: 1px solid #cccccc; padding: 0; margin: 0;} -.mceEditorArea { font-family: 'MS Sans Serif', sans-serif, Verdana, Arial; background: #FFFFFF; padding: 0; margin: 0; } -.mceToolbarTop, .mceToolbarBottom {background: #F0F0EE; line-height: 1px; font-size: 1px;} +.mceLabelDisabled {cursor: text; color: #999999;} +.mceEditor {background: #F0F0EE; border: 1px solid #cccccc; padding: 0; margin: 0;} +.mceEditorArea { font-family: 'MS Sans Serif', sans-serif, Verdana, Arial; background: #FFFFFF; padding: 0; margin: 0; } +.mceToolbarTop, .mceToolbarBottom {background: #F0F0EE; line-height: 1px; font-size: 1px;} .mceToolbarTop {border-bottom: 1px solid #cccccc; padding-bottom: 1px;} .mceToolbarBottom {border-top: 1px solid #cccccc;} -.mceToolbarContainer {position: relative; left: 0; top: 0; display: block;} +.mceToolbarContainer {position: relative; left: 0; top: 0; display: block;} .mceStatusbarTop, .mceStatusbarBottom, .mceStatusbar {height: 20px;} -.mceStatusbarTop .mceStatusbarPathText, .mceStatusbarBottom .mceStatusbarPathText, .mceStatusbar .mceStatusbarPathText {font-family: 'MS Sans Serif', sans-serif, Verdana, Arial; font-size: 9pt; padding: 2px; line-height: 16px; overflow: visible;} +.mceStatusbarTop .mceStatusbarPathText, .mceStatusbarBottom .mceStatusbarPathText, .mceStatusbar .mceStatusbarPathText {font-family: 'MS Sans Serif', sans-serif, Verdana, Arial; font-size: 9pt; padding: 2px; line-height: 16px; overflow: visible;} .mceStatusbarTop {border-bottom: 1px solid #cccccc;} .mceStatusbarBottom {border-top: 1px solid #cccccc;} .mceStatusbar {border-bottom: 1px solid #cccccc;} -.mcePathItem, .mcePathItem:link, .mcePathItem:visited, .mcePathItem:hover {text-decoration: none; font-family: 'MS Sans Serif', sans-serif, Verdana, Arial; font-size: 9pt; color: #000000;} +.mcePathItem, .mcePathItem:link, .mcePathItem:visited, .mcePathItem:hover {text-decoration: none; font-family: 'MS Sans Serif', sans-serif, Verdana, Arial; font-size: 9pt; color: #000000;} .mcePathItem:hover {text-decoration: underline;} .mceStatusbarPathText {float: left;} -.mceStatusbarResize {float: right; background-image: url('../images/statusbar_resize.gif'); background-repeat: no-repeat; width: 11px; height: 20px; cursor: se-resize;} -.mceResizeBox {width: 10px; height: 10px; display: none; border: 1px dotted gray; margin: 0; padding: 0;} +.mceStatusbarResize {float: right; background-image: url('../images/statusbar_resize.gif'); background-repeat: no-repeat; width: 11px; height: 20px; cursor: se-resize;} +.mceResizeBox {width: 10px; height: 10px; display: none; border: 1px dotted gray; margin: 0; padding: 0;} .mceEditorIframe {border: 0;} /* Button CSS rules */ -a.mceButtonDisabled img, a.mceButtonNormal img, a.mceButtonSelected img {width: 20px; height: 20px; cursor: default; margin-top: 1px; margin-left: 1px;} +a.mceButtonDisabled img, a.mceButtonNormal img, a.mceButtonSelected img {width: 20px; height: 20px; cursor: default; margin-top: 1px; margin-left: 1px;} a.mceButtonDisabled img {border: 0 !important;} a.mceButtonNormal img, a.mceButtonSelected img {border: 1px solid #F0F0EE !important;} -a.mceButtonSelected img {border: 1px solid #6779AA !important; background-color: #D4D5D8;} -a.mceButtonNormal img:hover, a.mceButtonSelected img:hover {border: 1px solid #0A246A !important; cursor: default; background-color: #B6BDD2;} -a.mceButtonDisabled img {-moz-opacity:0.3; opacity: 0.3; border: 1px solid #F0F0EE !important; cursor: default;} -a.mceTiledButton img {background-image: url('../images/buttons.gif'); background-repeat: no-repeat;} +a.mceButtonSelected img {border: 1px solid #6779AA !important; background-color: #D4D5D8;} +a.mceButtonNormal img:hover, a.mceButtonSelected img:hover {border: 1px solid #0A246A !important; cursor: default; background-color: #B6BDD2;} +a.mceButtonDisabled img {-moz-opacity:0.3; opacity: 0.3; border: 1px solid #F0F0EE !important; cursor: default;} +a.mceTiledButton img {background-image: url('../images/buttons.gif'); background-repeat: no-repeat;} /* Menu button CSS rules */ -span.mceMenuButton img, span.mceMenuButtonSelected img {border: 1px solid #F0F0EE; margin-left: 1px;} -span.mceMenuButtonSelected img {border: 1px solid #6779AA; background-color: #B6BDD2;} -span.mceMenuButtonSelected img.mceMenuButton {border: 1px solid #F0F0EE; background-color: transparent;} -span.mceMenuButton img.mceMenuButton, span.mceMenuButtonSelected img.mceMenuButton {border-left: 0; margin-left: 0;} -span.mceMenuButton:hover img, span.mceMenuButtonSelected:hover img {border: 1px solid #0A246A; background-color: #B6BDD2;} +span.mceMenuButton img, span.mceMenuButtonSelected img {border: 1px solid #F0F0EE; margin-left: 1px;} +span.mceMenuButtonSelected img {border: 1px solid #6779AA; background-color: #B6BDD2;} +span.mceMenuButtonSelected img.mceMenuButton {border: 1px solid #F0F0EE; background-color: transparent;} +span.mceMenuButton img.mceMenuButton, span.mceMenuButtonSelected img.mceMenuButton {border-left: 0; margin-left: 0;} +span.mceMenuButton:hover img, span.mceMenuButtonSelected:hover img {border: 1px solid #0A246A; background-color: #B6BDD2;} span.mceMenuButton:hover img.mceMenuButton, span.mceMenuButtonSelected:hover img.mceMenuButton {border-left: 0;} -span.mceMenuButtonFocus img {border: 1px solid gray; border-right: 0; margin-left: 1px; background-color: #F5F4F2;} -span.mceMenuButtonFocus img.mceMenuButton {border: 1px solid gray; border-left: 1px solid #F5F4F2; margin-left: 0;} -span.mceMenuHover img {border: 1px solid #0A246A; background-color: #B6BDD2;} -span.mceMenuButtonSelected.mceMenuHover img.mceMenuButton {border: 1px solid #0A246A; background-color: #B6BDD2; border-left: 0;} +span.mceMenuButtonFocus img {border: 1px solid gray; border-right: 0; margin-left: 1px; background-color: #F5F4F2;} +span.mceMenuButtonFocus img.mceMenuButton {border: 1px solid gray; border-left: 1px solid #F5F4F2; margin-left: 0;} +span.mceMenuHover img {border: 1px solid #0A246A; background-color: #B6BDD2;} +span.mceMenuButtonSelected.mceMenuHover img.mceMenuButton {border: 1px solid #0A246A; background-color: #B6BDD2; border-left: 0;} /* Menu */ -.mceMenu {position: absolute; left: 0; top: 0; display: none; z-index: 100; background-color: white; border: 1px solid gray; font-weight: normal;} -.mceMenu a, .mceMenuTitle, .mceMenuDisabled {display: block; width: 100%; text-decoration: none; background-color: white; font-family: Tahoma, Verdana, Arial, Helvetica; font-size: 11px; line-height: 20px; color: black;} -.mceMenu a:hover {background-color: #B6BDD2; color: black; text-decoration: none !important;} -.mceMenu span {padding-left: 10px; padding-right: 10px; display: block; line-height: 20px;} -.mceMenuSeparator {border-bottom: 1px solid gray; background-color: gray; height: 1px;} +.mceMenu {position: absolute; left: 0; top: 0; display: none; z-index: 100; background-color: white; border: 1px solid gray; font-weight: normal;} +.mceMenu a, .mceMenuTitle, .mceMenuDisabled {display: block; width: 100%; text-decoration: none; background-color: white; font-family: Tahoma, Verdana, Arial, Helvetica; font-size: 11px; line-height: 20px; color: black;} +.mceMenu a:hover {background-color: #B6BDD2; color: black; text-decoration: none !important;} +.mceMenu span {padding-left: 10px; padding-right: 10px; display: block; line-height: 20px;} +.mceMenuSeparator {border-bottom: 1px solid gray; background-color: gray; height: 1px;} .mceMenuTitle span {padding-left: 5px;} -.mceMenuTitle {background-color: #DDDDDD; font-weight: bold;} +.mceMenuTitle {background-color: #DDDDDD; font-weight: bold;} .mceMenuDisabled {color: gray;} -span.mceMenuSelectedItem {background-image: url('../images/menu_check.gif'); background-repeat: no-repeat; background-position: 5px 8px; padding-left: 20px;} +span.mceMenuSelectedItem {background-image: url('../images/menu_check.gif'); background-repeat: no-repeat; background-position: 5px 8px; padding-left: 20px;} span.mceMenuCheckItem {padding-left: 20px;} -span.mceMenuLine {display: block; position: absolute; left: 0; top: -1px; background-color: #F5F4F2; width: 30px; height: 1px; overflow: hidden; padding-left: 0; padding-right: 0;} -.mceColors table, .mceColors td {margin: 0; padding: 2px;} -a.mceMoreColors {width: 130px; margin: 0; padding: 0; margin-left: 3px; margin-bottom: 3px; text-align: center; border: 1px solid white;} -.mceColorPreview {position: absolute; left: 0; top: 0; margin-left: 3px; margin-top: 15px; width: 16px; height: 4px; background-color: red;} +span.mceMenuLine {display: block; position: absolute; left: 0; top: -1px; background-color: #F5F4F2; width: 30px; height: 1px; overflow: hidden; padding-left: 0; padding-right: 0;} +.mceColors table, .mceColors td {margin: 0; padding: 2px;} +a.mceMoreColors {width: 130px; margin: 0; padding: 0; margin-left: 3px; margin-bottom: 3px; text-align: center; border: 1px solid white;} +.mceColorPreview {position: absolute; overflow:hidden; left: 0; top: 0; margin-left: 3px; margin-top: 15px; width: 16px; height: 4px; background-color: red;} a.mceMoreColors:hover {border: 1px solid #0A246A;} -.mceColors td a {width: 9px; height: 9px; overflow: hidden; border: 1px solid #808080;} +.mceColors td a {width: 9px; height: 9px; overflow: hidden; border: 1px solid #808080;} /* MSIE 6 specific rules */ -* html a.mceButtonNormal img, * html a.mceButtonSelected img, * html a.mceButtonDisabled img {border: 0 !important; margin-top: 2px; margin-bottom: 1px;} -* html a.mceButtonDisabled img {filter:progid:DXImageTransform.Microsoft.Alpha(opacity=30); border: 0 !important;} +* html a.mceButtonNormal img, * html a.mceButtonSelected img, * html a.mceButtonDisabled img {border: 0 !important; margin-top: 2px; margin-bottom: 1px;} +* html a.mceButtonDisabled img {filter:progid:DXImageTransform.Microsoft.Alpha(opacity=30); border: 0 !important;} * html a.mceButtonDisabled {border: 1px solid #F0F0EE !important;} -* html a.mceButtonNormal, * html a.mceButtonSelected {border: 1px solid #F0F0EE !important; cursor: default;} -* html a.mceButtonSelected {border: 1px solid #6779AA !important; background-color: #D4D5D8;} -* html a.mceButtonNormal:hover, * html a.mceButtonSelected:hover {border: 1px solid #0A246A !important; background-color: #B6BDD2; cursor: default;} +* html a.mceButtonNormal, * html a.mceButtonSelected {border: 1px solid #F0F0EE !important; cursor: default;} +* html a.mceButtonSelected {border: 1px solid #6779AA !important; background-color: #D4D5D8;} +* html a.mceButtonNormal:hover, * html a.mceButtonSelected:hover {border: 1px solid #0A246A !important; background-color: #B6BDD2; cursor: default;} * html .mceSelectList {margin-top: 2px;} -* html span.mceMenuButton, * html span.mceMenuButtonFocus {position: relative; left: 0; top: 0;} -* html span.mceMenuButton img, * html span.mceMenuButtonSelected img, * html span.mceMenuButtonFocus img {position: relative; top: 1px;} +* html span.mceMenuButton, * html span.mceMenuButtonFocus {position: relative; left: 0; top: 0;} +* html span.mceMenuButton img, * html span.mceMenuButtonSelected img, * html span.mceMenuButtonFocus img {position: relative; top: 1px;} * html a.mceMoreColors {width: 132px;} -* html .mceColors td a {width: 10px; height: 10px;} -* html .mceColorPreview {margin-left: 2px; margin-top: 14px;} +* html .mceColors td a {width: 10px; height: 10px;} +* html .mceColorPreview {margin-left: 2px; margin-top: 14px;} /* MSIE 7 specific rules */ -*:first-child+html a.mceButtonNormal img, *:first-child+html a.mceButtonSelected img, *:first-child+html a.mceButtonDisabled img {border: 0 !important; margin-top: 2px; margin-bottom: 1px;} -*:first-child+html a.mceButtonDisabled img {filter:progid:DXImageTransform.Microsoft.Alpha(opacity=30); border: 0 !important;} +*:first-child+html a.mceButtonNormal img, *:first-child+html a.mceButtonSelected img, *:first-child+html a.mceButtonDisabled img {border: 0 !important; margin-top: 2px; margin-bottom: 1px;} +*:first-child+html a.mceButtonDisabled img {filter:progid:DXImageTransform.Microsoft.Alpha(opacity=30); border: 0 !important;} *:first-child+html a.mceButtonDisabled {border: 1px solid #F0F0EE !important;} -*:first-child+html a.mceButtonNormal, *:first-child+html a.mceButtonSelected {border: 1px solid #F0F0EE !important; cursor: default;} -*:first-child+html a.mceButtonSelected {border: 1px solid #6779AA !important; background-color: #D4D5D8;} -*:first-child+html a.mceButtonNormal:hover, *:first-child+html a.mceButtonSelected:hover {border: 1px solid #0A246A !important; background-color: #B6BDD2; cursor: default;} +*:first-child+html a.mceButtonNormal, *:first-child+html a.mceButtonSelected {border: 1px solid #F0F0EE !important; cursor: default;} +*:first-child+html a.mceButtonSelected {border: 1px solid #6779AA !important; background-color: #D4D5D8;} +*:first-child+html a.mceButtonNormal:hover, *:first-child+html a.mceButtonSelected:hover {border: 1px solid #0A246A !important; background-color: #B6BDD2; cursor: default;} *:first-child+html .mceSelectList {margin-top: 2px;} -*:first-child+html span.mceMenuButton, *:first-child+html span.mceMenuButtonFocus {position: relative; left: 0; top: 0;} -*:first-child+html span.mceMenuButton img, *:first-child+html span.mceMenuButtonSelected img, *:first-child+html span.mceMenuButtonFocus img {position: relative; top: 1px;} +*:first-child+html span.mceMenuButton, *:first-child+html span.mceMenuButtonFocus {position: relative; left: 0; top: 0;} +*:first-child+html span.mceMenuButton img, *:first-child+html span.mceMenuButtonSelected img, *:first-child+html span.mceMenuButtonFocus img {position: relative; top: 1px;} *:first-child+html a.mceMoreColors {width: 132px;} -*:first-child+html .mceColors td a {width: 10px; height: 10px;} -*:first-child+html .mceColorPreview {margin: 0; padding-left: 4px; margin-top: 14px; width: 14px;} +*:first-child+html .mceColors td a {width: 10px; height: 10px;} +*:first-child+html .mceColorPreview {margin: 0; padding-left: 4px; margin-top: 14px; width: 14px;} diff --git a/wp-includes/js/tinymce/themes/advanced/editor_template.js b/wp-includes/js/tinymce/themes/advanced/editor_template.js index 2285832df4..3d918914b7 100644 --- a/wp-includes/js/tinymce/themes/advanced/editor_template.js +++ b/wp-includes/js/tinymce/themes/advanced/editor_template.js @@ -1,8 +1,8 @@ /** - * $Id: editor_template_src.js 129 2006-10-23 09:45:17Z spocke $ + * $Id: editor_template_src.js 166 2007-01-05 10:31:50Z spocke $ * * @author Moxiecode - * @copyright Copyright © 2004-2006, Moxiecode Systems AB, All rights reserved. + * @copyright Copyright © 2004-2007, Moxiecode Systems AB, All rights reserved. */ /* Import theme specific language pack */ @@ -713,8 +713,13 @@ var TinyMCE_AdvancedTheme = { template['html'] += ''; template['html'] = tinyMCE.replaceVar(template['html'], 'style_select_options', styleSelectHTML); - template['delta_width'] = 0; - template['delta_height'] = deltaHeight; + + // Set to default values + if (!template['delta_width']) + template['delta_width'] = 0; + + if (!template['delta_height']) + template['delta_height'] = deltaHeight; return template; }, @@ -732,6 +737,12 @@ var TinyMCE_AdvancedTheme = { inst.addShortcut('ctrl', 'k', 'lang_link_desc', 'mceLink'); }, + removeInstance : function(inst) { + var fcm = new TinyMCE_Layer(inst.editorId + '_fcMenu'); + + fcm.remove(); + }, + _handleMenuEvent : function(e) { var te = tinyMCE.isMSIE ? window.event.srcElement : e.target; tinyMCE._menuButtonEvent(e.type == "mouseover" ? "over" : "out", document.getElementById(te._switchId)); @@ -782,10 +793,6 @@ var TinyMCE_AdvancedTheme = { return false; }; - function getAttrib(elm, name) { - return elm.getAttribute(name) ? elm.getAttribute(name) : ""; - }; - // No node provided if (node == null) return; @@ -839,7 +846,7 @@ var TinyMCE_AdvancedTheme = { var st = tinyMCE.getAttrib(path[i], "style"); if (st != "") { st = tinyMCE.serializeStyle(tinyMCE.parseStyle(st)); - nodeData += "style: " + st + " "; + nodeData += "style: " + tinyMCE.xmlEncode(st) + " "; } } @@ -849,18 +856,18 @@ var TinyMCE_AdvancedTheme = { var face = tinyMCE.getAttrib(path[i], "face"); if (face != "") - nodeData += "font: " + face + " "; + nodeData += "font: " + tinyMCE.xmlEncode(face) + " "; var size = tinyMCE.getAttrib(path[i], "size"); if (size != "") - nodeData += "size: " + size + " "; + nodeData += "size: " + tinyMCE.xmlEncode(size) + " "; var color = tinyMCE.getAttrib(path[i], "color"); if (color != "") - nodeData += "color: " + color + " "; + nodeData += "color: " + tinyMCE.xmlEncode(color) + " "; } - if (getAttrib(path[i], 'id') != "") { + if (tinyMCE.getAttrib(path[i], 'id') != "") { nodeData += "id: " + path[i].getAttribute('id') + " "; } @@ -868,22 +875,22 @@ var TinyMCE_AdvancedTheme = { if (className != "" && className.indexOf('mceItem') == -1) nodeData += "class: " + className + " "; - if (getAttrib(path[i], 'src') != "") { + if (tinyMCE.getAttrib(path[i], 'src') != "") { var src = tinyMCE.getAttrib(path[i], "mce_src"); if (src == "") src = tinyMCE.getAttrib(path[i], "src"); - nodeData += "src: " + src + " "; + nodeData += "src: " + tinyMCE.xmlEncode(src) + " "; } - if (path[i].nodeName == 'A' && getAttrib(path[i], 'href') != "") { + if (path[i].nodeName == 'A' && tinyMCE.getAttrib(path[i], 'href') != "") { var href = tinyMCE.getAttrib(path[i], "mce_href"); if (href == "") href = tinyMCE.getAttrib(path[i], "href"); - nodeData += "href: " + href + " "; + nodeData += "href: " + tinyMCE.xmlEncode(href) + " "; } className = tinyMCE.getAttrib(path[i], "class"); @@ -894,11 +901,11 @@ var TinyMCE_AdvancedTheme = { if (nodeName == "a" && (anchor = tinyMCE.getAttrib(path[i], "name")) != "") { nodeName = "a"; - nodeName += "#" + anchor; + nodeName += "#" + tinyMCE.xmlEncode(anchor); nodeData = ""; } - if (getAttrib(path[i], 'name').indexOf("mce_") != 0) { + if (tinyMCE.getAttrib(path[i], 'name').indexOf("mce_") != 0) { var className = tinyMCE.getVisualAidClass(tinyMCE.getAttrib(path[i], "class"), false); if (className != "" && className.indexOf('mceItem') == -1) { nodeName += "." + className; @@ -1124,7 +1131,7 @@ var TinyMCE_AdvancedTheme = { break; case "IMG": - if (getAttrib(node, 'name').indexOf('mce_') != 0 && tinyMCE.getAttrib(node, 'class').indexOf('mceItem') == -1) { + if (tinyMCE.getAttrib(node, 'name').indexOf('mce_') != 0 && tinyMCE.getAttrib(node, 'class').indexOf('mceItem') == -1) { tinyMCE.switchClass(editor_id + '_image', 'mceButtonSelected'); } break; diff --git a/wp-includes/js/tinymce/themes/advanced/jscripts/source_editor.js b/wp-includes/js/tinymce/themes/advanced/jscripts/source_editor.js index 8395340ce8..83648be49c 100644 --- a/wp-includes/js/tinymce/themes/advanced/jscripts/source_editor.js +++ b/wp-includes/js/tinymce/themes/advanced/jscripts/source_editor.js @@ -25,7 +25,7 @@ function setWrap(val) { s.wrap = val; - if (tinyMCE.isGecko) { + if (tinyMCE.isGecko || tinyMCE.isOpera) { var v = s.value; var n = s.cloneNode(false); n.setAttribute("wrap", val); @@ -47,14 +47,13 @@ function resizeInputs() { var el = document.getElementById('htmlSource'); if (!tinyMCE.isMSIE) { - wHeight = self.innerHeight-80; - wWidth = self.innerWidth-16; + wHeight = self.innerHeight - 60; + wWidth = self.innerWidth - 16; } else { - wHeight = document.body.clientHeight - 80; + wHeight = document.body.clientHeight - 60; wWidth = document.body.clientWidth - 16; } el.style.height = Math.abs(wHeight) + 'px'; el.style.width = Math.abs(wWidth) + 'px'; } - diff --git a/wp-includes/js/tinymce/tiny_mce.js b/wp-includes/js/tinymce/tiny_mce.js index aece8d1475..c3f2159bc4 100644 --- a/wp-includes/js/tinymce/tiny_mce.js +++ b/wp-includes/js/tinymce/tiny_mce.js @@ -5,8 +5,8 @@ function TinyMCE_Engine() { var ua; this.majorVersion = "2"; - this.minorVersion = "0.8"; - this.releaseDate = "2006-10-23"; + this.minorVersion = "0.9"; + this.releaseDate = "2007-01-09"; this.instances = new Array(); this.switchClassCache = new Array(); @@ -192,6 +192,7 @@ TinyMCE_Engine.prototype = { this._def("hidden_tab_class", ''); this._def("display_tab_class", ''); this._def("gecko_spellcheck", false); + this._def("hide_selects_on_submit", true); // Force strict loading mode to false on non Gecko browsers if (this.isMSIE && !this.isOpera) @@ -242,7 +243,7 @@ TinyMCE_Engine.prototype = { this.posKeyCodes = new Array(13,45,36,35,33,34,37,38,39,40); this.uniqueURL = 'javascript:TINYMCE_UNIQUEURL();'; // Make unique URL non real URL this.uniqueTag = ' '; - this.callbacks = new Array('onInit', 'getInfo', 'getEditorTemplate', 'setupContent', 'onChange', 'onPageLoad', 'handleNodeChange', 'initInstance', 'execCommand', 'getControlHTML', 'handleEvent', 'cleanup'); + this.callbacks = new Array('onInit', 'getInfo', 'getEditorTemplate', 'setupContent', 'onChange', 'onPageLoad', 'handleNodeChange', 'initInstance', 'execCommand', 'getControlHTML', 'handleEvent', 'cleanup', 'removeInstance'); // Theme url this.settings['theme_href'] = tinyMCE.baseURL + "/themes/" + theme; @@ -338,6 +339,11 @@ TinyMCE_Engine.prototype = { } catch (e) { } } + + // Setup XML encoding regexps + this.xmlEncodeAposRe = new RegExp('[<>&"\']', 'g'); + this.xmlEncodeRe = new RegExp('[<>&"]', 'g'); +// this.xmlEncodeEnts = {'&':'&','"':'"',"'":''','<':'<','>':'>'}; }, _addUnloadEvents : function() { @@ -570,6 +576,9 @@ TinyMCE_Engine.prototype = { tinyMCE.undoLevels = n; tinyMCE.undoIndex = n.length; + // Dispatch remove instance call + tinyMCE.dispatchCallback(ti, 'remove_instance_callback', 'removeInstance', ti); + return ti; }, @@ -836,6 +845,7 @@ TinyMCE_Engine.prototype = { content = content.replace(/&/g, '&'); } + tinyMCE.selectedInstance = inst; inst.switchSettings(); // Not loaded correctly hit it again, Mozilla bug #997860 @@ -1015,8 +1025,8 @@ TinyMCE_Engine.prototype = { storeAwayURLs : function(s) { // Remove all mce_src, mce_href and replace them with new ones - // s = s.replace(new RegExp('mce_src\\s*=\\s*\"[^ >\"]*\"', 'gi'), ''); - // s = s.replace(new RegExp('mce_href\\s*=\\s*\"[^ >\"]*\"', 'gi'), ''); + // s = s.replace(new RegExp('mce_src\\s*=\\s*\"[^ >\"]*\"', 'gi'), ''); + // s = s.replace(new RegExp('mce_href\\s*=\\s*\"[^ >\"]*\"', 'gi'), ''); if (!s.match(/(mce_src|mce_href)/gi, s)) { s = s.replace(new RegExp('src\\s*=\\s*\"([^ >\"]*)\"', 'gi'), 'src="$1" mce_src="$1"'); @@ -1038,6 +1048,38 @@ TinyMCE_Engine.prototype = { } }, + removeTinyMCEFormElements : function(form_obj) { + var i, elementId; + + // Skip form element removal + if (!tinyMCE.getParam('hide_selects_on_submit')) + return; + + // Check if form is valid + if (typeof(form_obj) == "undefined" || form_obj == null) + return; + + // If not a form, find the form + if (form_obj.nodeName != "FORM") { + if (form_obj.form) + form_obj = form_obj.form; + else + form_obj = tinyMCE.getParentElement(form_obj, "form"); + } + + // Still nothing + if (form_obj == null) + return; + + // Disable all UI form elements that TinyMCE created + for (i=0; iby Moxiecode Systems AB. It has the ability to convert HTML TEXTAREA fields or other HTML elements to editor instances.'), '') ?>
Moxiecode Systems AB, All rights reserved.') ?>
TinyMCE website.') ?>
diff --git a/wp-includes/script-loader.php b/wp-includes/script-loader.php index 17042bb36a..3351eef692 100644 --- a/wp-includes/script-loader.php +++ b/wp-includes/script-loader.php @@ -15,9 +15,9 @@ class WP_Scripts { $this->add( 'sack', '/wp-includes/js/tw-sack.js', false, '1.6.1' ); $this->add( 'quicktags', '/wp-includes/js/quicktags.js', false, '3517' ); $this->add( 'colorpicker', '/wp-includes/js/colorpicker.js', false, '3517' ); - $this->add( 'tiny_mce', '/wp-includes/js/tinymce/tiny_mce_gzip.php', false, '20061113' ); + $this->add( 'tiny_mce', '/wp-includes/js/tinymce/tiny_mce_gzip.php', false, '20070124' ); $mce_config = apply_filters('tiny_mce_config_url', '/wp-includes/js/tinymce/tiny_mce_config.php'); - $this->add( 'wp_tiny_mce', $mce_config, array('tiny_mce'), '20061113' ); + $this->add( 'wp_tiny_mce', $mce_config, array('tiny_mce'), '20070124' ); $this->add( 'prototype', '/wp-includes/js/prototype.js', false, '1.5.0'); $this->add( 'autosave', '/wp-includes/js/autosave-js.php', array('prototype', 'sack'), '20070116'); $this->add( 'wp-ajax', '/wp-includes/js/wp-ajax-js.php', array('prototype'), '20070118');