upgrading tinymce to 2.0.5.1
This commit is contained in:
parent
cb2a8d025e
commit
00d46f6148
342 changed files with 13043 additions and 11487 deletions
|
|
@ -1 +1 @@
|
|||
tinyMCE.importPluginLanguagePack('directionality','en,sv,fr_ca,zh_cn,cs,da,he,nb,de,hu,ru,ru_KOI8-R,ru_UTF-8,nn,es,cy,is,pl,nl,fr,pt_br');function TinyMCE_directionality_getInfo(){return{longname:'Directionality',author:'Moxiecode Systems',authorurl:'http://tinymce.moxiecode.com',infourl:'http://tinymce.moxiecode.com/tinymce/docs/plugin_directionality.html',version:tinyMCE.majorVersion+"."+tinyMCE.minorVersion};};function TinyMCE_directionality_getControlHTML(control_name){switch(control_name){case "ltr":var cmd='tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceDirectionLTR\');return false;';return '<a href="javascript:'+cmd+'" onclick="'+cmd+'" target="_self" onmousedown="return false;"><img id="{$editor_id}_ltr" src="{$pluginurl}/images/ltr.gif" title="{$lang_directionality_ltr_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" /></a>';case "rtl":var cmd='tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceDirectionRTL\');return false;';return '<a href="javascript:'+cmd+'" onclick="'+cmd+'" target="_self" onmousedown="return false;"><img id="{$editor_id}_rtl" src="{$pluginurl}/images/rtl.gif" title="{$lang_directionality_rtl_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" /></a>';}return "";}function TinyMCE_directionality_execCommand(editor_id,element,command,user_interface,value){switch(command){case "mceDirectionLTR":var inst=tinyMCE.getInstanceById(editor_id);var elm=tinyMCE.getParentElement(inst.getFocusElement(),"p,div,td,h1,h2,h3,h4,h5,h6,pre,address");if(elm)elm.setAttribute("dir","ltr");tinyMCE.triggerNodeChange(false);return true;case "mceDirectionRTL":var inst=tinyMCE.getInstanceById(editor_id);var elm=tinyMCE.getParentElement(inst.getFocusElement(),"p,div,td,h1,h2,h3,h4,h5,h6,pre,address");if(elm)elm.setAttribute("dir","rtl");tinyMCE.triggerNodeChange(false);return true;}return false;}function TinyMCE_directionality_handleNodeChange(editor_id,node,undo_index,undo_levels,visual_aid,any_selection){function getAttrib(elm,name){return elm.getAttribute(name)?elm.getAttribute(name):"";}tinyMCE.switchClassSticky(editor_id+'_ltr','mceButtonNormal',false);tinyMCE.switchClassSticky(editor_id+'_rtl','mceButtonNormal',false);if(node==null)return;var elm=tinyMCE.getParentElement(node,"p,div,td,h1,h2,h3,h4,h5,h6,pre,address");if(!elm){tinyMCE.switchClassSticky(editor_id+'_ltr','mceButtonDisabled',true);tinyMCE.switchClassSticky(editor_id+'_rtl','mceButtonDisabled',true);return;}var dir=getAttrib(elm,"dir");if(dir=="ltr"||dir=="")tinyMCE.switchClassSticky(editor_id+'_ltr','mceButtonSelected',false);else tinyMCE.switchClassSticky(editor_id+'_rtl','mceButtonSelected',false);return true;}
|
||||
tinyMCE.importPluginLanguagePack('directionality','en,tr,sv,fr_ca,zh_cn,cs,da,he,nb,de,hu,ru,ru_KOI8-R,ru_UTF-8,nn,es,cy,is,pl,nl,fr,pt_br');var TinyMCE_DirectionalityPlugin={getInfo:function(){return{longname:'Directionality',author:'Moxiecode Systems',authorurl:'http://tinymce.moxiecode.com',infourl:'http://tinymce.moxiecode.com/tinymce/docs/plugin_directionality.html',version:tinyMCE.majorVersion+"."+tinyMCE.minorVersion};},getControlHTML:function(cn){switch(cn){case"ltr":return tinyMCE.getButtonHTML(cn,'lang_directionality_ltr_desc','{$pluginurl}/images/ltr.gif','mceDirectionLTR');case"rtl":return tinyMCE.getButtonHTML(cn,'lang_directionality_rtl_desc','{$pluginurl}/images/rtl.gif','mceDirectionRTL');}return"";},execCommand:function(editor_id,element,command,user_interface,value){switch(command){case"mceDirectionLTR":var inst=tinyMCE.getInstanceById(editor_id);var elm=tinyMCE.getParentElement(inst.getFocusElement(),"p,div,td,h1,h2,h3,h4,h5,h6,pre,address");if(elm)elm.setAttribute("dir","ltr");tinyMCE.triggerNodeChange(false);return true;case"mceDirectionRTL":var inst=tinyMCE.getInstanceById(editor_id);var elm=tinyMCE.getParentElement(inst.getFocusElement(),"p,div,td,h1,h2,h3,h4,h5,h6,pre,address");if(elm)elm.setAttribute("dir","rtl");tinyMCE.triggerNodeChange(false);return true;}return false;},handleNodeChange:function(editor_id,node,undo_index,undo_levels,visual_aid,any_selection){function getAttrib(elm,name){return elm.getAttribute(name)?elm.getAttribute(name):"";}if(node==null)return;var elm=tinyMCE.getParentElement(node,"p,div,td,h1,h2,h3,h4,h5,h6,pre,address");if(!elm){tinyMCE.switchClass(editor_id+'_ltr','mceButtonDisabled');tinyMCE.switchClass(editor_id+'_rtl','mceButtonDisabled');return true;}tinyMCE.switchClass(editor_id+'_ltr','mceButtonNormal');tinyMCE.switchClass(editor_id+'_rtl','mceButtonNormal');var dir=getAttrib(elm,"dir");if(dir=="ltr"||dir=="")tinyMCE.switchClass(editor_id+'_ltr','mceButtonSelected');else tinyMCE.switchClass(editor_id+'_rtl','mceButtonSelected');return true;}};tinyMCE.addPlugin("directionality",TinyMCE_DirectionalityPlugin);
|
||||
|
|
@ -1,81 +1,92 @@
|
|||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('directionality', 'en,sv,fr_ca,zh_cn,cs,da,he,nb,de,hu,ru,ru_KOI8-R,ru_UTF-8,nn,es,cy,is,pl,nl,fr,pt_br');
|
||||
/**
|
||||
* $RCSfile: editor_plugin_src.js,v $
|
||||
* $Revision: 1.16 $
|
||||
* $Date: 2006/02/10 21:34:28 $
|
||||
*
|
||||
* @author Moxiecode
|
||||
* @copyright Copyright © 2004-2006, Moxiecode Systems AB, All rights reserved.
|
||||
*/
|
||||
|
||||
function TinyMCE_directionality_getInfo() {
|
||||
return {
|
||||
longname : 'Directionality',
|
||||
author : 'Moxiecode Systems',
|
||||
authorurl : 'http://tinymce.moxiecode.com',
|
||||
infourl : 'http://tinymce.moxiecode.com/tinymce/docs/plugin_directionality.html',
|
||||
version : tinyMCE.majorVersion + "." + tinyMCE.minorVersion
|
||||
};
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('directionality', 'en,tr,sv,fr_ca,zh_cn,cs,da,he,nb,de,hu,ru,ru_KOI8-R,ru_UTF-8,nn,es,cy,is,pl,nl,fr,pt_br');
|
||||
|
||||
var TinyMCE_DirectionalityPlugin = {
|
||||
getInfo : function() {
|
||||
return {
|
||||
longname : 'Directionality',
|
||||
author : 'Moxiecode Systems',
|
||||
authorurl : 'http://tinymce.moxiecode.com',
|
||||
infourl : 'http://tinymce.moxiecode.com/tinymce/docs/plugin_directionality.html',
|
||||
version : tinyMCE.majorVersion + "." + tinyMCE.minorVersion
|
||||
};
|
||||
},
|
||||
|
||||
getControlHTML : function(cn) {
|
||||
switch (cn) {
|
||||
case "ltr":
|
||||
return tinyMCE.getButtonHTML(cn, 'lang_directionality_ltr_desc', '{$pluginurl}/images/ltr.gif', 'mceDirectionLTR');
|
||||
|
||||
case "rtl":
|
||||
return tinyMCE.getButtonHTML(cn, 'lang_directionality_rtl_desc', '{$pluginurl}/images/rtl.gif', 'mceDirectionRTL');
|
||||
}
|
||||
|
||||
return "";
|
||||
},
|
||||
|
||||
execCommand : function(editor_id, element, command, user_interface, value) {
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mceDirectionLTR":
|
||||
var inst = tinyMCE.getInstanceById(editor_id);
|
||||
var elm = tinyMCE.getParentElement(inst.getFocusElement(), "p,div,td,h1,h2,h3,h4,h5,h6,pre,address");
|
||||
|
||||
if (elm)
|
||||
elm.setAttribute("dir", "ltr");
|
||||
|
||||
tinyMCE.triggerNodeChange(false);
|
||||
return true;
|
||||
|
||||
case "mceDirectionRTL":
|
||||
var inst = tinyMCE.getInstanceById(editor_id);
|
||||
var elm = tinyMCE.getParentElement(inst.getFocusElement(), "p,div,td,h1,h2,h3,h4,h5,h6,pre,address");
|
||||
|
||||
if (elm)
|
||||
elm.setAttribute("dir", "rtl");
|
||||
|
||||
tinyMCE.triggerNodeChange(false);
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
},
|
||||
|
||||
handleNodeChange : function(editor_id, node, undo_index, undo_levels, visual_aid, any_selection) {
|
||||
function getAttrib(elm, name) {
|
||||
return elm.getAttribute(name) ? elm.getAttribute(name) : "";
|
||||
}
|
||||
|
||||
if (node == null)
|
||||
return;
|
||||
|
||||
var elm = tinyMCE.getParentElement(node, "p,div,td,h1,h2,h3,h4,h5,h6,pre,address");
|
||||
if (!elm) {
|
||||
tinyMCE.switchClass(editor_id + '_ltr', 'mceButtonDisabled');
|
||||
tinyMCE.switchClass(editor_id + '_rtl', 'mceButtonDisabled');
|
||||
return true;
|
||||
}
|
||||
|
||||
tinyMCE.switchClass(editor_id + '_ltr', 'mceButtonNormal');
|
||||
tinyMCE.switchClass(editor_id + '_rtl', 'mceButtonNormal');
|
||||
|
||||
var dir = getAttrib(elm, "dir");
|
||||
if (dir == "ltr" || dir == "")
|
||||
tinyMCE.switchClass(editor_id + '_ltr', 'mceButtonSelected');
|
||||
else
|
||||
tinyMCE.switchClass(editor_id + '_rtl', 'mceButtonSelected');
|
||||
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
||||
function TinyMCE_directionality_getControlHTML(control_name) {
|
||||
switch (control_name) {
|
||||
case "ltr":
|
||||
var cmd = 'tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceDirectionLTR\');return false;';
|
||||
return '<a href="javascript:' + cmd + '" onclick="' + cmd + '" target="_self" onmousedown="return false;"><img id="{$editor_id}_ltr" src="{$pluginurl}/images/ltr.gif" title="{$lang_directionality_ltr_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" /></a>';
|
||||
|
||||
case "rtl":
|
||||
var cmd = 'tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceDirectionRTL\');return false;';
|
||||
return '<a href="javascript:' + cmd + '" onclick="' + cmd + '" target="_self" onmousedown="return false;"><img id="{$editor_id}_rtl" src="{$pluginurl}/images/rtl.gif" title="{$lang_directionality_rtl_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" /></a>';
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
function TinyMCE_directionality_execCommand(editor_id, element, command, user_interface, value) {
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mceDirectionLTR":
|
||||
var inst = tinyMCE.getInstanceById(editor_id);
|
||||
var elm = tinyMCE.getParentElement(inst.getFocusElement(), "p,div,td,h1,h2,h3,h4,h5,h6,pre,address");
|
||||
|
||||
if (elm)
|
||||
elm.setAttribute("dir", "ltr");
|
||||
|
||||
tinyMCE.triggerNodeChange(false);
|
||||
return true;
|
||||
|
||||
case "mceDirectionRTL":
|
||||
var inst = tinyMCE.getInstanceById(editor_id);
|
||||
var elm = tinyMCE.getParentElement(inst.getFocusElement(), "p,div,td,h1,h2,h3,h4,h5,h6,pre,address");
|
||||
|
||||
if (elm)
|
||||
elm.setAttribute("dir", "rtl");
|
||||
|
||||
tinyMCE.triggerNodeChange(false);
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
||||
|
||||
function TinyMCE_directionality_handleNodeChange(editor_id, node, undo_index, undo_levels, visual_aid, any_selection) {
|
||||
function getAttrib(elm, name) {
|
||||
return elm.getAttribute(name) ? elm.getAttribute(name) : "";
|
||||
}
|
||||
|
||||
tinyMCE.switchClassSticky(editor_id + '_ltr', 'mceButtonNormal', false);
|
||||
tinyMCE.switchClassSticky(editor_id + '_rtl', 'mceButtonNormal', false);
|
||||
|
||||
if (node == null)
|
||||
return;
|
||||
|
||||
var elm = tinyMCE.getParentElement(node, "p,div,td,h1,h2,h3,h4,h5,h6,pre,address");
|
||||
if (!elm) {
|
||||
tinyMCE.switchClassSticky(editor_id + '_ltr', 'mceButtonDisabled', true);
|
||||
tinyMCE.switchClassSticky(editor_id + '_rtl', 'mceButtonDisabled', true);
|
||||
return;
|
||||
}
|
||||
|
||||
var dir = getAttrib(elm, "dir");
|
||||
if (dir == "ltr" || dir == "")
|
||||
tinyMCE.switchClassSticky(editor_id + '_ltr', 'mceButtonSelected', false);
|
||||
else
|
||||
tinyMCE.switchClassSticky(editor_id + '_rtl', 'mceButtonSelected', false);
|
||||
|
||||
return true;
|
||||
}
|
||||
tinyMCE.addPlugin("directionality", TinyMCE_DirectionalityPlugin);
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
* Czech lang variables
|
||||
* encoding: utf-8
|
||||
*
|
||||
* $Id: cs.js,v 1.1 2005/10/18 13:55:41 spocke Exp $
|
||||
* $Id: cs.js,v 1.2 2006/01/11 14:25:48 spocke Exp $
|
||||
*/
|
||||
|
||||
tinyMCE.addToLang('',{
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
// DK lang variables contributed by Jan Moelgaard
|
||||
// DK lang variables contributed by Jan Moelgaard, John Dalsgaard and Bo Frederiksen.
|
||||
|
||||
tinyMCE.addToLang('',{
|
||||
directionality_ltr_desc : 'Retning - venstre mod højre',
|
||||
directionality_rtl_desc : 'Retning - højre mod venstre'
|
||||
directionality_ltr_desc : 'Retning - venstre mod højre',
|
||||
directionality_rtl_desc : 'Retning - højre mod venstre'
|
||||
});
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
// Simplified Chinese lang variables contributed by tom_cat (thomaswangyang@gmail.com)
|
||||
// Simplified Chinese lang variables contributed by TinyMCE_China_Team ( tinymce_china {AT} yahoogroups {DOT} com ).
|
||||
// visit our homepage at: http://www.cube316.net/tinymce/ for more information.
|
||||
|
||||
tinyMCE.addToLang('',{
|
||||
directionality_ltr_desc : '方向从左往右',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue