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('insertdatetime','cs,el,en,fr_ca,it,ko,sv,zh_cn,fa,fr,de,pl,pt_br,nl,da,he,nb,ru,ru_KOI8-R,ru_UTF-8,nn,fi,es,cy,is,pl');function TinyMCE_insertdatetime_getInfo(){return{longname:'Insert date/time',author:'Moxiecode Systems',authorurl:'http://tinymce.moxiecode.com',infourl:'http://tinymce.moxiecode.com/tinymce/docs/plugin_insertdatetime.html',version:tinyMCE.majorVersion+"."+tinyMCE.minorVersion};};function TinyMCE_insertdatetime_getControlHTML(control_name){switch(control_name){case "insertdate":var cmd='tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceInsertDate\');return false;';return '<a href="javascript:'+cmd+'" onclick="'+cmd+'" target="_self" onmousedown="return false;"><img id="{$editor_id}_insertdate" src="{$pluginurl}/images/insertdate.gif" title="{$lang_insertdate_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" /></a>';case "inserttime":var cmd='tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceInsertTime\');return false;';return '<a href="javascript:'+cmd+'" onclick="'+cmd+'" target="_self" onmousedown="return false;"><img id="{$editor_id}_inserttime" src="{$pluginurl}/images/inserttime.gif" title="{$lang_inserttime_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_insertdatetime_execCommand(editor_id,element,command,user_interface,value){function addZeros(value,len){value=""+value;if(value.length<len){for(var i=0;i<(len-value.length);i++)value="0"+value;}return value;}function getDateTime(date,format){format=tinyMCE.regexpReplace(format,"%D","%m/%d/%y");format=tinyMCE.regexpReplace(format,"%r","%I:%M:%S %p");format=tinyMCE.regexpReplace(format,"%Y",""+date.getFullYear());format=tinyMCE.regexpReplace(format,"%y",""+date.getYear());format=tinyMCE.regexpReplace(format,"%m",addZeros(date.getMonth()+1,2));format=tinyMCE.regexpReplace(format,"%d",addZeros(date.getDate(),2));format=tinyMCE.regexpReplace(format,"%H",""+addZeros(date.getHours(),2));format=tinyMCE.regexpReplace(format,"%M",""+addZeros(date.getMinutes(),2));format=tinyMCE.regexpReplace(format,"%S",""+addZeros(date.getSeconds(),2));format=tinyMCE.regexpReplace(format,"%I",""+((date.getHours()+11)%12+1));format=tinyMCE.regexpReplace(format,"%p",""+(date.getHours()<12?"AM":"PM"));format=tinyMCE.regexpReplace(format,"%B",""+tinyMCE.getLang("lang_inserttime_months_long")[date.getMonth()]);format=tinyMCE.regexpReplace(format,"%b",""+tinyMCE.getLang("lang_inserttime_months_short")[date.getMonth()]);format=tinyMCE.regexpReplace(format,"%A",""+tinyMCE.getLang("lang_inserttime_day_long")[date.getDay()]);format=tinyMCE.regexpReplace(format,"%a",""+tinyMCE.getLang("lang_inserttime_day_short")[date.getDay()]);format=tinyMCE.regexpReplace(format,"%%","%");return format;}switch(command){case "mceInsertDate":tinyMCE.execInstanceCommand(editor_id,'mceInsertContent',false,getDateTime(new Date(),tinyMCE.getParam("plugin_insertdate_dateFormat",tinyMCE.getLang('lang_insertdate_def_fmt'))));return true;case "mceInsertTime":tinyMCE.execInstanceCommand(editor_id,'mceInsertContent',false,getDateTime(new Date(),tinyMCE.getParam("plugin_insertdate_timeFormat",tinyMCE.getLang('lang_inserttime_def_fmt'))));return true;}return false;}
|
||||
tinyMCE.importPluginLanguagePack('insertdatetime','en,tr,cs,el,fr_ca,it,ko,sv,zh_cn,fa,fr,de,pl,pt_br,nl,da,he,nb,ru,ru_KOI8-R,ru_UTF-8,nn,fi,es,cy,is,pl');var TinyMCE_InsertDateTimePlugin={getInfo:function(){return{longname:'Insert date/time',author:'Moxiecode Systems',authorurl:'http://tinymce.moxiecode.com',infourl:'http://tinymce.moxiecode.com/tinymce/docs/plugin_insertdatetime.html',version:tinyMCE.majorVersion+"."+tinyMCE.minorVersion};},getControlHTML:function(cn){switch(cn){case"insertdate":return tinyMCE.getButtonHTML(cn,'lang_insertdate_desc','{$pluginurl}/images/insertdate.gif','mceInsertDate');case"inserttime":return tinyMCE.getButtonHTML(cn,'lang_inserttime_desc','{$pluginurl}/images/inserttime.gif','mceInsertTime');}return"";},execCommand:function(editor_id,element,command,user_interface,value){function addZeros(value,len){value=""+value;if(value.length<len){for(var i=0;i<(len-value.length);i++)value="0"+value;}return value;}function getDateTime(date,format){format=tinyMCE.regexpReplace(format,"%D","%m/%d/%y");format=tinyMCE.regexpReplace(format,"%r","%I:%M:%S %p");format=tinyMCE.regexpReplace(format,"%Y",""+date.getFullYear());format=tinyMCE.regexpReplace(format,"%y",""+date.getYear());format=tinyMCE.regexpReplace(format,"%m",addZeros(date.getMonth()+1,2));format=tinyMCE.regexpReplace(format,"%d",addZeros(date.getDate(),2));format=tinyMCE.regexpReplace(format,"%H",""+addZeros(date.getHours(),2));format=tinyMCE.regexpReplace(format,"%M",""+addZeros(date.getMinutes(),2));format=tinyMCE.regexpReplace(format,"%S",""+addZeros(date.getSeconds(),2));format=tinyMCE.regexpReplace(format,"%I",""+((date.getHours()+11)%12+1));format=tinyMCE.regexpReplace(format,"%p",""+(date.getHours()<12?"AM":"PM"));format=tinyMCE.regexpReplace(format,"%B",""+tinyMCE.getLang("lang_inserttime_months_long")[date.getMonth()]);format=tinyMCE.regexpReplace(format,"%b",""+tinyMCE.getLang("lang_inserttime_months_short")[date.getMonth()]);format=tinyMCE.regexpReplace(format,"%A",""+tinyMCE.getLang("lang_inserttime_day_long")[date.getDay()]);format=tinyMCE.regexpReplace(format,"%a",""+tinyMCE.getLang("lang_inserttime_day_short")[date.getDay()]);format=tinyMCE.regexpReplace(format,"%%","%");return format;}switch(command){case"mceInsertDate":tinyMCE.execInstanceCommand(editor_id,'mceInsertContent',false,getDateTime(new Date(),tinyMCE.getParam("plugin_insertdate_dateFormat",tinyMCE.getLang('lang_insertdate_def_fmt'))));return true;case"mceInsertTime":tinyMCE.execInstanceCommand(editor_id,'mceInsertContent',false,getDateTime(new Date(),tinyMCE.getParam("plugin_insertdate_timeFormat",tinyMCE.getLang('lang_inserttime_def_fmt'))));return true;}return false;}};tinyMCE.addPlugin("insertdatetime",TinyMCE_InsertDateTimePlugin);
|
||||
|
|
@ -1,82 +1,93 @@
|
|||
/**
|
||||
* $RCSfile: editor_plugin_src.js,v $
|
||||
* $Revision: 1.22 $
|
||||
* $Date: 2006/02/10 16:29:39 $
|
||||
*
|
||||
* @author Moxiecode
|
||||
* @copyright Copyright © 2004-2006, Moxiecode Systems AB, All rights reserved.
|
||||
*/
|
||||
|
||||
/* Import plugin specific language pack */
|
||||
tinyMCE.importPluginLanguagePack('insertdatetime', 'cs,el,en,fr_ca,it,ko,sv,zh_cn,fa,fr,de,pl,pt_br,nl,da,he,nb,ru,ru_KOI8-R,ru_UTF-8,nn,fi,es,cy,is,pl');
|
||||
tinyMCE.importPluginLanguagePack('insertdatetime', 'en,tr,cs,el,fr_ca,it,ko,sv,zh_cn,fa,fr,de,pl,pt_br,nl,da,he,nb,ru,ru_KOI8-R,ru_UTF-8,nn,fi,es,cy,is,pl');
|
||||
|
||||
function TinyMCE_insertdatetime_getInfo() {
|
||||
return {
|
||||
longname : 'Insert date/time',
|
||||
author : 'Moxiecode Systems',
|
||||
authorurl : 'http://tinymce.moxiecode.com',
|
||||
infourl : 'http://tinymce.moxiecode.com/tinymce/docs/plugin_insertdatetime.html',
|
||||
version : tinyMCE.majorVersion + "." + tinyMCE.minorVersion
|
||||
};
|
||||
};
|
||||
var TinyMCE_InsertDateTimePlugin = {
|
||||
getInfo : function() {
|
||||
return {
|
||||
longname : 'Insert date/time',
|
||||
author : 'Moxiecode Systems',
|
||||
authorurl : 'http://tinymce.moxiecode.com',
|
||||
infourl : 'http://tinymce.moxiecode.com/tinymce/docs/plugin_insertdatetime.html',
|
||||
version : tinyMCE.majorVersion + "." + tinyMCE.minorVersion
|
||||
};
|
||||
},
|
||||
|
||||
/**
|
||||
* Returns the HTML contents of the insertdate, inserttime controls.
|
||||
*/
|
||||
function TinyMCE_insertdatetime_getControlHTML(control_name) {
|
||||
switch (control_name) {
|
||||
case "insertdate":
|
||||
var cmd = 'tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceInsertDate\');return false;';
|
||||
return '<a href="javascript:' + cmd + '" onclick="' + cmd + '" target="_self" onmousedown="return false;"><img id="{$editor_id}_insertdate" src="{$pluginurl}/images/insertdate.gif" title="{$lang_insertdate_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" /></a>';
|
||||
/**
|
||||
* Returns the HTML contents of the insertdate, inserttime controls.
|
||||
*/
|
||||
getControlHTML : function(cn) {
|
||||
switch (cn) {
|
||||
case "insertdate":
|
||||
return tinyMCE.getButtonHTML(cn, 'lang_insertdate_desc', '{$pluginurl}/images/insertdate.gif', 'mceInsertDate');
|
||||
|
||||
case "inserttime":
|
||||
var cmd = 'tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceInsertTime\');return false;';
|
||||
return '<a href="javascript:' + cmd + '" onclick="' + cmd + '" target="_self" onmousedown="return false;"><img id="{$editor_id}_inserttime" src="{$pluginurl}/images/inserttime.gif" title="{$lang_inserttime_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" /></a>';
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* Executes the mceInsertDate command.
|
||||
*/
|
||||
function TinyMCE_insertdatetime_execCommand(editor_id, element, command, user_interface, value) {
|
||||
/* Adds zeros infront of value */
|
||||
function addZeros(value, len) {
|
||||
value = "" + value;
|
||||
|
||||
if (value.length < len) {
|
||||
for (var i=0; i<(len-value.length); i++)
|
||||
value = "0" + value;
|
||||
case "inserttime":
|
||||
return tinyMCE.getButtonHTML(cn, 'lang_inserttime_desc', '{$pluginurl}/images/inserttime.gif', 'mceInsertTime');
|
||||
}
|
||||
|
||||
return value;
|
||||
return "";
|
||||
},
|
||||
|
||||
/**
|
||||
* Executes the mceInsertDate command.
|
||||
*/
|
||||
execCommand : function(editor_id, element, command, user_interface, value) {
|
||||
/* Adds zeros infront of value */
|
||||
function addZeros(value, len) {
|
||||
value = "" + value;
|
||||
|
||||
if (value.length < len) {
|
||||
for (var i=0; i<(len-value.length); i++)
|
||||
value = "0" + value;
|
||||
}
|
||||
|
||||
return value;
|
||||
}
|
||||
|
||||
/* Returns the date object in the specified format */
|
||||
function getDateTime(date, format) {
|
||||
format = tinyMCE.regexpReplace(format, "%D", "%m/%d/%y");
|
||||
format = tinyMCE.regexpReplace(format, "%r", "%I:%M:%S %p");
|
||||
format = tinyMCE.regexpReplace(format, "%Y", "" + date.getFullYear());
|
||||
format = tinyMCE.regexpReplace(format, "%y", "" + date.getYear());
|
||||
format = tinyMCE.regexpReplace(format, "%m", addZeros(date.getMonth()+1, 2));
|
||||
format = tinyMCE.regexpReplace(format, "%d", addZeros(date.getDate(), 2));
|
||||
format = tinyMCE.regexpReplace(format, "%H", "" + addZeros(date.getHours(), 2));
|
||||
format = tinyMCE.regexpReplace(format, "%M", "" + addZeros(date.getMinutes(), 2));
|
||||
format = tinyMCE.regexpReplace(format, "%S", "" + addZeros(date.getSeconds(), 2));
|
||||
format = tinyMCE.regexpReplace(format, "%I", "" + ((date.getHours() + 11) % 12 + 1));
|
||||
format = tinyMCE.regexpReplace(format, "%p", "" + (date.getHours() < 12 ? "AM" : "PM"));
|
||||
format = tinyMCE.regexpReplace(format, "%B", "" + tinyMCE.getLang("lang_inserttime_months_long")[date.getMonth()]);
|
||||
format = tinyMCE.regexpReplace(format, "%b", "" + tinyMCE.getLang("lang_inserttime_months_short")[date.getMonth()]);
|
||||
format = tinyMCE.regexpReplace(format, "%A", "" + tinyMCE.getLang("lang_inserttime_day_long")[date.getDay()]);
|
||||
format = tinyMCE.regexpReplace(format, "%a", "" + tinyMCE.getLang("lang_inserttime_day_short")[date.getDay()]);
|
||||
format = tinyMCE.regexpReplace(format, "%%", "%");
|
||||
|
||||
return format;
|
||||
}
|
||||
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mceInsertDate":
|
||||
tinyMCE.execInstanceCommand(editor_id, 'mceInsertContent', false, getDateTime(new Date(), tinyMCE.getParam("plugin_insertdate_dateFormat", tinyMCE.getLang('lang_insertdate_def_fmt'))));
|
||||
return true;
|
||||
|
||||
case "mceInsertTime":
|
||||
tinyMCE.execInstanceCommand(editor_id, 'mceInsertContent', false, getDateTime(new Date(), tinyMCE.getParam("plugin_insertdate_timeFormat", tinyMCE.getLang('lang_inserttime_def_fmt'))));
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
||||
};
|
||||
|
||||
/* Returns the date object in the specified format */
|
||||
function getDateTime(date, format) {
|
||||
format = tinyMCE.regexpReplace(format, "%D", "%m/%d/%y");
|
||||
format = tinyMCE.regexpReplace(format, "%r", "%I:%M:%S %p");
|
||||
format = tinyMCE.regexpReplace(format, "%Y", "" + date.getFullYear());
|
||||
format = tinyMCE.regexpReplace(format, "%y", "" + date.getYear());
|
||||
format = tinyMCE.regexpReplace(format, "%m", addZeros(date.getMonth()+1, 2));
|
||||
format = tinyMCE.regexpReplace(format, "%d", addZeros(date.getDate(), 2));
|
||||
format = tinyMCE.regexpReplace(format, "%H", "" + addZeros(date.getHours(), 2));
|
||||
format = tinyMCE.regexpReplace(format, "%M", "" + addZeros(date.getMinutes(), 2));
|
||||
format = tinyMCE.regexpReplace(format, "%S", "" + addZeros(date.getSeconds(), 2));
|
||||
format = tinyMCE.regexpReplace(format, "%I", "" + ((date.getHours() + 11) % 12 + 1));
|
||||
format = tinyMCE.regexpReplace(format, "%p", "" + (date.getHours() < 12 ? "AM" : "PM"));
|
||||
format = tinyMCE.regexpReplace(format, "%B", "" + tinyMCE.getLang("lang_inserttime_months_long")[date.getMonth()]);
|
||||
format = tinyMCE.regexpReplace(format, "%b", "" + tinyMCE.getLang("lang_inserttime_months_short")[date.getMonth()]);
|
||||
format = tinyMCE.regexpReplace(format, "%A", "" + tinyMCE.getLang("lang_inserttime_day_long")[date.getDay()]);
|
||||
format = tinyMCE.regexpReplace(format, "%a", "" + tinyMCE.getLang("lang_inserttime_day_short")[date.getDay()]);
|
||||
format = tinyMCE.regexpReplace(format, "%%", "%");
|
||||
|
||||
return format;
|
||||
}
|
||||
|
||||
// Handle commands
|
||||
switch (command) {
|
||||
case "mceInsertDate":
|
||||
tinyMCE.execInstanceCommand(editor_id, 'mceInsertContent', false, getDateTime(new Date(), tinyMCE.getParam("plugin_insertdate_dateFormat", tinyMCE.getLang('lang_insertdate_def_fmt'))));
|
||||
return true;
|
||||
|
||||
case "mceInsertTime":
|
||||
tinyMCE.execInstanceCommand(editor_id, 'mceInsertContent', false, getDateTime(new Date(), tinyMCE.getParam("plugin_insertdate_timeFormat", tinyMCE.getLang('lang_inserttime_def_fmt'))));
|
||||
return true;
|
||||
}
|
||||
|
||||
// Pass to next handler in chain
|
||||
return false;
|
||||
}
|
||||
tinyMCE.addPlugin("insertdatetime", TinyMCE_InsertDateTimePlugin);
|
||||
|
|
|
|||
|
|
@ -2,12 +2,12 @@
|
|||
* Czech lang variables
|
||||
* encoding: utf-8
|
||||
*
|
||||
* $Id: cs.js,v 1.5 2005/10/18 13:59:43 spocke Exp $
|
||||
* $Id: cs.js,v 1.6 2006/01/11 14:25:49 spocke Exp $
|
||||
*/
|
||||
|
||||
tinyMCE.addToLang('',{
|
||||
insertdate_def_fmt : '%Y-%m-%d',
|
||||
inserttime_def_fmt : '%H:%M:%S',
|
||||
insertdate_def_fmt : '%d.%m.%Y',
|
||||
inserttime_def_fmt : '%H:%M',
|
||||
insertdate_desc : 'Vložit datum',
|
||||
inserttime_desc : 'Vložit čas',
|
||||
inserttime_months_long : new Array('Leden','Únor','Březen','Duben','Květen','Červen','Červenec','Srpen','Září','Říjen','Listopad','Prosinec'),
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
// DK lang variables contributed by Jan Moelgaard
|
||||
// DK lang variables contributed by Jan Moelgaard, John Dalsgaard and Bo Frederiksen.
|
||||
|
||||
tinyMCE.addToLang('',{
|
||||
insertdate_def_fmt : '%d-%m-%Y',
|
||||
inserttime_def_fmt : '%H:%M:%S',
|
||||
insertdate_desc : 'Indsæt dato',
|
||||
inserttime_desc : 'Indsæt tid',
|
||||
insertdate_desc : 'Indsæt dato',
|
||||
inserttime_desc : 'Indsæt tid',
|
||||
inserttime_months_long : new Array("Januar", "Februar", "Marts", "April", "Maj", "Juni", "Juli", "August", "September", "Oktober", "November", "December"),
|
||||
inserttime_months_short : new Array("Jan", "Feb", "Mar", "Apr", "Maj", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dec"),
|
||||
inserttime_day_long : new Array("Søndag", "Mandag", "Tirsdag", "Onsdag", "Torsdag", "Fredag", "Lørdag", "Søndag"),
|
||||
inserttime_day_short : new Array("Søn", "Man", "Tir", "Ons", "Tor", "Fre", "Lør", "Søn")
|
||||
inserttime_day_long : new Array("Søndag", "Mandag", "Tirsdag", "Onsdag", "Torsdag", "Fredag", "Lørdag", "Søndag"),
|
||||
inserttime_day_short : new Array("Søn", "Man", "Tir", "Ons", "Tor", "Fre", "Lør", "Søn")
|
||||
});
|
||||
|
|
|
|||
|
|
@ -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('',{
|
||||
insertdate_def_fmt : '%Y-%m-%d',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue