mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-24 10:09:47 +01:00
Update TinyMCE to 3.5.4.1, fixes #21173
git-svn-id: http://core.svn.wordpress.org/trunk@21228 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
4db9e5c605
commit
54294ad174
@ -499,6 +499,7 @@
|
|||||||
top: 0;
|
top: 0;
|
||||||
z-index: 1000;
|
z-index: 1000;
|
||||||
border-color: #ddd;
|
border-color: #ddd;
|
||||||
|
direction: ltr;
|
||||||
}
|
}
|
||||||
|
|
||||||
.wp_themeSkin .mceNoIcons span.mceIcon {
|
.wp_themeSkin .mceNoIcons span.mceIcon {
|
||||||
@ -622,6 +623,16 @@
|
|||||||
border: 1px dotted gray;
|
border: 1px dotted gray;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Rtl */
|
||||||
|
.mceRtl .mceListBox .mceText {
|
||||||
|
text-align: right;
|
||||||
|
padding: 0 4px 0 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mceRtl .mceMenuItem .mceText {
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
/* Formats */
|
/* Formats */
|
||||||
.wp_themeSkin .mce_p span.mceText {}
|
.wp_themeSkin .mce_p span.mceText {}
|
||||||
.wp_themeSkin .mce_address span.mceText {
|
.wp_themeSkin .mce_address span.mceText {
|
||||||
@ -853,6 +864,8 @@
|
|||||||
.wp_themeSkin span.mce_del {background-position:-940px -20px}
|
.wp_themeSkin span.mce_del {background-position:-940px -20px}
|
||||||
.wp_themeSkin span.mce_ins {background-position:-960px -20px}
|
.wp_themeSkin span.mce_ins {background-position:-960px -20px}
|
||||||
.wp_themeSkin span.mce_pagebreak {background-position:0 -40px}
|
.wp_themeSkin span.mce_pagebreak {background-position:0 -40px}
|
||||||
|
.wp_themeSkin span.mce_restoredraft {background-position:-20px -40px}
|
||||||
|
.wp_themeSkin span.mce_visualblocks {background-position: -40px -40px}
|
||||||
|
|
||||||
/* border */
|
/* border */
|
||||||
.wp_themeSkin .mceExternalToolbar,
|
.wp_themeSkin .mceExternalToolbar,
|
||||||
|
@ -1 +1 @@
|
|||||||
(function(){var a=tinymce.DOM;tinymce.create("tinymce.plugins.FullScreenPlugin",{init:function(d,e){var f=this,g={},c,b;f.editor=d;d.addCommand("mceFullScreen",function(){var i,j=a.doc.documentElement;if(d.getParam("fullscreen_is_enabled")){if(d.getParam("fullscreen_new_window")){closeFullscreen()}else{a.win.setTimeout(function(){tinymce.dom.Event.remove(a.win,"resize",f.resizeFunc);tinyMCE.get(d.getParam("fullscreen_editor_id")).setContent(d.getContent());tinyMCE.remove(d);a.remove("mce_fullscreen_container");j.style.overflow=d.getParam("fullscreen_html_overflow");a.setStyle(a.doc.body,"overflow",d.getParam("fullscreen_overflow"));a.win.scrollTo(d.getParam("fullscreen_scrollx"),d.getParam("fullscreen_scrolly"));tinyMCE.settings=tinyMCE.oldSettings},10)}return}if(d.getParam("fullscreen_new_window")){i=a.win.open(e+"/fullscreen.htm","mceFullScreenPopup","fullscreen=yes,menubar=no,toolbar=no,scrollbars=no,resizable=yes,left=0,top=0,width="+screen.availWidth+",height="+screen.availHeight);try{i.resizeTo(screen.availWidth,screen.availHeight)}catch(h){}}else{tinyMCE.oldSettings=tinyMCE.settings;g.fullscreen_overflow=a.getStyle(a.doc.body,"overflow",1)||"auto";g.fullscreen_html_overflow=a.getStyle(j,"overflow",1);c=a.getViewPort();g.fullscreen_scrollx=c.x;g.fullscreen_scrolly=c.y;if(tinymce.isOpera&&g.fullscreen_overflow=="visible"){g.fullscreen_overflow="auto"}if(tinymce.isIE&&g.fullscreen_overflow=="scroll"){g.fullscreen_overflow="auto"}if(tinymce.isIE&&(g.fullscreen_html_overflow=="visible"||g.fullscreen_html_overflow=="scroll")){g.fullscreen_html_overflow="auto"}if(g.fullscreen_overflow=="0px"){g.fullscreen_overflow=""}a.setStyle(a.doc.body,"overflow","hidden");j.style.overflow="hidden";c=a.getViewPort();a.win.scrollTo(0,0);if(tinymce.isIE){c.h-=1}if(tinymce.isIE6){b="absolute;top:"+c.y}else{b="fixed;top:0"}n=a.add(a.doc.body,"div",{id:"mce_fullscreen_container",style:"position:"+b+";left:0;width:"+c.w+"px;height:"+c.h+"px;z-index:200000;"});a.add(n,"div",{id:"mce_fullscreen"});tinymce.each(d.settings,function(k,l){g[l]=k});g.id="mce_fullscreen";g.width=n.clientWidth;g.height=n.clientHeight-15;g.fullscreen_is_enabled=true;g.fullscreen_editor_id=d.id;g.theme_advanced_resizing=false;g.save_onsavecallback=function(){d.setContent(tinyMCE.get(g.id).getContent());d.execCommand("mceSave")};tinymce.each(d.getParam("fullscreen_settings"),function(m,l){g[l]=m});if(g.theme_advanced_toolbar_location==="external"){g.theme_advanced_toolbar_location="top"}f.fullscreenEditor=new tinymce.Editor("mce_fullscreen",g);f.fullscreenEditor.onInit.add(function(){f.fullscreenEditor.setContent(d.getContent());f.fullscreenEditor.focus()});f.fullscreenEditor.render();f.fullscreenElement=new tinymce.dom.Element("mce_fullscreen_container");f.fullscreenElement.update();f.resizeFunc=tinymce.dom.Event.add(a.win,"resize",function(){var o=tinymce.DOM.getViewPort(),l=f.fullscreenEditor,k,m;k=l.dom.getSize(l.getContainer().firstChild);m=l.dom.getSize(l.getContainer().getElementsByTagName("iframe")[0]);l.theme.resizeTo(o.w-k.w+m.w,o.h-k.h+m.h)})}});d.addButton("fullscreen",{title:"fullscreen.desc",cmd:"mceFullScreen"});d.onNodeChange.add(function(i,h){h.setActive("fullscreen",i.getParam("fullscreen_is_enabled"))})},getInfo:function(){return{longname:"Fullscreen",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/fullscreen",version:tinymce.majorVersion+"."+tinymce.minorVersion}}});tinymce.PluginManager.add("fullscreen",tinymce.plugins.FullScreenPlugin)})();
|
(function(){var a=tinymce.DOM;tinymce.create("tinymce.plugins.FullScreenPlugin",{init:function(d,e){var f=this,g={},c,b;f.editor=d;d.addCommand("mceFullScreen",function(){var i,j=a.doc.documentElement;if(d.getParam("fullscreen_is_enabled")){if(d.getParam("fullscreen_new_window")){closeFullscreen()}else{a.win.setTimeout(function(){tinymce.dom.Event.remove(a.win,"resize",f.resizeFunc);tinyMCE.get(d.getParam("fullscreen_editor_id")).setContent(d.getContent());tinyMCE.remove(d);a.remove("mce_fullscreen_container");j.style.overflow=d.getParam("fullscreen_html_overflow");a.setStyle(a.doc.body,"overflow",d.getParam("fullscreen_overflow"));a.win.scrollTo(d.getParam("fullscreen_scrollx"),d.getParam("fullscreen_scrolly"));tinyMCE.settings=tinyMCE.oldSettings},10)}return}if(d.getParam("fullscreen_new_window")){i=a.win.open(e+"/fullscreen.htm","mceFullScreenPopup","fullscreen=yes,menubar=no,toolbar=no,scrollbars=no,resizable=yes,left=0,top=0,width="+screen.availWidth+",height="+screen.availHeight);try{i.resizeTo(screen.availWidth,screen.availHeight)}catch(h){}}else{tinyMCE.oldSettings=tinyMCE.settings;g.fullscreen_overflow=a.getStyle(a.doc.body,"overflow",1)||"auto";g.fullscreen_html_overflow=a.getStyle(j,"overflow",1);c=a.getViewPort();g.fullscreen_scrollx=c.x;g.fullscreen_scrolly=c.y;if(tinymce.isOpera&&g.fullscreen_overflow=="visible"){g.fullscreen_overflow="auto"}if(tinymce.isIE&&g.fullscreen_overflow=="scroll"){g.fullscreen_overflow="auto"}if(tinymce.isIE&&(g.fullscreen_html_overflow=="visible"||g.fullscreen_html_overflow=="scroll")){g.fullscreen_html_overflow="auto"}if(g.fullscreen_overflow=="0px"){g.fullscreen_overflow=""}a.setStyle(a.doc.body,"overflow","hidden");j.style.overflow="hidden";c=a.getViewPort();a.win.scrollTo(0,0);if(tinymce.isIE){c.h-=1}if(tinymce.isIE6||document.compatMode=="BackCompat"){b="absolute;top:"+c.y}else{b="fixed;top:0"}n=a.add(a.doc.body,"div",{id:"mce_fullscreen_container",style:"position:"+b+";left:0;width:"+c.w+"px;height:"+c.h+"px;z-index:200000;"});a.add(n,"div",{id:"mce_fullscreen"});tinymce.each(d.settings,function(k,l){g[l]=k});g.id="mce_fullscreen";g.width=n.clientWidth;g.height=n.clientHeight-15;g.fullscreen_is_enabled=true;g.fullscreen_editor_id=d.id;g.theme_advanced_resizing=false;g.save_onsavecallback=function(){d.setContent(tinyMCE.get(g.id).getContent());d.execCommand("mceSave")};tinymce.each(d.getParam("fullscreen_settings"),function(m,l){g[l]=m});if(g.theme_advanced_toolbar_location==="external"){g.theme_advanced_toolbar_location="top"}f.fullscreenEditor=new tinymce.Editor("mce_fullscreen",g);f.fullscreenEditor.onInit.add(function(){f.fullscreenEditor.setContent(d.getContent());f.fullscreenEditor.focus()});f.fullscreenEditor.render();f.fullscreenElement=new tinymce.dom.Element("mce_fullscreen_container");f.fullscreenElement.update();f.resizeFunc=tinymce.dom.Event.add(a.win,"resize",function(){var o=tinymce.DOM.getViewPort(),l=f.fullscreenEditor,k,m;k=l.dom.getSize(l.getContainer().firstChild);m=l.dom.getSize(l.getContainer().getElementsByTagName("iframe")[0]);l.theme.resizeTo(o.w-k.w+m.w,o.h-k.h+m.h)})}});d.addButton("fullscreen",{title:"fullscreen.desc",cmd:"mceFullScreen"});d.onNodeChange.add(function(i,h){h.setActive("fullscreen",i.getParam("fullscreen_is_enabled"))})},getInfo:function(){return{longname:"Fullscreen",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/fullscreen",version:tinymce.majorVersion+"."+tinymce.minorVersion}}});tinymce.PluginManager.add("fullscreen",tinymce.plugins.FullScreenPlugin)})();
|
@ -79,7 +79,7 @@
|
|||||||
vp.h -= 1;
|
vp.h -= 1;
|
||||||
|
|
||||||
// Use fixed position if it exists
|
// Use fixed position if it exists
|
||||||
if (tinymce.isIE6)
|
if (tinymce.isIE6 || document.compatMode == 'BackCompat')
|
||||||
posCss = 'absolute;top:' + vp.y;
|
posCss = 'absolute;top:' + vp.y;
|
||||||
else
|
else
|
||||||
posCss = 'fixed;top:0';
|
posCss = 'fixed;top:0';
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<title></title>
|
<title></title>
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||||
<script type="text/javascript" src="../../tiny_mce.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../tiny_mce.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
function patchCallback(settings, key) {
|
function patchCallback(settings, key) {
|
||||||
if (settings[key])
|
if (settings[key])
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head>
|
<head>
|
||||||
<title>Template for dialogs</title>
|
<title>Template for dialogs</title>
|
||||||
<link rel="stylesheet" type="text/css" href="skins/clearlooks2/window.css?ver=349-20120314" />
|
<link rel="stylesheet" type="text/css" href="skins/clearlooks2/window.css?ver=3541-20120705" />
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
|
File diff suppressed because one or more lines are too long
@ -28,6 +28,10 @@
|
|||||||
["Audio"]
|
["Audio"]
|
||||||
];
|
];
|
||||||
|
|
||||||
|
function normalizeSize(size) {
|
||||||
|
return typeof(size) == "string" ? size.replace(/[^0-9%]/g, '') : size;
|
||||||
|
}
|
||||||
|
|
||||||
function toArray(obj) {
|
function toArray(obj) {
|
||||||
var undef, out, i;
|
var undef, out, i;
|
||||||
|
|
||||||
@ -258,8 +262,8 @@
|
|||||||
'data-mce-json' : JSON.serialize(data, "'")
|
'data-mce-json' : JSON.serialize(data, "'")
|
||||||
});
|
});
|
||||||
|
|
||||||
img.width = data.width || (data.type == 'audio' ? "300" : "320");
|
img.width = data.width = normalizeSize(data.width || (data.type == 'audio' ? "300" : "320"));
|
||||||
img.height = data.height || (data.type == 'audio' ? "32" : "240");
|
img.height = data.height = normalizeSize(data.height || (data.type == 'audio' ? "32" : "240"));
|
||||||
|
|
||||||
return img;
|
return img;
|
||||||
},
|
},
|
||||||
@ -386,6 +390,10 @@
|
|||||||
style = editor.dom.serializeStyle(editor.dom.parseStyle(style, 'img'));
|
style = editor.dom.serializeStyle(editor.dom.parseStyle(style, 'img'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Use node width/height to override the data width/height when the placeholder is resized
|
||||||
|
data.width = node.attr('width') || data.width;
|
||||||
|
data.height = node.attr('height') || data.height;
|
||||||
|
|
||||||
// Handle iframe
|
// Handle iframe
|
||||||
if (typeItem.name === 'Iframe') {
|
if (typeItem.name === 'Iframe') {
|
||||||
replacement = new Node('iframe', 1);
|
replacement = new Node('iframe', 1);
|
||||||
@ -434,8 +442,8 @@
|
|||||||
// Create new object element
|
// Create new object element
|
||||||
video = new Node('video', 1).attr(tinymce.extend({
|
video = new Node('video', 1).attr(tinymce.extend({
|
||||||
id : node.attr('id'),
|
id : node.attr('id'),
|
||||||
width: node.attr('width'),
|
width: normalizeSize(node.attr('width')),
|
||||||
height: node.attr('height'),
|
height: normalizeSize(node.attr('height')),
|
||||||
style : style
|
style : style
|
||||||
}, data.video.attrs));
|
}, data.video.attrs));
|
||||||
|
|
||||||
@ -473,8 +481,8 @@
|
|||||||
// Create new object element
|
// Create new object element
|
||||||
audio = new Node('audio', 1).attr(tinymce.extend({
|
audio = new Node('audio', 1).attr(tinymce.extend({
|
||||||
id : node.attr('id'),
|
id : node.attr('id'),
|
||||||
width: node.attr('width'),
|
width: normalizeSize(node.attr('width')),
|
||||||
height: node.attr('height'),
|
height: normalizeSize(node.attr('height')),
|
||||||
style : style
|
style : style
|
||||||
}, data.video.attrs));
|
}, data.video.attrs));
|
||||||
|
|
||||||
@ -502,8 +510,8 @@
|
|||||||
embed.shortEnded = true;
|
embed.shortEnded = true;
|
||||||
embed.attr({
|
embed.attr({
|
||||||
id: node.attr('id'),
|
id: node.attr('id'),
|
||||||
width: node.attr('width'),
|
width: normalizeSize(node.attr('width')),
|
||||||
height: node.attr('height'),
|
height: normalizeSize(node.attr('height')),
|
||||||
style : style,
|
style : style,
|
||||||
type: node.attr('type')
|
type: node.attr('type')
|
||||||
});
|
});
|
||||||
@ -531,8 +539,8 @@
|
|||||||
// Create new object element
|
// Create new object element
|
||||||
object = new Node('object', 1).attr({
|
object = new Node('object', 1).attr({
|
||||||
id : node.attr('id'),
|
id : node.attr('id'),
|
||||||
width: node.attr('width'),
|
width: normalizeSize(node.attr('width')),
|
||||||
height: node.attr('height'),
|
height: normalizeSize(node.attr('height')),
|
||||||
style : style
|
style : style
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -576,8 +584,8 @@
|
|||||||
embed.shortEnded = true;
|
embed.shortEnded = true;
|
||||||
embed.attr({
|
embed.attr({
|
||||||
id: node.attr('id'),
|
id: node.attr('id'),
|
||||||
width: node.attr('width'),
|
width: normalizeSize(node.attr('width')),
|
||||||
height: node.attr('height'),
|
height: normalizeSize(node.attr('height')),
|
||||||
style : style,
|
style : style,
|
||||||
type: typeItem.mimes[0]
|
type: typeItem.mimes[0]
|
||||||
});
|
});
|
||||||
@ -793,8 +801,8 @@
|
|||||||
|
|
||||||
if (iframe) {
|
if (iframe) {
|
||||||
// Get width/height
|
// Get width/height
|
||||||
width = iframe.attr('width');
|
width = normalizeSize(iframe.attr('width'));
|
||||||
height = iframe.attr('height');
|
height = normalizeSize(iframe.attr('height'));
|
||||||
style = style || iframe.attr('style');
|
style = style || iframe.attr('style');
|
||||||
id = iframe.attr('id');
|
id = iframe.attr('id');
|
||||||
hspace = iframe.attr('hspace');
|
hspace = iframe.attr('hspace');
|
||||||
|
@ -2,13 +2,13 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head>
|
<head>
|
||||||
<title>{#media_dlg.title}</title>
|
<title>{#media_dlg.title}</title>
|
||||||
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="js/media.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="js/media.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="../../utils/mctabs.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../utils/mctabs.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="../../utils/validate.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../utils/validate.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="../../utils/form_utils.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../utils/form_utils.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="../../utils/editable_selects.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../utils/editable_selects.js?ver=3541-20120705"></script>
|
||||||
<link href="css/media.css?ver=349-20120314" rel="stylesheet" type="text/css" />
|
<link href="css/media.css?ver=3541-20120705" rel="stylesheet" type="text/css" />
|
||||||
</head>
|
</head>
|
||||||
<body style="display: none" role="application">
|
<body style="display: none" role="application">
|
||||||
<form onsubmit="Media.insert();return false;" action="#">
|
<form onsubmit="Media.insert();return false;" action="#">
|
||||||
|
File diff suppressed because one or more lines are too long
@ -359,7 +359,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
// IE9 adds BRs before/after block elements when contents is pasted from word or for example another browser
|
// IE9 adds BRs before/after block elements when contents is pasted from word or for example another browser
|
||||||
if (tinymce.isIE && document.documentMode >= 9) {
|
if (tinymce.isIE && document.documentMode >= 9 && /<(h[1-6r]|p|div|address|pre|form|table|tbody|thead|tfoot|th|tr|td|li|ol|ul|caption|blockquote|center|dl|dt|dd|dir|fieldset)/.test(o.content)) {
|
||||||
// IE9 adds BRs before/after block elements when contents is pasted from word or for example another browser
|
// IE9 adds BRs before/after block elements when contents is pasted from word or for example another browser
|
||||||
process([[/(?:<br> [\s\r\n]+|<br>)*(<\/?(h[1-6r]|p|div|address|pre|form|table|tbody|thead|tfoot|th|tr|td|li|ol|ul|caption|blockquote|center|dl|dt|dd|dir|fieldset)[^>]*>)(?:<br> [\s\r\n]+|<br>)*/g, '$1']]);
|
process([[/(?:<br> [\s\r\n]+|<br>)*(<\/?(h[1-6r]|p|div|address|pre|form|table|tbody|thead|tfoot|th|tr|td|li|ol|ul|caption|blockquote|center|dl|dt|dd|dir|fieldset)[^>]*>)(?:<br> [\s\r\n]+|<br>)*/g, '$1']]);
|
||||||
|
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head>
|
<head>
|
||||||
<title>{#paste.paste_text_desc}</title>
|
<title>{#paste.paste_text_desc}</title>
|
||||||
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="js/pastetext.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="js/pastetext.js?ver=3541-20120705"></script>
|
||||||
</head>
|
</head>
|
||||||
<body onresize="PasteTextDialog.resize();" style="display:none; overflow:hidden;">
|
<body onresize="PasteTextDialog.resize();" style="display:none; overflow:hidden;">
|
||||||
<form name="source" onsubmit="return PasteTextDialog.insert();" action="#">
|
<form name="source" onsubmit="return PasteTextDialog.insert();" action="#">
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head>
|
<head>
|
||||||
<title>{#paste.paste_word_desc}</title>
|
<title>{#paste.paste_word_desc}</title>
|
||||||
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="js/pasteword.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="js/pasteword.js?ver=3541-20120705"></script>
|
||||||
</head>
|
</head>
|
||||||
<body onresize="PasteWordDialog.resize();" style="display:none; overflow:hidden;">
|
<body onresize="PasteWordDialog.resize();" style="display:none; overflow:hidden;">
|
||||||
<form name="source" onsubmit="return PasteWordDialog.insert();" action="#">
|
<form name="source" onsubmit="return PasteWordDialog.insert();" action="#">
|
||||||
|
File diff suppressed because one or more lines are too long
@ -208,7 +208,7 @@
|
|||||||
},
|
},
|
||||||
|
|
||||||
_removeWords : function(w) {
|
_removeWords : function(w) {
|
||||||
var ed = this.editor, dom = ed.dom, se = ed.selection, b = se.getBookmark();
|
var ed = this.editor, dom = ed.dom, se = ed.selection, r = se.getRng(true);
|
||||||
|
|
||||||
each(dom.select('span').reverse(), function(n) {
|
each(dom.select('span').reverse(), function(n) {
|
||||||
if (n && (dom.hasClass(n, 'mceItemHiddenSpellWord') || dom.hasClass(n, 'mceItemHidden'))) {
|
if (n && (dom.hasClass(n, 'mceItemHiddenSpellWord') || dom.hasClass(n, 'mceItemHidden'))) {
|
||||||
@ -217,11 +217,11 @@
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
se.moveToBookmark(b);
|
se.setRng(r);
|
||||||
},
|
},
|
||||||
|
|
||||||
_markWords : function(wl) {
|
_markWords : function(wl) {
|
||||||
var ed = this.editor, dom = ed.dom, doc = ed.getDoc(), se = ed.selection, b = se.getBookmark(), nl = [],
|
var ed = this.editor, dom = ed.dom, doc = ed.getDoc(), se = ed.selection, r = se.getRng(true), nl = [],
|
||||||
w = wl.join('|'), re = this._getSeparators(), rx = new RegExp('(^|[' + re + '])(' + w + ')(?=[' + re + ']|$)', 'g');
|
w = wl.join('|'), re = this._getSeparators(), rx = new RegExp('(^|[' + re + '])(' + w + ')(?=[' + re + ']|$)', 'g');
|
||||||
|
|
||||||
// Collect all text nodes
|
// Collect all text nodes
|
||||||
@ -279,7 +279,7 @@
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
se.moveToBookmark(b);
|
se.setRng(r);
|
||||||
},
|
},
|
||||||
|
|
||||||
_showMenu : function(ed, e) {
|
_showMenu : function(ed, e) {
|
||||||
|
@ -1 +1 @@
|
|||||||
(function(){var c=tinymce.DOM,a=tinymce.dom.Event,d=tinymce.each,b=tinymce.explode;tinymce.create("tinymce.plugins.TabFocusPlugin",{init:function(f,g){function e(i,j){if(j.keyCode===9){return a.cancel(j)}}function h(l,p){var j,m,o,n,k;function q(t){n=c.select(":input:enabled,*[tabindex]");function s(v){return v.nodeName==="BODY"||(v.type!="hidden"&&!(v.style.display=="none")&&!(v.style.visibility=="hidden")&&s(v.parentNode))}function i(v){return v.attributes.tabIndex.specified||v.nodeName=="INPUT"||v.nodeName=="TEXTAREA"}function u(){return tinymce.isIE6||tinymce.isIE7}function r(v){return((!u()||i(v)))&&v.getAttribute("tabindex")!="-1"&&s(v)}d(n,function(w,v){if(w.id==l.id){j=v;return false}});if(t>0){for(m=j+1;m<n.length;m++){if(r(n[m])){return n[m]}}}else{for(m=j-1;m>=0;m--){if(r(n[m])){return n[m]}}}return null}if(p.keyCode===9){k=b(l.getParam("tab_focus",l.getParam("tabfocus_elements",":prev,:next")));if(k.length==1){k[1]=k[0];k[0]=":prev"}if(p.shiftKey){if(k[0]==":prev"){n=q(-1)}else{n=c.get(k[0])}}else{if(k[1]==":next"){n=q(1)}else{n=c.get(k[1])}}if(n){if(n.id&&(l=tinymce.get(n.id||n.name))){l.focus()}else{window.setTimeout(function(){if(!tinymce.isWebKit){window.focus()}n.focus()},10)}return a.cancel(p)}}}f.onKeyUp.add(e);if(tinymce.isGecko){f.onKeyPress.add(h);f.onKeyDown.add(e)}else{f.onKeyDown.add(h)}},getInfo:function(){return{longname:"Tabfocus",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/tabfocus",version:tinymce.majorVersion+"."+tinymce.minorVersion}}});tinymce.PluginManager.add("tabfocus",tinymce.plugins.TabFocusPlugin)})();
|
(function(){var c=tinymce.DOM,a=tinymce.dom.Event,d=tinymce.each,b=tinymce.explode;tinymce.create("tinymce.plugins.TabFocusPlugin",{init:function(f,g){function e(i,j){if(j.keyCode===9){return a.cancel(j)}}function h(l,p){var j,m,o,n,k;function q(t){n=c.select(":input:enabled,*[tabindex]:not(iframe)");function s(v){return v.nodeName==="BODY"||(v.type!="hidden"&&!(v.style.display=="none")&&!(v.style.visibility=="hidden")&&s(v.parentNode))}function i(v){return v.attributes.tabIndex.specified||v.nodeName=="INPUT"||v.nodeName=="TEXTAREA"}function u(){return tinymce.isIE6||tinymce.isIE7}function r(v){return((!u()||i(v)))&&v.getAttribute("tabindex")!="-1"&&s(v)}d(n,function(w,v){if(w.id==l.id){j=v;return false}});if(t>0){for(m=j+1;m<n.length;m++){if(r(n[m])){return n[m]}}}else{for(m=j-1;m>=0;m--){if(r(n[m])){return n[m]}}}return null}if(p.keyCode===9){k=b(l.getParam("tab_focus",l.getParam("tabfocus_elements",":prev,:next")));if(k.length==1){k[1]=k[0];k[0]=":prev"}if(p.shiftKey){if(k[0]==":prev"){n=q(-1)}else{n=c.get(k[0])}}else{if(k[1]==":next"){n=q(1)}else{n=c.get(k[1])}}if(n){if(n.id&&(l=tinymce.get(n.id||n.name))){l.focus()}else{window.setTimeout(function(){if(!tinymce.isWebKit){window.focus()}n.focus()},10)}return a.cancel(p)}}}f.onKeyUp.add(e);if(tinymce.isGecko){f.onKeyPress.add(h);f.onKeyDown.add(e)}else{f.onKeyDown.add(h)}},getInfo:function(){return{longname:"Tabfocus",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/tabfocus",version:tinymce.majorVersion+"."+tinymce.minorVersion}}});tinymce.PluginManager.add("tabfocus",tinymce.plugins.TabFocusPlugin)})();
|
@ -22,7 +22,7 @@
|
|||||||
var x, i, f, el, v;
|
var x, i, f, el, v;
|
||||||
|
|
||||||
function find(d) {
|
function find(d) {
|
||||||
el = DOM.select(':input:enabled,*[tabindex]');
|
el = DOM.select(':input:enabled,*[tabindex]:not(iframe)');
|
||||||
|
|
||||||
function canSelectRecursive(e) {
|
function canSelectRecursive(e) {
|
||||||
return e.nodeName==="BODY" || (e.type != 'hidden' &&
|
return e.nodeName==="BODY" || (e.type != 'hidden' &&
|
||||||
|
@ -2,9 +2,9 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head>
|
<head>
|
||||||
<title>{#advanced_dlg.about_title}</title>
|
<title>{#advanced_dlg.about_title}</title>
|
||||||
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="../../utils/mctabs.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../utils/mctabs.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="js/about.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="js/about.js?ver=3541-20120705"></script>
|
||||||
</head>
|
</head>
|
||||||
<body id="about" style="display: none">
|
<body id="about" style="display: none">
|
||||||
<div class="tabs">
|
<div class="tabs">
|
||||||
|
@ -2,8 +2,8 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head>
|
<head>
|
||||||
<title>{#advanced_dlg.anchor_title}</title>
|
<title>{#advanced_dlg.anchor_title}</title>
|
||||||
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="js/anchor.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="js/anchor.js?ver=3541-20120705"></script>
|
||||||
</head>
|
</head>
|
||||||
<body style="display: none" role="application" aria-labelledby="app_title">
|
<body style="display: none" role="application" aria-labelledby="app_title">
|
||||||
<form onsubmit="AnchorDialog.update();return false;" action="#">
|
<form onsubmit="AnchorDialog.update();return false;" action="#">
|
||||||
|
@ -2,8 +2,8 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head>
|
<head>
|
||||||
<title>{#advanced_dlg.charmap_title}</title>
|
<title>{#advanced_dlg.charmap_title}</title>
|
||||||
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="js/charmap.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="js/charmap.js?ver=3541-20120705"></script>
|
||||||
</head>
|
</head>
|
||||||
<body id="charmap" style="display:none" role="application">
|
<body id="charmap" style="display:none" role="application">
|
||||||
<table align="center" border="0" cellspacing="0" cellpadding="2" role="presentation">
|
<table align="center" border="0" cellspacing="0" cellpadding="2" role="presentation">
|
||||||
|
@ -2,9 +2,9 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head>
|
<head>
|
||||||
<title>{#advanced_dlg.colorpicker_title}</title>
|
<title>{#advanced_dlg.colorpicker_title}</title>
|
||||||
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="../../utils/mctabs.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../utils/mctabs.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="js/color_picker.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="js/color_picker.js?ver=3541-20120705"></script>
|
||||||
</head>
|
</head>
|
||||||
<body id="colorpicker" style="display: none" role="application" aria-labelledby="app_label">
|
<body id="colorpicker" style="display: none" role="application" aria-labelledby="app_label">
|
||||||
<span class="mceVoiceLabel" id="app_label" style="display:none;">{#advanced_dlg.colorpicker_title}</span>
|
<span class="mceVoiceLabel" id="app_label" style="display:none;">{#advanced_dlg.colorpicker_title}</span>
|
||||||
@ -61,15 +61,9 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mceActionPanel">
|
<div class="mceActionPanel">
|
||||||
<div style="float: left">
|
|
||||||
<input type="submit" id="insert" name="insert" value="{#apply}" />
|
<input type="submit" id="insert" name="insert" value="{#apply}" />
|
||||||
</div>
|
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();"/>
|
||||||
|
<div id="preview_wrapper"><div id="previewblock"><label for="color">{#advanced_dlg.colorpicker_color}</label> <input id="color" type="text" size="8" class="text mceFocus" aria-required="true" /></div><span id="preview"></span></div>
|
||||||
<div id="preview"></div>
|
|
||||||
|
|
||||||
<div id="previewblock">
|
|
||||||
<label for="color">{#advanced_dlg.colorpicker_color}</label> <input id="color" type="text" size="8" class="text mceFocus" aria-required="true" />
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</body>
|
</body>
|
||||||
|
File diff suppressed because one or more lines are too long
@ -11,6 +11,95 @@
|
|||||||
(function(tinymce) {
|
(function(tinymce) {
|
||||||
var DOM = tinymce.DOM, Event = tinymce.dom.Event, extend = tinymce.extend, each = tinymce.each, Cookie = tinymce.util.Cookie, lastExtID, explode = tinymce.explode;
|
var DOM = tinymce.DOM, Event = tinymce.dom.Event, extend = tinymce.extend, each = tinymce.each, Cookie = tinymce.util.Cookie, lastExtID, explode = tinymce.explode;
|
||||||
|
|
||||||
|
// Generates a preview for a format
|
||||||
|
function getPreviewCss(ed, fmt) {
|
||||||
|
var previewElm, dom = ed.dom, previewCss = '', parentFontSize, previewStylesName;
|
||||||
|
|
||||||
|
previewStyles = ed.settings.preview_styles;
|
||||||
|
|
||||||
|
// No preview forced
|
||||||
|
if (previewStyles === false)
|
||||||
|
return '';
|
||||||
|
|
||||||
|
// Default preview
|
||||||
|
if (!previewStyles)
|
||||||
|
previewStyles = 'font-family font-size font-weight text-decoration text-transform color background-color';
|
||||||
|
|
||||||
|
// Removes any variables since these can't be previewed
|
||||||
|
function removeVars(val) {
|
||||||
|
return val.replace(/%(\w+)/g, '');
|
||||||
|
};
|
||||||
|
|
||||||
|
// Create block/inline element to use for preview
|
||||||
|
name = fmt.block || fmt.inline || 'span';
|
||||||
|
previewElm = dom.create(name);
|
||||||
|
|
||||||
|
// Add format styles to preview element
|
||||||
|
each(fmt.styles, function(value, name) {
|
||||||
|
value = removeVars(value);
|
||||||
|
|
||||||
|
if (value)
|
||||||
|
dom.setStyle(previewElm, name, value);
|
||||||
|
});
|
||||||
|
|
||||||
|
// Add attributes to preview element
|
||||||
|
each(fmt.attributes, function(value, name) {
|
||||||
|
value = removeVars(value);
|
||||||
|
|
||||||
|
if (value)
|
||||||
|
dom.setAttrib(previewElm, name, value);
|
||||||
|
});
|
||||||
|
|
||||||
|
// Add classes to preview element
|
||||||
|
each(fmt.classes, function(value) {
|
||||||
|
value = removeVars(value);
|
||||||
|
|
||||||
|
if (!dom.hasClass(previewElm, value))
|
||||||
|
dom.addClass(previewElm, value);
|
||||||
|
});
|
||||||
|
|
||||||
|
// Add the previewElm outside the visual area
|
||||||
|
dom.setStyles(previewElm, {position: 'absolute', left: -0xFFFF});
|
||||||
|
ed.getBody().appendChild(previewElm);
|
||||||
|
|
||||||
|
// Get parent container font size so we can compute px values out of em/% for older IE:s
|
||||||
|
parentFontSize = dom.getStyle(ed.getBody(), 'fontSize', true);
|
||||||
|
parentFontSize = /px$/.test(parentFontSize) ? parseInt(parentFontSize, 10) : 0;
|
||||||
|
|
||||||
|
each(previewStyles.split(' '), function(name) {
|
||||||
|
var value = dom.getStyle(previewElm, name, true);
|
||||||
|
|
||||||
|
// If background is transparent then check if the body has a background color we can use
|
||||||
|
if (name == 'background-color' && /transparent|rgba\s*\([^)]+,\s*0\)/.test(value)) {
|
||||||
|
value = dom.getStyle(ed.getBody(), name, true);
|
||||||
|
|
||||||
|
// Ignore white since it's the default color, not the nicest fix
|
||||||
|
if (dom.toHex(value).toLowerCase() == '#ffffff') {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Old IE won't calculate the font size so we need to do that manually
|
||||||
|
if (name == 'font-size') {
|
||||||
|
if (/em|%$/.test(value)) {
|
||||||
|
if (parentFontSize === 0) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Convert font size from em/% to px
|
||||||
|
value = parseFloat(value, 10) / (/%$/.test(value) ? 100 : 1);
|
||||||
|
value = (value * parentFontSize) + 'px';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
previewCss += name + ':' + value + ';';
|
||||||
|
});
|
||||||
|
|
||||||
|
dom.remove(previewElm);
|
||||||
|
|
||||||
|
return previewCss;
|
||||||
|
};
|
||||||
|
|
||||||
// Tell it to load theme specific language pack(s)
|
// Tell it to load theme specific language pack(s)
|
||||||
tinymce.ThemeManager.requireLangPack('advanced');
|
tinymce.ThemeManager.requireLangPack('advanced');
|
||||||
|
|
||||||
@ -65,19 +154,27 @@
|
|||||||
t.editor = ed;
|
t.editor = ed;
|
||||||
t.url = url;
|
t.url = url;
|
||||||
t.onResolveName = new tinymce.util.Dispatcher(this);
|
t.onResolveName = new tinymce.util.Dispatcher(this);
|
||||||
|
s = ed.settings;
|
||||||
|
|
||||||
ed.forcedHighContrastMode = ed.settings.detect_highcontrast && t._isHighContrast();
|
ed.forcedHighContrastMode = ed.settings.detect_highcontrast && t._isHighContrast();
|
||||||
ed.settings.skin = ed.forcedHighContrastMode ? 'highcontrast' : ed.settings.skin;
|
ed.settings.skin = ed.forcedHighContrastMode ? 'highcontrast' : ed.settings.skin;
|
||||||
|
|
||||||
|
// Setup default buttons
|
||||||
|
if (!s.theme_advanced_buttons1) {
|
||||||
|
s = extend({
|
||||||
|
theme_advanced_buttons1 : "bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,styleselect,formatselect",
|
||||||
|
theme_advanced_buttons2 : "bullist,numlist,|,outdent,indent,|,undo,redo,|,link,unlink,anchor,image,cleanup,help,code",
|
||||||
|
theme_advanced_buttons3 : "hr,removeformat,visualaid,|,sub,sup,|,charmap"
|
||||||
|
}, s);
|
||||||
|
}
|
||||||
|
|
||||||
// Default settings
|
// Default settings
|
||||||
t.settings = s = extend({
|
t.settings = s = extend({
|
||||||
theme_advanced_path : true,
|
theme_advanced_path : true,
|
||||||
theme_advanced_toolbar_location : 'bottom',
|
theme_advanced_toolbar_location : 'top',
|
||||||
theme_advanced_buttons1 : "bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,styleselect,formatselect",
|
|
||||||
theme_advanced_buttons2 : "bullist,numlist,|,outdent,indent,|,undo,redo,|,link,unlink,anchor,image,cleanup,help,code",
|
|
||||||
theme_advanced_buttons3 : "hr,removeformat,visualaid,|,sub,sup,|,charmap",
|
|
||||||
theme_advanced_blockformats : "p,address,pre,h1,h2,h3,h4,h5,h6",
|
theme_advanced_blockformats : "p,address,pre,h1,h2,h3,h4,h5,h6",
|
||||||
theme_advanced_toolbar_align : "center",
|
theme_advanced_toolbar_align : "left",
|
||||||
|
theme_advanced_statusbar_location : "bottom",
|
||||||
theme_advanced_fonts : "Andale Mono=andale mono,times;Arial=arial,helvetica,sans-serif;Arial Black=arial black,avant garde;Book Antiqua=book antiqua,palatino;Comic Sans MS=comic sans ms,sans-serif;Courier New=courier new,courier;Georgia=georgia,palatino;Helvetica=helvetica;Impact=impact,chicago;Symbol=symbol;Tahoma=tahoma,arial,helvetica,sans-serif;Terminal=terminal,monaco;Times New Roman=times new roman,times;Trebuchet MS=trebuchet ms,geneva;Verdana=verdana,geneva;Webdings=webdings;Wingdings=wingdings,zapf dingbats",
|
theme_advanced_fonts : "Andale Mono=andale mono,times;Arial=arial,helvetica,sans-serif;Arial Black=arial black,avant garde;Book Antiqua=book antiqua,palatino;Comic Sans MS=comic sans ms,sans-serif;Courier New=courier new,courier;Georgia=georgia,palatino;Helvetica=helvetica;Impact=impact,chicago;Symbol=symbol;Tahoma=tahoma,arial,helvetica,sans-serif;Terminal=terminal,monaco;Times New Roman=times new roman,times;Trebuchet MS=trebuchet ms,geneva;Verdana=verdana,geneva;Webdings=webdings;Wingdings=wingdings,zapf dingbats",
|
||||||
theme_advanced_more_colors : 1,
|
theme_advanced_more_colors : 1,
|
||||||
theme_advanced_row_height : 23,
|
theme_advanced_row_height : 23,
|
||||||
@ -87,7 +184,7 @@
|
|||||||
theme_advanced_font_selector : "span",
|
theme_advanced_font_selector : "span",
|
||||||
theme_advanced_show_current_color: 0,
|
theme_advanced_show_current_color: 0,
|
||||||
readonly : ed.settings.readonly
|
readonly : ed.settings.readonly
|
||||||
}, ed.settings);
|
}, s);
|
||||||
|
|
||||||
// Setup default font_size_style_values
|
// Setup default font_size_style_values
|
||||||
if (!s.font_size_style_values)
|
if (!s.font_size_style_values)
|
||||||
@ -219,15 +316,21 @@
|
|||||||
|
|
||||||
if (ctrl.getLength() == 0) {
|
if (ctrl.getLength() == 0) {
|
||||||
each(ed.dom.getClasses(), function(o, idx) {
|
each(ed.dom.getClasses(), function(o, idx) {
|
||||||
var name = 'style_' + idx;
|
var name = 'style_' + idx, fmt;
|
||||||
|
|
||||||
ed.formatter.register(name, {
|
fmt = {
|
||||||
inline : 'span',
|
inline : 'span',
|
||||||
attributes : {'class' : o['class']},
|
attributes : {'class' : o['class']},
|
||||||
selector : '*'
|
selector : '*'
|
||||||
});
|
};
|
||||||
|
|
||||||
ctrl.add(o['class'], name);
|
ed.formatter.register(name, fmt);
|
||||||
|
|
||||||
|
ctrl.add(o['class'], name, {
|
||||||
|
style: function() {
|
||||||
|
return getPreviewCss(ed, fmt);
|
||||||
|
}
|
||||||
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -239,7 +342,7 @@
|
|||||||
ctrl = ctrlMan.createListBox('styleselect', {
|
ctrl = ctrlMan.createListBox('styleselect', {
|
||||||
title : 'advanced.style_select',
|
title : 'advanced.style_select',
|
||||||
onselect : function(name) {
|
onselect : function(name) {
|
||||||
var matches, formatNames = [];
|
var matches, formatNames = [], removedFormat;
|
||||||
|
|
||||||
each(ctrl.items, function(item) {
|
each(ctrl.items, function(item) {
|
||||||
formatNames.push(item.value);
|
formatNames.push(item.value);
|
||||||
@ -248,12 +351,18 @@
|
|||||||
ed.focus();
|
ed.focus();
|
||||||
ed.undoManager.add();
|
ed.undoManager.add();
|
||||||
|
|
||||||
// Toggle off the current format
|
// Toggle off the current format(s)
|
||||||
matches = ed.formatter.matchAll(formatNames);
|
matches = ed.formatter.matchAll(formatNames);
|
||||||
if (!name || matches[0] == name) {
|
tinymce.each(matches, function(match) {
|
||||||
if (matches[0])
|
if (!name || match == name) {
|
||||||
ed.formatter.remove(matches[0]);
|
if (match)
|
||||||
} else
|
ed.formatter.remove(match);
|
||||||
|
|
||||||
|
removedFormat = true;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
if (!removedFormat)
|
||||||
ed.formatter.apply(name);
|
ed.formatter.apply(name);
|
||||||
|
|
||||||
ed.undoManager.add();
|
ed.undoManager.add();
|
||||||
@ -264,7 +373,7 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Handle specified format
|
// Handle specified format
|
||||||
ed.onInit.add(function() {
|
ed.onPreInit.add(function() {
|
||||||
var counter = 0, formats = ed.getParam('style_formats');
|
var counter = 0, formats = ed.getParam('style_formats');
|
||||||
|
|
||||||
if (formats) {
|
if (formats) {
|
||||||
@ -276,24 +385,32 @@
|
|||||||
if (keys > 1) {
|
if (keys > 1) {
|
||||||
name = fmt.name = fmt.name || 'style_' + (counter++);
|
name = fmt.name = fmt.name || 'style_' + (counter++);
|
||||||
ed.formatter.register(name, fmt);
|
ed.formatter.register(name, fmt);
|
||||||
ctrl.add(fmt.title, name);
|
ctrl.add(fmt.title, name, {
|
||||||
|
style: function() {
|
||||||
|
return getPreviewCss(ed, fmt);
|
||||||
|
}
|
||||||
|
});
|
||||||
} else
|
} else
|
||||||
ctrl.add(fmt.title);
|
ctrl.add(fmt.title);
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
each(ed.getParam('theme_advanced_styles', '', 'hash'), function(val, key) {
|
each(ed.getParam('theme_advanced_styles', '', 'hash'), function(val, key) {
|
||||||
var name;
|
var name, fmt;
|
||||||
|
|
||||||
if (val) {
|
if (val) {
|
||||||
name = 'style_' + (counter++);
|
name = 'style_' + (counter++);
|
||||||
|
fmt = {
|
||||||
ed.formatter.register(name, {
|
|
||||||
inline : 'span',
|
inline : 'span',
|
||||||
classes : val,
|
classes : val,
|
||||||
selector : '*'
|
selector : '*'
|
||||||
});
|
};
|
||||||
|
|
||||||
ctrl.add(t.editor.translate(key), name);
|
ed.formatter.register(name, fmt);
|
||||||
|
ctrl.add(t.editor.translate(key), name, {
|
||||||
|
style: function() {
|
||||||
|
return getPreviewCss(ed, fmt);
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -433,7 +550,9 @@
|
|||||||
|
|
||||||
if (c) {
|
if (c) {
|
||||||
each(t.editor.getParam('theme_advanced_blockformats', t.settings.theme_advanced_blockformats, 'hash'), function(v, k) {
|
each(t.editor.getParam('theme_advanced_blockformats', t.settings.theme_advanced_blockformats, 'hash'), function(v, k) {
|
||||||
c.add(t.editor.translate(k != v ? k : fmts[v]), v, {'class' : 'mce_formatPreview mce_' + v});
|
c.add(t.editor.translate(k != v ? k : fmts[v]), v, {'class' : 'mce_formatPreview mce_' + v, style: function() {
|
||||||
|
return getPreviewCss(t.editor, {block: v});
|
||||||
|
}});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -507,7 +626,7 @@
|
|||||||
|
|
||||||
// TODO: ACC Should have an aria-describedby attribute which is user-configurable to describe what this field is actually for.
|
// TODO: ACC Should have an aria-describedby attribute which is user-configurable to describe what this field is actually for.
|
||||||
// Maybe actually inherit it from the original textara?
|
// Maybe actually inherit it from the original textara?
|
||||||
n = p = DOM.create('span', {role : 'application', 'aria-labelledby' : ed.id + '_voice', id : ed.id + '_parent', 'class' : 'mceEditor ' + ed.settings.skin + 'Skin' + (s.skin_variant ? ' ' + ed.settings.skin + 'Skin' + t._ufirst(s.skin_variant) : '')});
|
n = p = DOM.create('span', {role : 'application', 'aria-labelledby' : ed.id + '_voice', id : ed.id + '_parent', 'class' : 'mceEditor ' + ed.settings.skin + 'Skin' + (s.skin_variant ? ' ' + ed.settings.skin + 'Skin' + t._ufirst(s.skin_variant) : '') + (ed.settings.directionality == "rtl" ? ' mceRtl' : '')});
|
||||||
DOM.add(n, 'span', {'class': 'mceVoiceLabel', 'style': 'display:none;', id: ed.id + '_voice'}, s.aria_label);
|
DOM.add(n, 'span', {'class': 'mceVoiceLabel', 'style': 'display:none;', id: ed.id + '_voice'}, s.aria_label);
|
||||||
|
|
||||||
if (!DOM.boxModel)
|
if (!DOM.boxModel)
|
||||||
@ -552,8 +671,7 @@
|
|||||||
|
|
||||||
if (e.nodeName == 'A') {
|
if (e.nodeName == 'A') {
|
||||||
t._sel(e.className.replace(/^.*mcePath_([0-9]+).*$/, '$1'));
|
t._sel(e.className.replace(/^.*mcePath_([0-9]+).*$/, '$1'));
|
||||||
|
return false;
|
||||||
return Event.cancel(e);
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
/*
|
/*
|
||||||
@ -825,7 +943,7 @@
|
|||||||
},
|
},
|
||||||
|
|
||||||
_addToolbars : function(c, o) {
|
_addToolbars : function(c, o) {
|
||||||
var t = this, i, tb, ed = t.editor, s = t.settings, v, cf = ed.controlManager, di, n, h = [], a, toolbarGroup;
|
var t = this, i, tb, ed = t.editor, s = t.settings, v, cf = ed.controlManager, di, n, h = [], a, toolbarGroup, toolbarsExist = false;
|
||||||
|
|
||||||
toolbarGroup = cf.createToolbarGroup('toolbargroup', {
|
toolbarGroup = cf.createToolbarGroup('toolbargroup', {
|
||||||
'name': ed.getLang('advanced.toolbar'),
|
'name': ed.getLang('advanced.toolbar'),
|
||||||
@ -841,6 +959,7 @@
|
|||||||
|
|
||||||
// Create toolbar and add the controls
|
// Create toolbar and add the controls
|
||||||
for (i=1; (v = s['theme_advanced_buttons' + i]); i++) {
|
for (i=1; (v = s['theme_advanced_buttons' + i]); i++) {
|
||||||
|
toolbarsExist = true;
|
||||||
tb = cf.createToolbar("toolbar" + i, {'class' : 'mceToolbarRow' + i});
|
tb = cf.createToolbar("toolbar" + i, {'class' : 'mceToolbarRow' + i});
|
||||||
|
|
||||||
if (s['theme_advanced_buttons' + i + '_add'])
|
if (s['theme_advanced_buttons' + i + '_add'])
|
||||||
@ -854,6 +973,9 @@
|
|||||||
|
|
||||||
o.deltaHeight -= s.theme_advanced_row_height;
|
o.deltaHeight -= s.theme_advanced_row_height;
|
||||||
}
|
}
|
||||||
|
// Handle case when there are no toolbar buttons and ensure editor height is adjusted accordingly
|
||||||
|
if (!toolbarsExist)
|
||||||
|
o.deltaHeight -= s.theme_advanced_row_height;
|
||||||
h.push(toolbarGroup.renderHTML());
|
h.push(toolbarGroup.renderHTML());
|
||||||
h.push(DOM.createHTML('a', {href : '#', accesskey : 'z', title : ed.getLang("advanced.toolbar_focus"), onfocus : 'tinyMCE.getInstanceById(\'' + ed.id + '\').focus();'}, '<!-- IE -->'));
|
h.push(DOM.createHTML('a', {href : '#', accesskey : 'z', title : ed.getLang("advanced.toolbar_focus"), onfocus : 'tinyMCE.getInstanceById(\'' + ed.id + '\').focus();'}, '<!-- IE -->'));
|
||||||
DOM.setHTML(n, h.join(''));
|
DOM.setHTML(n, h.join(''));
|
||||||
@ -975,19 +1097,17 @@
|
|||||||
|
|
||||||
p = getParent('A');
|
p = getParent('A');
|
||||||
if (c = cm.get('link')) {
|
if (c = cm.get('link')) {
|
||||||
if (!p || !p.name) {
|
c.setDisabled((!p && co) || (p && !p.href));
|
||||||
c.setDisabled(!p && co);
|
c.setActive(!!p && (!p.name && !p.id));
|
||||||
c.setActive(!!p);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (c = cm.get('unlink')) {
|
if (c = cm.get('unlink')) {
|
||||||
c.setDisabled(!p && co);
|
c.setDisabled(!p && co);
|
||||||
c.setActive(!!p && !p.name);
|
c.setActive(!!p && !p.name && !p.id);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (c = cm.get('anchor')) {
|
if (c = cm.get('anchor')) {
|
||||||
c.setActive(!co && !!p && p.name);
|
c.setActive(!co && !!p && (p.name || (p.id && !p.href)));
|
||||||
}
|
}
|
||||||
|
|
||||||
p = getParent('IMG');
|
p = getParent('IMG');
|
||||||
@ -1004,10 +1124,15 @@
|
|||||||
|
|
||||||
matches = ed.formatter.matchAll(formatNames);
|
matches = ed.formatter.matchAll(formatNames);
|
||||||
c.select(matches[0]);
|
c.select(matches[0]);
|
||||||
|
tinymce.each(matches, function(match, index) {
|
||||||
|
if (index > 0) {
|
||||||
|
c.mark(match);
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
if (c = cm.get('formatselect')) {
|
if (c = cm.get('formatselect')) {
|
||||||
p = getParent(DOM.isBlock);
|
p = getParent(ed.dom.isBlock);
|
||||||
|
|
||||||
if (p)
|
if (p)
|
||||||
c.select(p.nodeName.toLowerCase());
|
c.select(p.nodeName.toLowerCase());
|
||||||
@ -1105,7 +1230,7 @@
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
// Handle prefix
|
// Handle prefix
|
||||||
if (tinymce.isIE && n.scopeName !== 'HTML')
|
if (tinymce.isIE && n.scopeName !== 'HTML' && n.scopeName)
|
||||||
na = n.scopeName + ':' + na;
|
na = n.scopeName + ':' + na;
|
||||||
|
|
||||||
// Remove internal prefix
|
// Remove internal prefix
|
||||||
@ -1166,7 +1291,7 @@
|
|||||||
if (v) {
|
if (v) {
|
||||||
ti += 'class: ' + v + ' ';
|
ti += 'class: ' + v + ' ';
|
||||||
|
|
||||||
if (DOM.isBlock(n) || na == 'img' || na == 'span')
|
if (ed.dom.isBlock(n) || na == 'img' || na == 'span')
|
||||||
na += '.' + v;
|
na += '.' + v;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1294,7 +1419,7 @@
|
|||||||
var ed = this.editor;
|
var ed = this.editor;
|
||||||
|
|
||||||
// Internal image object like a flash placeholder
|
// Internal image object like a flash placeholder
|
||||||
if (ed.dom.getAttrib(ed.selection.getNode(), 'class').indexOf('mceItem') != -1)
|
if (ed.dom.getAttrib(ed.selection.getNode(), 'class', '').indexOf('mceItem') != -1)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
ed.windowManager.open({
|
ed.windowManager.open({
|
||||||
|
@ -2,10 +2,10 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head>
|
<head>
|
||||||
<title>{#advanced_dlg.image_title}</title>
|
<title>{#advanced_dlg.image_title}</title>
|
||||||
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="../../utils/mctabs.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../utils/mctabs.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="../../utils/form_utils.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../utils/form_utils.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="js/image.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="js/image.js?ver=3541-20120705"></script>
|
||||||
</head>
|
</head>
|
||||||
<body id="image" style="display: none">
|
<body id="image" style="display: none">
|
||||||
<form onsubmit="ImageDialog.update();return false;" action="#">
|
<form onsubmit="ImageDialog.update();return false;" action="#">
|
||||||
|
Binary file not shown.
Before Width: | Height: | Size: 12 KiB After Width: | Height: | Size: 12 KiB |
@ -6,7 +6,7 @@ var AnchorDialog = {
|
|||||||
|
|
||||||
this.editor = ed;
|
this.editor = ed;
|
||||||
elm = ed.dom.getParent(ed.selection.getNode(), 'A');
|
elm = ed.dom.getParent(ed.selection.getNode(), 'A');
|
||||||
v = ed.dom.getAttrib(elm, 'name');
|
v = ed.dom.getAttrib(elm, 'name') || ed.dom.getAttrib(elm, 'id');
|
||||||
|
|
||||||
if (v) {
|
if (v) {
|
||||||
this.action = 'update';
|
this.action = 'update';
|
||||||
@ -17,7 +17,7 @@ var AnchorDialog = {
|
|||||||
},
|
},
|
||||||
|
|
||||||
update : function() {
|
update : function() {
|
||||||
var ed = this.editor, elm, name = document.forms[0].anchorName.value;
|
var ed = this.editor, elm, name = document.forms[0].anchorName.value, attribName;
|
||||||
|
|
||||||
if (!name || !/^[a-z][a-z0-9\-\_:\.]*$/i.test(name)) {
|
if (!name || !/^[a-z][a-z0-9\-\_:\.]*$/i.test(name)) {
|
||||||
tinyMCEPopup.alert('advanced_dlg.anchor_invalid');
|
tinyMCEPopup.alert('advanced_dlg.anchor_invalid');
|
||||||
@ -29,12 +29,25 @@ var AnchorDialog = {
|
|||||||
if (this.action != 'update')
|
if (this.action != 'update')
|
||||||
ed.selection.collapse(1);
|
ed.selection.collapse(1);
|
||||||
|
|
||||||
|
var aRule = ed.schema.getElementRule('a');
|
||||||
|
if (!aRule || aRule.attributes.name) {
|
||||||
|
attribName = 'name';
|
||||||
|
} else {
|
||||||
|
attribName = 'id';
|
||||||
|
}
|
||||||
|
|
||||||
elm = ed.dom.getParent(ed.selection.getNode(), 'A');
|
elm = ed.dom.getParent(ed.selection.getNode(), 'A');
|
||||||
if (elm) {
|
if (elm) {
|
||||||
elm.setAttribute('name', name);
|
elm.setAttribute(attribName, name);
|
||||||
elm.name = name;
|
elm[attribName] = name;
|
||||||
} else
|
ed.undoManager.add();
|
||||||
ed.execCommand('mceInsertContent', 0, ed.dom.createHTML('a', {name : name, 'class' : 'mceItemAnchor'}, ''));
|
} else {
|
||||||
|
// create with zero-sized nbsp so that in Webkit where anchor is on last line by itself caret cannot be placed after it
|
||||||
|
var attrs = {'class' : 'mceItemAnchor'};
|
||||||
|
attrs[attribName] = name;
|
||||||
|
ed.execCommand('mceInsertContent', 0, ed.dom.createHTML('a', attrs, '\uFEFF'));
|
||||||
|
ed.nodeChanged();
|
||||||
|
}
|
||||||
|
|
||||||
tinyMCEPopup.close();
|
tinyMCEPopup.close();
|
||||||
}
|
}
|
||||||
|
@ -93,40 +93,56 @@ function toHexColor(color) {
|
|||||||
return value.length > 1 ? value : '0' + value; // Padd with leading zero
|
return value.length > 1 ? value : '0' + value; // Padd with leading zero
|
||||||
};
|
};
|
||||||
|
|
||||||
color = color.replace(/[\s#]+/g, '').toLowerCase();
|
color = tinymce.trim(color);
|
||||||
|
color = color.replace(/^[#]/, '').toLowerCase(); // remove leading '#'
|
||||||
color = namedLookup[color] || color;
|
color = namedLookup[color] || color;
|
||||||
matches = /^rgb\((\d{1,3}),(\d{1,3}),(\d{1,3})\)|([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})|([a-f0-9])([a-f0-9])([a-f0-9])$/.exec(color);
|
|
||||||
|
matches = /^rgb\((\d{1,3}),(\d{1,3}),(\d{1,3})\)$/.exec(color);
|
||||||
|
|
||||||
if (matches) {
|
if (matches) {
|
||||||
if (matches[1]) {
|
|
||||||
red = toInt(matches[1]);
|
red = toInt(matches[1]);
|
||||||
green = toInt(matches[2]);
|
green = toInt(matches[2]);
|
||||||
blue = toInt(matches[3]);
|
blue = toInt(matches[3]);
|
||||||
} else if (matches[4]) {
|
} else {
|
||||||
red = toInt(matches[4], 16);
|
matches = /^([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})$/.exec(color);
|
||||||
green = toInt(matches[5], 16);
|
|
||||||
blue = toInt(matches[6], 16);
|
if (matches) {
|
||||||
} else if (matches[7]) {
|
red = toInt(matches[1], 16);
|
||||||
red = toInt(matches[7] + matches[7], 16);
|
green = toInt(matches[2], 16);
|
||||||
green = toInt(matches[8] + matches[8], 16);
|
blue = toInt(matches[3], 16);
|
||||||
blue = toInt(matches[9] + matches[9], 16);
|
} else {
|
||||||
|
matches = /^([0-9a-f])([0-9a-f])([0-9a-f])$/.exec(color);
|
||||||
|
|
||||||
|
if (matches) {
|
||||||
|
red = toInt(matches[1] + matches[1], 16);
|
||||||
|
green = toInt(matches[2] + matches[2], 16);
|
||||||
|
blue = toInt(matches[3] + matches[3], 16);
|
||||||
|
} else {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return '#' + hex(red) + hex(green) + hex(blue);
|
return '#' + hex(red) + hex(green) + hex(blue);
|
||||||
}
|
|
||||||
|
|
||||||
return '';
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function insertAction() {
|
function insertAction() {
|
||||||
var color = document.getElementById("color").value, f = tinyMCEPopup.getWindowArg('func');
|
var color = document.getElementById("color").value, f = tinyMCEPopup.getWindowArg('func');
|
||||||
|
|
||||||
|
var hexColor = toHexColor(color);
|
||||||
|
|
||||||
|
if (hexColor === '') {
|
||||||
|
var text = tinyMCEPopup.editor.getLang('advanced_dlg.invalid_color_value');
|
||||||
|
tinyMCEPopup.alert(text + ': ' + color);
|
||||||
|
}
|
||||||
|
else {
|
||||||
tinyMCEPopup.restoreSelection();
|
tinyMCEPopup.restoreSelection();
|
||||||
|
|
||||||
if (f)
|
if (f)
|
||||||
f(toHexColor(color));
|
f(hexColor);
|
||||||
|
|
||||||
tinyMCEPopup.close();
|
tinyMCEPopup.close();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function showColor(color, name) {
|
function showColor(color, name) {
|
||||||
|
@ -104,10 +104,12 @@ var ImageDialog = {
|
|||||||
},
|
},
|
||||||
|
|
||||||
updateStyle : function() {
|
updateStyle : function() {
|
||||||
var dom = tinyMCEPopup.dom, st, v, f = document.forms[0];
|
var dom = tinyMCEPopup.dom, st = {}, v, f = document.forms[0];
|
||||||
|
|
||||||
if (tinyMCEPopup.editor.settings.inline_styles) {
|
if (tinyMCEPopup.editor.settings.inline_styles) {
|
||||||
st = tinyMCEPopup.dom.parseStyle(this.styleVal);
|
tinymce.each(tinyMCEPopup.dom.parseStyle(this.styleVal), function(value, key) {
|
||||||
|
st[key] = value;
|
||||||
|
});
|
||||||
|
|
||||||
// Handle align
|
// Handle align
|
||||||
v = getSelectValue(f, 'align');
|
v = getSelectValue(f, 'align');
|
||||||
|
@ -68,10 +68,16 @@ var LinkDialog = {
|
|||||||
} else {
|
} else {
|
||||||
ed.dom.setAttribs(e, {
|
ed.dom.setAttribs(e, {
|
||||||
href : href,
|
href : href,
|
||||||
title : f.linktitle.value,
|
title : f.linktitle.value
|
||||||
target : f.target_list ? getSelectValue(f, "target_list") : null,
|
|
||||||
'class' : f.class_list ? getSelectValue(f, "class_list") : null
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
if (f.target_list) {
|
||||||
|
ed.dom.setAttrib(e, 'target', getSelectValue(f, "target_list"));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (f.class_list) {
|
||||||
|
ed.dom.setAttrib(e, 'class', getSelectValue(f, "class_list"));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Don't move caret if selection was image
|
// Don't move caret if selection was image
|
||||||
|
@ -16,7 +16,7 @@ function onLoadInit() {
|
|||||||
document.getElementById('htmlSource').value = tinyMCEPopup.editor.getContent({source_view : true});
|
document.getElementById('htmlSource').value = tinyMCEPopup.editor.getContent({source_view : true});
|
||||||
|
|
||||||
if (tinyMCEPopup.editor.getParam("theme_advanced_source_editor_wrap", true)) {
|
if (tinyMCEPopup.editor.getParam("theme_advanced_source_editor_wrap", true)) {
|
||||||
setWrap('soft');
|
turnWrapOn();
|
||||||
document.getElementById('wraped').checked = true;
|
document.getElementById('wraped').checked = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -37,11 +37,33 @@ function setWrap(val) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function toggleWordWrap(elm) {
|
function setWhiteSpaceCss(value) {
|
||||||
if (elm.checked)
|
var el = document.getElementById('htmlSource');
|
||||||
setWrap('soft');
|
tinymce.DOM.setStyle(el, 'white-space', value);
|
||||||
else
|
}
|
||||||
|
|
||||||
|
function turnWrapOff() {
|
||||||
|
if (tinymce.isWebKit) {
|
||||||
|
setWhiteSpaceCss('pre');
|
||||||
|
} else {
|
||||||
setWrap('off');
|
setWrap('off');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function turnWrapOn() {
|
||||||
|
if (tinymce.isWebKit) {
|
||||||
|
setWhiteSpaceCss('pre-wrap');
|
||||||
|
} else {
|
||||||
|
setWrap('soft');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function toggleWordWrap(elm) {
|
||||||
|
if (elm.checked) {
|
||||||
|
turnWrapOn();
|
||||||
|
} else {
|
||||||
|
turnWrapOff();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function resizeInputs() {
|
function resizeInputs() {
|
||||||
|
@ -2,11 +2,11 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head>
|
<head>
|
||||||
<title>{#advanced_dlg.link_title}</title>
|
<title>{#advanced_dlg.link_title}</title>
|
||||||
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="../../utils/mctabs.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../utils/mctabs.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="../../utils/form_utils.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../utils/form_utils.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="../../utils/validate.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../utils/validate.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="js/link.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="js/link.js?ver=3541-20120705"></script>
|
||||||
</head>
|
</head>
|
||||||
<body id="link" style="display: none">
|
<body id="link" style="display: none">
|
||||||
<form onsubmit="LinkDialog.update();return false;" action="#">
|
<form onsubmit="LinkDialog.update();return false;" action="#">
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head>
|
<head>
|
||||||
<title>{#advanced_dlg.accessibility_help}</title>
|
<title>{#advanced_dlg.accessibility_help}</title>
|
||||||
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript">tinyMCEPopup.requireLangPack();</script>
|
<script type="text/javascript">tinyMCEPopup.requireLangPack();</script>
|
||||||
</head>
|
</head>
|
||||||
<body id="content">
|
<body id="content">
|
||||||
|
@ -105,11 +105,12 @@ h3 {font-size:14px;}
|
|||||||
#plugintable, #about #plugintable td {border:1px solid #919B9C;}
|
#plugintable, #about #plugintable td {border:1px solid #919B9C;}
|
||||||
#plugintable {width:96%; margin-top:10px;}
|
#plugintable {width:96%; margin-top:10px;}
|
||||||
#pluginscontainer {height:290px; overflow:auto;}
|
#pluginscontainer {height:290px; overflow:auto;}
|
||||||
#colorpicker #preview {float:right; width:50px; height:14px;line-height:1px; border:1px solid black; margin-left:5px;}
|
#colorpicker #preview {display:inline-block; padding-left:40px; height:14px; border:1px solid black; margin-left:5px; margin-right: 5px}
|
||||||
|
#colorpicker #previewblock {position: relative; top: -3px; padding-left:5px; padding-top: 0px; display:inline}
|
||||||
|
#colorpicker #preview_wrapper { text-align:center; padding-top:4px; white-space: nowrap}
|
||||||
#colorpicker #colors {float:left; border:1px solid gray; cursor:crosshair;}
|
#colorpicker #colors {float:left; border:1px solid gray; cursor:crosshair;}
|
||||||
#colorpicker #light {border:1px solid gray; margin-left:5px; float:left;width:15px; height:150px; cursor:crosshair;}
|
#colorpicker #light {border:1px solid gray; margin-left:5px; float:left;width:15px; height:150px; cursor:crosshair;}
|
||||||
#colorpicker #light div {overflow:hidden;}
|
#colorpicker #light div {overflow:hidden;}
|
||||||
#colorpicker #previewblock {float:right; padding-left:10px; height:20px;}
|
|
||||||
#colorpicker .panel_wrapper div.current {height:175px;}
|
#colorpicker .panel_wrapper div.current {height:175px;}
|
||||||
#colorpicker #namedcolors {width:150px;}
|
#colorpicker #namedcolors {width:150px;}
|
||||||
#colorpicker #namedcolors a {display:block; float:left; width:10px; height:10px; margin:1px 1px 0 0; overflow:hidden;}
|
#colorpicker #namedcolors a {display:block; float:left; width:10px; height:10px; margin:1px 1px 0 0; overflow:hidden;}
|
||||||
|
@ -83,7 +83,7 @@
|
|||||||
.defaultSkin .mce_forecolor span.mceAction, .defaultSkin .mce_backcolor span.mceAction {overflow:hidden; height:16px}
|
.defaultSkin .mce_forecolor span.mceAction, .defaultSkin .mce_backcolor span.mceAction {overflow:hidden; height:16px}
|
||||||
|
|
||||||
/* Menu */
|
/* Menu */
|
||||||
.defaultSkin .mceMenu {position:absolute; left:0; top:0; z-index:1000; border:1px solid #D4D0C8}
|
.defaultSkin .mceMenu {position:absolute; left:0; top:0; z-index:1000; border:1px solid #D4D0C8; direction:ltr}
|
||||||
.defaultSkin .mceNoIcons span.mceIcon {width:0;}
|
.defaultSkin .mceNoIcons span.mceIcon {width:0;}
|
||||||
.defaultSkin .mceNoIcons a .mceText {padding-left:10px}
|
.defaultSkin .mceNoIcons a .mceText {padding-left:10px}
|
||||||
.defaultSkin .mceMenu table {background:#FFF}
|
.defaultSkin .mceMenu table {background:#FFF}
|
||||||
@ -109,6 +109,10 @@
|
|||||||
.defaultSkin .mceBlocker {position:absolute; left:0; top:0; z-index:1000; opacity:0.5; -ms-filter:'alpha(opacity=50)'; filter:alpha(opacity=50); background:#FFF}
|
.defaultSkin .mceBlocker {position:absolute; left:0; top:0; z-index:1000; opacity:0.5; -ms-filter:'alpha(opacity=50)'; filter:alpha(opacity=50); background:#FFF}
|
||||||
.defaultSkin .mceProgress {position:absolute; left:0; top:0; z-index:1001; background:url(img/progress.gif) no-repeat; width:32px; height:32px; margin:-16px 0 0 -16px}
|
.defaultSkin .mceProgress {position:absolute; left:0; top:0; z-index:1001; background:url(img/progress.gif) no-repeat; width:32px; height:32px; margin:-16px 0 0 -16px}
|
||||||
|
|
||||||
|
/* Rtl */
|
||||||
|
.mceRtl .mceListBox .mceText {text-align: right; padding: 0 4px 0 0}
|
||||||
|
.mceRtl .mceMenuItem .mceText {text-align: right}
|
||||||
|
|
||||||
/* Formats */
|
/* Formats */
|
||||||
.defaultSkin .mce_formatPreview a {font-size:10px}
|
.defaultSkin .mce_formatPreview a {font-size:10px}
|
||||||
.defaultSkin .mce_p span.mceText {}
|
.defaultSkin .mce_p span.mceText {}
|
||||||
@ -212,3 +216,4 @@
|
|||||||
.defaultSkin span.mce_pagebreak {background-position:0 -40px}
|
.defaultSkin span.mce_pagebreak {background-position:0 -40px}
|
||||||
.defaultSkin span.mce_restoredraft {background-position:-20px -40px}
|
.defaultSkin span.mce_restoredraft {background-position:-20px -40px}
|
||||||
.defaultSkin span.mce_spellchecker {background-position:-540px -20px}
|
.defaultSkin span.mce_spellchecker {background-position:-540px -20px}
|
||||||
|
.defaultSkin span.mce_visualblocks {background-position: -40px -40px}
|
||||||
|
@ -94,11 +94,12 @@ h3 {font-size:14px;}
|
|||||||
#plugintable, #about #plugintable td {border:1px solid #919B9C;}
|
#plugintable, #about #plugintable td {border:1px solid #919B9C;}
|
||||||
#plugintable {width:96%; margin-top:10px;}
|
#plugintable {width:96%; margin-top:10px;}
|
||||||
#pluginscontainer {height:290px; overflow:auto;}
|
#pluginscontainer {height:290px; overflow:auto;}
|
||||||
#colorpicker #preview {float:right; width:50px; height:14px;line-height:1px; border:1px solid black; margin-left:5px;}
|
#colorpicker #preview {display:inline-block; padding-left:40px; height:14px; border:1px solid black; margin-left:5px; margin-right: 5px}
|
||||||
|
#colorpicker #previewblock {position: relative; top: -3px; padding-left:5px; padding-top: 0px; display:inline}
|
||||||
|
#colorpicker #preview_wrapper { text-align:center; padding-top:4px; white-space: nowrap}
|
||||||
#colorpicker #colors {float:left; border:1px solid gray; cursor:crosshair;}
|
#colorpicker #colors {float:left; border:1px solid gray; cursor:crosshair;}
|
||||||
#colorpicker #light {border:1px solid gray; margin-left:5px; float:left;width:15px; height:150px; cursor:crosshair;}
|
#colorpicker #light {border:1px solid gray; margin-left:5px; float:left;width:15px; height:150px; cursor:crosshair;}
|
||||||
#colorpicker #light div {overflow:hidden;}
|
#colorpicker #light div {overflow:hidden;}
|
||||||
#colorpicker #previewblock {float:right; padding-left:10px; height:20px;}
|
|
||||||
#colorpicker .panel_wrapper div.current {height:175px;}
|
#colorpicker .panel_wrapper div.current {height:175px;}
|
||||||
#colorpicker #namedcolors {width:150px;}
|
#colorpicker #namedcolors {width:150px;}
|
||||||
#colorpicker #namedcolors a {display:block; float:left; width:10px; height:10px; margin:1px 1px 0 0; overflow:hidden;}
|
#colorpicker #namedcolors a {display:block; float:left; width:10px; height:10px; margin:1px 1px 0 0; overflow:hidden;}
|
||||||
|
@ -58,7 +58,7 @@
|
|||||||
|
|
||||||
/* Menu */
|
/* Menu */
|
||||||
.highcontrastSkin .mceNoIcons span.mceIcon {width:0;}
|
.highcontrastSkin .mceNoIcons span.mceIcon {width:0;}
|
||||||
.highcontrastSkin .mceMenu {position:absolute; left:0; top:0; z-index:1000; border:1px solid; }
|
.highcontrastSkin .mceMenu {position:absolute; left:0; top:0; z-index:1000; border:1px solid; direction:ltr}
|
||||||
.highcontrastSkin .mceMenu table {background:white; color: black}
|
.highcontrastSkin .mceMenu table {background:white; color: black}
|
||||||
.highcontrastSkin .mceNoIcons a .mceText {padding-left:10px}
|
.highcontrastSkin .mceNoIcons a .mceText {padding-left:10px}
|
||||||
.highcontrastSkin .mceMenu a, .highcontrastSkin .mceMenu span, .highcontrastSkin .mceMenu {display:block;background:white; color: black}
|
.highcontrastSkin .mceMenu a, .highcontrastSkin .mceMenu span, .highcontrastSkin .mceMenu {display:block;background:white; color: black}
|
||||||
@ -90,6 +90,10 @@
|
|||||||
.highcontrastSkin .mceBlocker {position:absolute; left:0; top:0; z-index:1000; opacity:0.5; -ms-filter:'alpha(opacity=30)'; filter:alpha(opacity=50); background:#FFF}
|
.highcontrastSkin .mceBlocker {position:absolute; left:0; top:0; z-index:1000; opacity:0.5; -ms-filter:'alpha(opacity=30)'; filter:alpha(opacity=50); background:#FFF}
|
||||||
.highcontrastSkin .mceProgress {position:absolute; left:0; top:0; z-index:1001; background:url(../default/img/progress.gif) no-repeat; width:32px; height:32px; margin:-16px 0 0 -16px}
|
.highcontrastSkin .mceProgress {position:absolute; left:0; top:0; z-index:1001; background:url(../default/img/progress.gif) no-repeat; width:32px; height:32px; margin:-16px 0 0 -16px}
|
||||||
|
|
||||||
|
/* Rtl */
|
||||||
|
.mceRtl .mceListBox .mceText {text-align: right; padding: 0 4px 0 0}
|
||||||
|
.mceRtl .mceMenuItem .mceText {text-align: right}
|
||||||
|
|
||||||
/* Formats */
|
/* Formats */
|
||||||
.highcontrastSkin .mce_p span.mceText {}
|
.highcontrastSkin .mce_p span.mceText {}
|
||||||
.highcontrastSkin .mce_address span.mceText {font-style:italic}
|
.highcontrastSkin .mce_address span.mceText {font-style:italic}
|
||||||
|
@ -105,11 +105,12 @@ h3 {font-size:14px;}
|
|||||||
#plugintable, #about #plugintable td {border:1px solid #919B9C;}
|
#plugintable, #about #plugintable td {border:1px solid #919B9C;}
|
||||||
#plugintable {width:96%; margin-top:10px;}
|
#plugintable {width:96%; margin-top:10px;}
|
||||||
#pluginscontainer {height:290px; overflow:auto;}
|
#pluginscontainer {height:290px; overflow:auto;}
|
||||||
#colorpicker #preview {float:right; width:50px; height:14px;line-height:1px; border:1px solid black; margin-left:5px;}
|
#colorpicker #preview {display:inline-block; padding-left:40px; height:14px; border:1px solid black; margin-left:5px; margin-right: 5px}
|
||||||
|
#colorpicker #previewblock {position: relative; top: -3px; padding-left:5px; padding-top: 0px; display:inline}
|
||||||
|
#colorpicker #preview_wrapper { text-align:center; padding-top:4px; white-space: nowrap}
|
||||||
#colorpicker #colors {float:left; border:1px solid gray; cursor:crosshair;}
|
#colorpicker #colors {float:left; border:1px solid gray; cursor:crosshair;}
|
||||||
#colorpicker #light {border:1px solid gray; margin-left:5px; float:left;width:15px; height:150px; cursor:crosshair;}
|
#colorpicker #light {border:1px solid gray; margin-left:5px; float:left;width:15px; height:150px; cursor:crosshair;}
|
||||||
#colorpicker #light div {overflow:hidden;}
|
#colorpicker #light div {overflow:hidden;}
|
||||||
#colorpicker #previewblock {float:right; padding-left:10px; height:20px;}
|
|
||||||
#colorpicker .panel_wrapper div.current {height:175px;}
|
#colorpicker .panel_wrapper div.current {height:175px;}
|
||||||
#colorpicker #namedcolors {width:150px;}
|
#colorpicker #namedcolors {width:150px;}
|
||||||
#colorpicker #namedcolors a {display:block; float:left; width:10px; height:10px; margin:1px 1px 0 0; overflow:hidden;}
|
#colorpicker #namedcolors a {display:block; float:left; width:10px; height:10px; margin:1px 1px 0 0; overflow:hidden;}
|
||||||
|
@ -86,7 +86,7 @@
|
|||||||
.o2k7Skin .mce_forecolor span.mceAction, .o2k7Skin .mce_backcolor span.mceAction {height:15px;overflow:hidden}
|
.o2k7Skin .mce_forecolor span.mceAction, .o2k7Skin .mce_backcolor span.mceAction {height:15px;overflow:hidden}
|
||||||
|
|
||||||
/* Menu */
|
/* Menu */
|
||||||
.o2k7Skin .mceMenu {position:absolute; left:0; top:0; z-index:1000; border:1px solid #ABC6DD}
|
.o2k7Skin .mceMenu {position:absolute; left:0; top:0; z-index:1000; border:1px solid #ABC6DD; direction:ltr}
|
||||||
.o2k7Skin .mceNoIcons span.mceIcon {width:0;}
|
.o2k7Skin .mceNoIcons span.mceIcon {width:0;}
|
||||||
.o2k7Skin .mceNoIcons a .mceText {padding-left:10px}
|
.o2k7Skin .mceNoIcons a .mceText {padding-left:10px}
|
||||||
.o2k7Skin .mceMenu table {background:#FFF}
|
.o2k7Skin .mceMenu table {background:#FFF}
|
||||||
@ -112,6 +112,10 @@
|
|||||||
.o2k7Skin .mceBlocker {position:absolute; left:0; top:0; z-index:1000; opacity:0.5; -ms-filter:'alpha(opacity=30)'; filter:alpha(opacity=50); background:#FFF}
|
.o2k7Skin .mceBlocker {position:absolute; left:0; top:0; z-index:1000; opacity:0.5; -ms-filter:'alpha(opacity=30)'; filter:alpha(opacity=50); background:#FFF}
|
||||||
.o2k7Skin .mceProgress {position:absolute; left:0; top:0; z-index:1001; background:url(../default/img/progress.gif) no-repeat; width:32px; height:32px; margin:-16px 0 0 -16px}
|
.o2k7Skin .mceProgress {position:absolute; left:0; top:0; z-index:1001; background:url(../default/img/progress.gif) no-repeat; width:32px; height:32px; margin:-16px 0 0 -16px}
|
||||||
|
|
||||||
|
/* Rtl */
|
||||||
|
.mceRtl .mceListBox .mceText {text-align: right; padding: 0 4px 0 0}
|
||||||
|
.mceRtl .mceMenuItem .mceText {text-align: right}
|
||||||
|
|
||||||
/* Formats */
|
/* Formats */
|
||||||
.o2k7Skin .mce_formatPreview a {font-size:10px}
|
.o2k7Skin .mce_formatPreview a {font-size:10px}
|
||||||
.o2k7Skin .mce_p span.mceText {}
|
.o2k7Skin .mce_p span.mceText {}
|
||||||
@ -215,3 +219,4 @@
|
|||||||
.o2k7Skin span.mce_pagebreak {background-position:0 -40px}
|
.o2k7Skin span.mce_pagebreak {background-position:0 -40px}
|
||||||
.o2k7Skin span.mce_restoredraft {background-position:-20px -40px}
|
.o2k7Skin span.mce_restoredraft {background-position:-20px -40px}
|
||||||
.o2k7Skin span.mce_spellchecker {background-position:-540px -20px}
|
.o2k7Skin span.mce_spellchecker {background-position:-540px -20px}
|
||||||
|
.o2k7Skin span.mce_visualblocks {background-position: -40px -40px}
|
||||||
|
@ -109,7 +109,9 @@ h3 {font-size:14px;}
|
|||||||
#plugintable, #about #plugintable td {border:1px solid #919B9C;}
|
#plugintable, #about #plugintable td {border:1px solid #919B9C;}
|
||||||
#plugintable {width:96%; margin-top:10px;}
|
#plugintable {width:96%; margin-top:10px;}
|
||||||
#pluginscontainer {height:290px; overflow:auto;}
|
#pluginscontainer {height:290px; overflow:auto;}
|
||||||
#colorpicker #preview {float:right; width:50px; height:14px;line-height:1px; border:1px solid black; margin-left:5px;}
|
#colorpicker #preview {display:inline-block; padding-left:40px; height:14px; border:1px solid black; margin-left:5px; margin-right: 5px}
|
||||||
|
#colorpicker #previewblock {position: relative; top: -3px; padding-left:5px; padding-top: 0px; display:inline}
|
||||||
|
#colorpicker #preview_wrapper { text-align:center; padding-top:4px; white-space: nowrap}
|
||||||
#colorpicker #colors {float:left; border:1px solid gray; cursor:crosshair;}
|
#colorpicker #colors {float:left; border:1px solid gray; cursor:crosshair;}
|
||||||
#colorpicker #light {border:1px solid gray; margin-left:5px; float:left;width:15px; height:150px; cursor:crosshair;}
|
#colorpicker #light {border:1px solid gray; margin-left:5px; float:left;width:15px; height:150px; cursor:crosshair;}
|
||||||
#colorpicker #light div {overflow:hidden;}
|
#colorpicker #light div {overflow:hidden;}
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||||
<head>
|
<head>
|
||||||
<title>{#advanced_dlg.code_title}</title>
|
<title>{#advanced_dlg.code_title}</title>
|
||||||
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=3541-20120705"></script>
|
||||||
<script type="text/javascript" src="js/source_editor.js?ver=349-20120314"></script>
|
<script type="text/javascript" src="js/source_editor.js?ver=3541-20120705"></script>
|
||||||
</head>
|
</head>
|
||||||
<body onresize="resizeInputs();" style="display:none; overflow:hidden;">
|
<body onresize="resizeInputs();" style="display:none; overflow:hidden;" spellcheck="false">
|
||||||
<form name="source" onsubmit="saveContent();return false;" action="#">
|
<form name="source" onsubmit="saveContent();return false;" action="#">
|
||||||
<div style="float: left" class="title"><label for="htmlSource">{#advanced_dlg.code_title}</label></div>
|
<div style="float: left" class="title"><label for="htmlSource">{#advanced_dlg.code_title}</label></div>
|
||||||
|
|
||||||
|
2
wp-includes/js/tinymce/tiny_mce.js
vendored
2
wp-includes/js/tinymce/tiny_mce.js
vendored
File diff suppressed because one or more lines are too long
2
wp-includes/js/tinymce/tiny_mce_popup.js
vendored
2
wp-includes/js/tinymce/tiny_mce_popup.js
vendored
File diff suppressed because one or more lines are too long
@ -18,7 +18,7 @@ $wp_db_version = 20596;
|
|||||||
*
|
*
|
||||||
* @global string $tinymce_version
|
* @global string $tinymce_version
|
||||||
*/
|
*/
|
||||||
$tinymce_version = '349-20805';
|
$tinymce_version = '3541-20805';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the required PHP version
|
* Holds the required PHP version
|
||||||
|
Loading…
Reference in New Issue
Block a user