![]() |
focus remains on control despite focus changed
select text, click color change:
http://www-archive.mozilla.org/editor/midasdemo/ How is that done, that is, the focus is transfered elsewhere (color picker), but text still remains selected. How does that work ? Need to do the same without iframes. |
being selected and having the focus are two entirely different things.
mytext.selected() is completely different from mytext.focus() |
so, I have:
Code:
<div contentEditable ="true" ...Code:
<img src = '...' onclick = "document.execCommand('underline')" />I have span, onclick it produces js generated color picker. And at that moment (clicking) text get deselected. Way around that ? Edit: If I replace span with img, selected text is not deselected ! But unfortunately it gets deselected, selecting color in color picker. ... |
| All times are GMT +1. The time now is 02:38 AM. |
Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.