My task is to create a table with a control to add the new lines. This typical control should consist of corresponding set of TextEdits and an "add new row" Button.
I use CellTable.
I can create this "adding widget" separately just combing button and necessary fields in some panel, but I want to try to bind it to the table. I want to make it using the CellTable. For this purpose I try to utilize the header of the CellTable. I created a Header and added a EditCellText and ButtonCell. I have two problems:
- The button is not shown. Instead a value returned by getValue() method is shown.
- I dont know how to handle the click on that button.
[1] Finally, the first question is: how can you add a button into a header of CellTable and how would you process the click on that button? The button should looks like a button, not just some click area.
[2] Probably there is another way to accomplish my task. Is it possible to create CellTable where different rows hold different buttons? I.e. first row holds button "Add", and all other rows hold button "Remove". Can GWT do this?
[3] One more question. At the moment I describe the structure of my CellTable using Java code. I.e. I create and add column and header objects manually while creating the parent widget. Is it possible to express the structure of my CellTable with XML, i.e. using some mySpecialCellTable.ui.xml file?