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