Revision 5081,
957 bytes
checked in by airton, 13 years ago
(diff) |
Ticket #2086 - Troca do atual editor de emails do expresso - Adicionando a biblioteca ckeditor
|
-
Property svn:executable set to
*
|
Line | |
---|
1 | /**
|
---|
2 | * Aspell plug-in for CKeditor 3.0
|
---|
3 | * Ported from FCKeditor 2.x by Christian Boisjoli, SilenceIT
|
---|
4 | * Requires toolbar, aspell
|
---|
5 | */
|
---|
6 |
|
---|
7 | CKEDITOR.plugins.add('aspell', {
|
---|
8 | init: function (editor) {
|
---|
9 | // Create dialog-based command named "aspell"
|
---|
10 | editor.addCommand('aspell', new CKEDITOR.dialogCommand('aspell'));
|
---|
11 |
|
---|
12 | // Add button to toolbar. Not sure why only that name works for me.
|
---|
13 | editor.ui.addButton('SpellCheck', {
|
---|
14 | label: editor.lang.spellCheck.toolbar,
|
---|
15 | command: 'aspell'
|
---|
16 | });
|
---|
17 |
|
---|
18 | // Add link dialog code
|
---|
19 | CKEDITOR.dialog.add('aspell', this.path + 'dialogs/aspell.js');
|
---|
20 |
|
---|
21 | // Add CSS
|
---|
22 | var aspellCSS = document.createElement('link');
|
---|
23 | aspellCSS.setAttribute( 'rel', 'stylesheet');
|
---|
24 | aspellCSS.setAttribute('type', 'text/css');
|
---|
25 | aspellCSS.setAttribute('href', this.path+'aspell.css');
|
---|
26 | document.getElementsByTagName("head")[0].appendChild(aspellCSS);
|
---|
27 | delete aspellCSS;
|
---|
28 | },
|
---|
29 | requires: ['toolbar']
|
---|
30 | });
|
---|
31 |
|
---|
Note: See
TracBrowser
for help on using the repository browser.