Hybrid View
-
19 Feb 2009 10:08 AM #1
[workaround] Is there a way to specify a tabIndex in the HtmlEditor?
[workaround] Is there a way to specify a tabIndex in the HtmlEditor?
Setting the tabIndex in the config doesn't do anything, but I thought I'd give it a try. Also, setting the tabindex attribute on the textarea on render isn't working either. Anyone have ideas? Do I have to listen for the tab key and focus the iframe? Here's what I have so far:
Code:this.htmlEditorComments = new Ext.form.HtmlEditor({ fieldLabel:'Comment', name: 'entry_html', hideMode: 'display', tabIndex: 13, autoMonitorDesignMode: false, width: 575, height: 70 }); this.htmlEditorComments.on("render",function(editor){ var wrap = Ext.get(editor.el.dom.parentNode) var tbar = wrap.select('.x-html-editor-tb'); var textarea = wrap.select('.x-form-textarea').elements[0]; textarea.setAttribute('tabindex',13); // console.log(textarea); tbar.elements[0].style.display = "none"; },this);
-
19 Feb 2009 2:26 PM #2
No solutions? Still am not able to get this working.

-
19 Feb 2009 2:32 PM #3
Please don't bump your threads every 4 hours. You'll get an answer if/when someone reads this and has something to say.
Tim Ryan
Read BEFORE posting a question / BEFORE posting a Bug
Use Google to Search - API / Forum
API Doc (4.x | 3.x | 2.x | 1.x) / FAQ / 1.x->2.x Migration Guide / 2.x->3.x Migration Guide
-
20 Feb 2009 9:07 AM #4
Workaround...
on the field before the editor, do this:
The setTimeout has to be there in order for the tab to momentarily focus the next field in the tab order & then the htmlEditor is focused after that's happened. I guess if the HtmlEditor is the first field, you listen for the tab key and focus it that way.Code:listeners:{ blur: function() { var self=this; setTimeout(function(){ self.htmlEditorObj.focus() },10);}, scope:this }
Would tabIndex not working for the HtmlEditor object be considered a bug?


Reply With Quote