I am trying to extend tree component in Vaadin. So I created client side class as:
import com.vaadin.terminal.gwt.client.ui.VTree;
public class CustomVtree extends VTree {
}
Server side class :
import com.vaadin.ui.ClientWidget;
import com.vaadin.ui.Tree;
@ClientWidget(CustomVtree.class)
public class MyTree extends Tree {
public MyTree() {
super();
}
}
And I got
[WARN] Widget class com.vaadin.sample.gwt.client.ui.CustomVtree was not found. The component com.vaadin.sample.gwt.client.ui.MyTree will not be included in the widgetset.
What did I forget to do or what I am doing wrong? Will be glad for any help. Thanks
Your classes look correct but one thing is missing: a GWT module descriptor file. Add that file to the com.vaadin.sample.gwt package and here I call it MyWidgetset.gwt.xml. The content of the file should look like the following if you don’t have any add-ons in your project:
And then you have to define in web.xml that you want to use this widgetset:
After these steps the GWT compilation should work.