Hi matttai,

unless you have a big reason to do so, I would avoid sinking/unsinking
events etc. I would go for one of two options:

1. if the inner widget is *only* ever used by the parent (owned by
parent only), then you can make it an inner class of the parent
widget. This is convenient since you just call the parent widget
method directly from the inner widget code
(MyParentWidget.class.methodTocall(....)

2. If that is not true and the inner widget must be a separate class,
you should use the Observer pattern which GWT supports. If you are
using 1.5.x or earlier, you could use the ChangeListener and
SourcesChangeEvents interfaces for example, of if 1.6.x you should use
maybe HasValueChangeHandlers and ValueChangeHandler.

regards
gregor

On Apr 5, 3:51 am, matttai <[email protected]> wrote:
> As per the title :)
>
> How to get internal widget to notify its parent widget when clicked
> (and have the parent execute something)?
>
> I think it has something to do with sinking and unsinking events but I
> haven't been able to find a very good example of doing this.
>
> Any help would be appreciated!
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to