plandem / lwrte

Export from Google Code. Lightweight Rich Text Editor (RTE / WYSIWYG) for jQuery
https://code.google.com/p/lwrte/
0 stars 0 forks source link

Focus autom. set to toolbar in IE8 #50

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. standard HTML page with more than one rte included by jQuery plugin
"jeditable"
2. edit one text via rte, press OK to submit -> submitted correctly
3. click another text to edit -> rte loads correctly, but focus is
somewhere in the toolbar (standard toolbar like provided in download)

What is the expected output? What do you see instead?
Expected is, that focus is set correctly to the new iframe where the text
can be edited. But it is somewhere in the toolbar ... sometimes using TAB
helps to get back focus, sometimes clicking on any button in the toolbar
helps too, but normally you have to reload the whole page to be able to use
it again.

What version of the product are you using? On what operating system?
version 1.2 of lwRTE
version 1.4.1 of jQuery
version 1.7.1 of jEditable

Please provide any additional information below.
I managed to fix this issue on my own ... but including this patch into
future versions of lwRTE would be great ...

Just insert the following line into lwRTE.prototype.enable_design_mode =
function() at the very end (after setting CSS styling off for Firefox):

self.iframe.contentWindow.focus();

That sets the focus to the iframe and that did work for me ...

Original issue reported on code.google.com by manuelju...@gmail.com on 25 Feb 2010 at 2:09