On Jan 4, 2007, at 3:23 AM, CHARLIER Cyril wrote:
I want to focus on a widget in the flowScript but i don't find a
setFocus() function or anything else to do it.
Browser focus is client-side. Flowscript is server-side.
When/why are you wanting to set the focus? Do you just want to
initialize it when the page loads? If so, just add some client-side
javascript to your page to do this in the usual way.
There you go Cyril, translate that! :-) :-)
=================================
As an aside... it would be a nice thing for a client-side library JS to
give the ability to do this declaratively, e.g.
<input initial-focus="true" ...>
Then we could drive that from the form template layer, e.g.
<ft:widget id="name">
<fi:styling initial-focus="true"/>
</ft:widget>
Furthermore... .I don't think we currently have a way to drive
<fi:styling> from flowscript, but it could be added:
someWidget.setStyling ('initial-focus', 'true');
Then if there were really a need to do this from flowscript (e.g.,
conditionally), we could support it directly (including from an event
handler, e.g. action button click or AJAX event change).
—ml—
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]