Upgrade TinyMCE to v3.4.5
[citadel.git] / webcit / tiny_mce / plugins / xhtmlxtras / editor_plugin_src.js
index bef06f2d24e7abbda3a07d21b38c52e68dafdcf7..f24057211c4ce2059912fec74c80bd3835914349 100644 (file)
@@ -1,8 +1,11 @@
 /**\r
- * $Id: editor_plugin_src.js 201 2007-02-12 15:56:56Z spocke $\r
+ * editor_plugin_src.js\r
  *\r
- * @author Moxiecode\r
- * @copyright Copyright © 2004-2008, Moxiecode Systems AB, All rights reserved.\r
+ * Copyright 2009, Moxiecode Systems AB\r
+ * Released under LGPL License.\r
+ *\r
+ * License: http://tinymce.moxiecode.com/license\r
+ * Contributing: http://tinymce.moxiecode.com/contributing\r
  */\r
 \r
 (function() {\r
@@ -24,7 +27,7 @@
                                ed.windowManager.open({\r
                                        file : url + '/acronym.htm',\r
                                        width : 350 + parseInt(ed.getLang('xhtmlxtras.acronym_delta_width', 0)),\r
-                                       height : 250 + parseInt(ed.getLang('xhtmlxtras.acronym_delta_width', 0)),\r
+                                       height : 250 + parseInt(ed.getLang('xhtmlxtras.acronym_delta_height', 0)),\r
                                        inline : 1\r
                                }, {\r
                                        plugin_url : url\r
@@ -35,7 +38,7 @@
                                ed.windowManager.open({\r
                                        file : url + '/abbr.htm',\r
                                        width : 350 + parseInt(ed.getLang('xhtmlxtras.abbr_delta_width', 0)),\r
-                                       height : 250 + parseInt(ed.getLang('xhtmlxtras.abbr_delta_width', 0)),\r
+                                       height : 250 + parseInt(ed.getLang('xhtmlxtras.abbr_delta_height', 0)),\r
                                        inline : 1\r
                                }, {\r
                                        plugin_url : url\r
@@ -46,7 +49,7 @@
                                ed.windowManager.open({\r
                                        file : url + '/del.htm',\r
                                        width : 340 + parseInt(ed.getLang('xhtmlxtras.del_delta_width', 0)),\r
-                                       height : 310 + parseInt(ed.getLang('xhtmlxtras.del_delta_width', 0)),\r
+                                       height : 310 + parseInt(ed.getLang('xhtmlxtras.del_delta_height', 0)),\r
                                        inline : 1\r
                                }, {\r
                                        plugin_url : url\r
@@ -57,7 +60,7 @@
                                ed.windowManager.open({\r
                                        file : url + '/ins.htm',\r
                                        width : 340 + parseInt(ed.getLang('xhtmlxtras.ins_delta_width', 0)),\r
-                                       height : 310 + parseInt(ed.getLang('xhtmlxtras.ins_delta_width', 0)),\r
+                                       height : 310 + parseInt(ed.getLang('xhtmlxtras.ins_delta_height', 0)),\r
                                        inline : 1\r
                                }, {\r
                                        plugin_url : url\r
@@ -67,8 +70,8 @@
                        ed.addCommand('mceAttributes', function() {\r
                                ed.windowManager.open({\r
                                        file : url + '/attributes.htm',\r
-                                       width : 380,\r
-                                       height : 370,\r
+                                       width : 380 + parseInt(ed.getLang('xhtmlxtras.attr_delta_width', 0)),\r
+                                       height : 370 + parseInt(ed.getLang('xhtmlxtras.attr_delta_height', 0)),\r
                                        inline : 1\r
                                }, {\r
                                        plugin_url : url\r
                        ed.addButton('ins', {title : 'xhtmlxtras.ins_desc', cmd : 'mceIns'});\r
                        ed.addButton('attribs', {title : 'xhtmlxtras.attribs_desc', cmd : 'mceAttributes'});\r
 \r
-                       if (tinymce.isIE) {\r
-                               function fix(ed, o) {\r
-                                       if (o.set) {\r
-                                               o.content = o.content.replace(/<abbr([^>]+)>/gi, '<html:abbr $1>');\r
-                                               o.content = o.content.replace(/<\/abbr>/gi, '</html:abbr>');\r
-                                       }\r
-                               };\r
-\r
-                               ed.onBeforeSetContent.add(fix);\r
-                               ed.onPostProcess.add(fix);\r
-                       }\r
-\r
                        ed.onNodeChange.add(function(ed, cm, n, co) {\r
                                n = ed.dom.getParent(n, 'CITE,ACRONYM,ABBR,DEL,INS');\r
 \r
                                        } while (n = n.parentNode);\r
                                }\r
                        });\r
+\r
+                       ed.onPreInit.add(function() {\r
+                               // Fixed IE issue where it can't handle these elements correctly\r
+                               ed.dom.create('abbr');\r
+                       });\r
                },\r
 \r
                getInfo : function() {\r