#10382 closed Bug (invalid)
CKEDITOR.currentInstance returns null on focus
Reported by: | Mandeep | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | General | Version: | 4.0.2 |
Keywords: | Cc: |
Description
I am using the inline CKEditor. I have many text boxes on the page. When I click on the text box on which the inline CKEditor is used, I get the current instance using CKEDITOR.currentInstance. But when I visit the text box by pressing tab, I get the CKEDITOR.currentInstance as null. The toolbar is displayed in both cases('click' and 'tab focus').
Change History (3)
comment:1 Changed 12 years ago by
Resolution: | → invalid |
---|---|
Status: | new → closed |
comment:2 Changed 12 years ago by
@j.swiderski I used the same approach, the only difference is that my timeout is 100ms.
Initially I was doing it without setTimeout which was not working. Then I set it to 0ms and 10ms which still gave me unpredictable results. Setting it to 100ms is working for now.
Can we achieve this without setTimeout?
comment:3 Changed 12 years ago by
Yes it can be achieved. Please see first example.
On each instance ready you can attach focus event or whatever you want.
I can't confirm this. I have tried two approaches here to attach focus event to editor in massive inline creation sample. In both cases once events have been registered they worked on click and on tab.
@Mandeep Jain I'm closing this ticket as invalid but if I have missed anything and you don't agree please let me know.