Why does GWT RichTextArea implement HasInitializeHandlers?
... and what should I do with the RichTextArea after the onInitialize method has been called, which I cannot do before?
NB This is a cross-post from the Google GWT group that did not respond.
a source to share
An is InitializeEvent
launched immediately after the widget is attached to it parent. Code that depends on the widget attached to it, and therefore the DOM should not be executed until then. The widget RichTextArea
uses iframe
, and this seems to be the reason that some functions are only available after creation, also depending on the specific browser. I don't have a complete list of all the specific cases where you need to initialize your code after attaching a widget. But one widget specific example RichTextArea
is when you want to set focus on the widget that the widget should be attached to.
You can get the same behavior by extending the widget RichTextArea
and overriding the method onLoad
, but this requires creating a new class.
a source to share