summaryrefslogtreecommitdiff
path: root/lib/grappelli/media/tinymce/jscripts/tiny_mce/plugins/emotions/js
diff options
context:
space:
mode:
authorluxagraf <sng@luxagraf.net>2010-10-23 19:46:20 -0400
committerluxagraf <sng@luxagraf.net>2010-10-23 19:46:20 -0400
commitc59a2a69fb38b92b6c45bcf7431d2b1a3c5dce3c (patch)
tree2fc44ca867839d5e591e21467b6e4526f7a9f080 /lib/grappelli/media/tinymce/jscripts/tiny_mce/plugins/emotions/js
parented77da873e675f02f12cbab9be27f342f825444b (diff)
added grappelli, filebrowser, chunks and tagging to lcal repo
Diffstat (limited to 'lib/grappelli/media/tinymce/jscripts/tiny_mce/plugins/emotions/js')
-rw-r--r--lib/grappelli/media/tinymce/jscripts/tiny_mce/plugins/emotions/js/emotions.js22
1 files changed, 22 insertions, 0 deletions
diff --git a/lib/grappelli/media/tinymce/jscripts/tiny_mce/plugins/emotions/js/emotions.js b/lib/grappelli/media/tinymce/jscripts/tiny_mce/plugins/emotions/js/emotions.js
new file mode 100644
index 0000000..c549367
--- /dev/null
+++ b/lib/grappelli/media/tinymce/jscripts/tiny_mce/plugins/emotions/js/emotions.js
@@ -0,0 +1,22 @@
+tinyMCEPopup.requireLangPack();
+
+var EmotionsDialog = {
+ init : function(ed) {
+ tinyMCEPopup.resizeToInnerSize();
+ },
+
+ insert : function(file, title) {
+ var ed = tinyMCEPopup.editor, dom = ed.dom;
+
+ tinyMCEPopup.execCommand('mceInsertContent', false, dom.createHTML('img', {
+ src : tinyMCEPopup.getWindowArg('plugin_url') + '/img/' + file,
+ alt : ed.getLang(title),
+ title : ed.getLang(title),
+ border : 0
+ }));
+
+ tinyMCEPopup.close();
+ }
+};
+
+tinyMCEPopup.onInit.add(EmotionsDialog.init, EmotionsDialog);