I just created widget:
public class myWidget<T> extends FlowPanel {
private T value;
public T getValue()
{
return value;
}
public myWidget(T[] values) {
for (T value : values)
{
//do action
}
}
How can I add it using UiBinder? Is it possible at all?
Yes you can. You have to import the package which contains the
myWidgetclass into an XML namespace. Say your package is calledcom.test.widgets, the declarative layout looks like this:Note the import
xmlns:my='urn:import:com.test.widgets'and the usage<my:myWidget>.