more font size tweaks.
[citadel.git] / webcit / tiny_mce / plugins / iespell / editor_plugin_src.js
1 /**\r
2  * editor_plugin_src.js\r
3  *\r
4  * Copyright 2009, Moxiecode Systems AB\r
5  * Released under LGPL License.\r
6  *\r
7  * License: http://tinymce.moxiecode.com/license\r
8  * Contributing: http://tinymce.moxiecode.com/contributing\r
9  */\r
10 \r
11 (function() {\r
12         tinymce.create('tinymce.plugins.IESpell', {\r
13                 init : function(ed, url) {\r
14                         var t = this, sp;\r
15 \r
16                         if (!tinymce.isIE)\r
17                                 return;\r
18 \r
19                         t.editor = ed;\r
20 \r
21                         // Register commands\r
22                         ed.addCommand('mceIESpell', function() {\r
23                                 try {\r
24                                         sp = new ActiveXObject("ieSpell.ieSpellExtension");\r
25                                         sp.CheckDocumentNode(ed.getDoc().documentElement);\r
26                                 } catch (e) {\r
27                                         if (e.number == -2146827859) {\r
28                                                 ed.windowManager.confirm(ed.getLang("iespell.download"), function(s) {\r
29                                                         if (s)\r
30                                                                 window.open('http://www.iespell.com/download.php', 'ieSpellDownload', '');\r
31                                                 });\r
32                                         } else\r
33                                                 ed.windowManager.alert("Error Loading ieSpell: Exception " + e.number);\r
34                                 }\r
35                         });\r
36 \r
37                         // Register buttons\r
38                         ed.addButton('iespell', {title : 'iespell.iespell_desc', cmd : 'mceIESpell'});\r
39                 },\r
40 \r
41                 getInfo : function() {\r
42                         return {\r
43                                 longname : 'IESpell (IE Only)',\r
44                                 author : 'Moxiecode Systems AB',\r
45                                 authorurl : 'http://tinymce.moxiecode.com',\r
46                                 infourl : 'http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/iespell',\r
47                                 version : tinymce.majorVersion + "." + tinymce.minorVersion\r
48                         };\r
49                 }\r
50         });\r
51 \r
52         // Register plugin\r
53         tinymce.PluginManager.add('iespell', tinymce.plugins.IESpell);\r
54 })();