File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to register same event handler with two widgets?

 
Roger Larry
Greenhorn
Posts: 2
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am kind of new to GWT. As a part of learning, I tried to create a StateCityCombo widget that comprises of state and city list boxes. If I register ChangeEvent handler with each, the compiler gives an error.

Relevant code:

@UiHandler ("stateCB")
public void onChange (ChangeEvent event)
{
...
}

If I try to register ChangeEvent handler with the city list box as:

@UiHandler ("cityCB")
public void onChange (ChangeEvent event)
{
...
}

The compiler complains about duplicate declaration of onChange. How can I register same signature event handler with two different widgets?

Thanks in advance for your help.

Regards,
- Roger
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic