Mercurial > public > sg101
comparison media/js/tiny_mce/plugins/tabfocus/editor_plugin_src.js @ 183:149c3567fec1
Updated to TinyMCE version 3.3.2. This is for #57.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Sun, 28 Mar 2010 21:47:48 +0000 |
parents | a5b4c5ce0658 |
children |
comparison
equal
deleted
inserted
replaced
182:5c889b587416 | 183:149c3567fec1 |
---|---|
1 /** | 1 /** |
2 * $Id: editor_plugin_src.js 787 2008-04-10 11:40:57Z spocke $ | 2 * editor_plugin_src.js |
3 * | 3 * |
4 * @author Moxiecode | 4 * Copyright 2009, Moxiecode Systems AB |
5 * @copyright Copyright © 2004-2008, Moxiecode Systems AB, All rights reserved. | 5 * Released under LGPL License. |
6 * | |
7 * License: http://tinymce.moxiecode.com/license | |
8 * Contributing: http://tinymce.moxiecode.com/contributing | |
6 */ | 9 */ |
7 | 10 |
8 (function() { | 11 (function() { |
9 var DOM = tinymce.DOM, Event = tinymce.dom.Event, each = tinymce.each, explode = tinymce.explode; | 12 var DOM = tinymce.DOM, Event = tinymce.dom.Event, each = tinymce.each, explode = tinymce.explode; |
10 | 13 |
66 else | 69 else |
67 el = DOM.get(v[1]); | 70 el = DOM.get(v[1]); |
68 } | 71 } |
69 | 72 |
70 if (el) { | 73 if (el) { |
71 if (ed = tinymce.EditorManager.get(el.id || el.name)) | 74 if (ed = tinymce.get(el.id || el.name)) |
72 ed.focus(); | 75 ed.focus(); |
73 else | 76 else |
74 window.setTimeout(function() {window.focus();el.focus();}, 10); | 77 window.setTimeout(function() {window.focus();el.focus();}, 10); |
75 | 78 |
76 return Event.cancel(e); | 79 return Event.cancel(e); |
85 ed.onKeyDown.add(tabCancel); | 88 ed.onKeyDown.add(tabCancel); |
86 } else | 89 } else |
87 ed.onKeyDown.add(tabHandler); | 90 ed.onKeyDown.add(tabHandler); |
88 | 91 |
89 ed.onInit.add(function() { | 92 ed.onInit.add(function() { |
90 each(DOM.select('a:first,a:last', tinyMCE.activeEditor.getContainer()), function(n) { | 93 each(DOM.select('a:first,a:last', ed.getContainer()), function(n) { |
91 Event.add(n, 'focus', function() {ed.focus();}); | 94 Event.add(n, 'focus', function() {ed.focus();}); |
92 }); | 95 }); |
93 }); | 96 }); |
94 }, | 97 }, |
95 | 98 |