1 /* Import plugin specific language pack */
2 tinyMCE.importPluginLanguagePack('emotions', 'en,sv,zh_cn,cs,fa,fr_ca,fr,de,pl,pt_br,nl,da,he,no,hu');
4 function TinyMCE_emotions_getInfo() {
7 author : 'Moxiecode Systems',
8 authorurl : 'http://tinymce.moxiecode.com',
9 infourl : 'http://tinymce.moxiecode.com/tinymce/docs/plugin_emotions.html',
10 version : tinyMCE.majorVersion + "." + tinyMCE.minorVersion
15 * Returns the HTML contents of the emotions control.
17 function TinyMCE_emotions_getControlHTML(control_name) {
18 switch (control_name) {
20 return '<a href="javascript:tinyMCE.execInstanceCommand(\'{$editor_id}\',\'mceEmotion\');" target="_self" onmousedown="return false;"><img id="{$editor_id}_emotions" src="{$pluginurl}/images/emotions.gif" title="{$lang_emotions_desc}" width="20" height="20" class="mceButtonNormal" onmouseover="tinyMCE.switchClass(this,\'mceButtonOver\');" onmouseout="tinyMCE.restoreClass(this);" onmousedown="tinyMCE.restoreAndSwitchClass(this,\'mceButtonDown\');" /></a>';
27 * Executes the mceEmotion command.
29 function TinyMCE_emotions_execCommand(editor_id, element, command, user_interface, value) {
33 var template = new Array();
35 template['file'] = '../../plugins/emotions/emotions.htm'; // Relative to theme
36 template['width'] = 160;
37 template['height'] = 160;
39 // Language specific width and height addons
40 template['width'] += tinyMCE.getLang('lang_emotions_delta_width', 0);
41 template['height'] += tinyMCE.getLang('lang_emotions_delta_height', 0);
43 tinyMCE.openWindow(template, {editor_id : editor_id, inline : "yes"});
48 // Pass to next handler in chain