I have a code like this:
final ValueListBox<GCountry> countryList = new ValueListBox<GCountry>(new
Renderer<GCountry>() {
public String render(GCountry c) {
String s = "";
if (c != null) {
s = c.getTitleRus();
} else {
s = "Choose a country";
}
return s;
}
public void render(GCountry c, Appendable appendable) throws
IOException {
String s = render(c);
appendable.append(s);
}
});
...
countryList.addHandler(new ChangeHandler() {
@Override
public void onChange(ChangeEvent event) {
GCountry gc = countryList.getValue();
if (gc != null) {
getService().getAVCompanies(gc.getId(), null, null,
cbAvcomp);
}
}
}, ChangeEvent.getType() );
I only have a previous value (GCountry gc = countryList.getValue()) in
handler but I need a value that user choose right now
How this code can be modified?
--
You received this message because you are subscribed to the Google Groups
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.