| | |
| | | /**
|
| | | * $Id: editor_plugin_src.js 201 2007-02-12 15:56:56Z spocke $
|
| | | * editor_plugin_src.js
|
| | | *
|
| | | * @author Moxiecode
|
| | | * @copyright Copyright © 2004-2008, Moxiecode Systems AB, All rights reserved.
|
| | | * Copyright 2009, Moxiecode Systems AB
|
| | | * Released under LGPL License.
|
| | | *
|
| | | * License: http://tinymce.moxiecode.com/license
|
| | | * Contributing: http://tinymce.moxiecode.com/contributing
|
| | | */
|
| | |
|
| | | (function() {
|
| | |
| | |
|
| | | // Register commands
|
| | | ed.addCommand('mceNonBreaking', function() {
|
| | | ed.execCommand('mceInsertContent', false, (ed.plugins.visualchars && ed.plugins.visualchars.state) ? '<span class="mceItemHidden mceVisualNbsp">·</span>' : ' ');
|
| | | ed.execCommand('mceInsertContent', false, (ed.plugins.visualchars && ed.plugins.visualchars.state) ? '<span data-mce-bogus="1" class="mceItemHidden mceItemNbsp"> </span>' : ' ');
|
| | | });
|
| | |
|
| | | // Register buttons
|
| | |
| | |
|
| | | if (ed.getParam('nonbreaking_force_tab')) {
|
| | | ed.onKeyDown.add(function(ed, e) {
|
| | | if (tinymce.isIE && e.keyCode == 9) {
|
| | | if (e.keyCode == 9) {
|
| | | e.preventDefault();
|
| | | |
| | | ed.execCommand('mceNonBreaking');
|
| | | ed.execCommand('mceNonBreaking');
|
| | | ed.execCommand('mceNonBreaking');
|
| | | tinymce.dom.Event.cancel(e);
|
| | | }
|
| | | });
|
| | | }
|