Is possible to add many child but same instance in StackLayoutPanel ??

15 views
Skip to first unread message

Jero

unread,
Oct 28, 2010, 11:15:17 AM10/28/10
to Google Web Toolkit
Hello! I have the following problem .. I am using StackLayoutPanel and
when I try to add a child of the same instance of another stack will
not let me and I remove his head and child.

The question is how I can make my stack allows many children of the
same instance?

I tried to make a wrapper of the children by putting them in another
LayoutPanel, are all the heads, but it only added the last child ah
the last head.

Thank you very much!
Jero.

John LaBanca

unread,
Oct 28, 2010, 11:20:49 AM10/28/10
to google-we...@googlegroups.com
There is currently no way to put a GWT Widget into multiple places, either within the same Panel or in another Panel.  GWT widgets map to a native DOM element instance, and DOM elements cannot be attached to multiple locations on the page.  What you would need is a presenter that can map to multiple widget instances.  Then you can update the presenter, which updates all of the widgets in turn.

Thanks,
John LaBanca
jlab...@google.com



--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to google-we...@googlegroups.com.
To unsubscribe from this group, send email to google-web-tool...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.


Jero

unread,
Nov 12, 2010, 12:09:35 PM11/12/10
to Google Web Toolkit
Thank you Very muchh for yout responde John!
Greeting
Jero.

On 28 oct, 12:20, John LaBanca <jlaba...@google.com> wrote:
> There is currently no way to put a GWT Widget into multiple places, either
> within the same Panel or in another Panel.  GWT widgets map to a native DOM
> element instance, and DOM elements cannot be attached to multiple locations
> on the page.  What you would need is a presenter that can map to multiple
> widget instances.  Then you can update the presenter, which updates all of
> the widgets in turn.
>
> Thanks,
> John LaBanca
> jlaba...@google.com
>
> On Thu, Oct 28, 2010 at 11:15 AM, Jero <jero.carr...@gmail.com> wrote:
> > Hello! I have the following problem .. I am using StackLayoutPanel and
> > when I try to add a child of the same instance of another stack will
> > not let me and I remove his head and child.
>
> > The question is how I can make my stack allows many children of the
> > same instance?
>
> > I tried to make a wrapper of the children by putting them in another
> > LayoutPanel, are all the heads, but it only added the last child ah
> > the last head.
>
> > Thank you very much!
> > Jero.
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Google Web Toolkit" group.
> > To post to this group, send email to google-we...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > google-web-tool...@googlegroups.com<google-web-toolkit%2Bunsu...@googlegroups.com>
> > .
Reply all
Reply to author
Forward
0 new messages