" panel.getFlexCellFormatter().setRowSpan(1, 1, 2);",
" }",
"}");
frame.refresh();
assertNoErrors(frame);
final HTMLTableInfo panel = (HTMLTableInfo) frame.getChildrenWidgets().get(0);
assertThat(panel.getColumns()).hasSize(3);
assertThat(panel.getRows()).hasSize(3);
assertEquals("3 3 [3, 3, 3] {"
+ "(0,0)=(1,1) (1,0)=(1,1) (2,0)=(1,1) "
+ "(0,1)=(1,1) (1,1)=(1,2) (2,1)=(1,1) "
+ "(0,2)=(1,1) (1,2)=(1,1) (2,2)=(1,1)}", panel.getStatus().toString());
// do operation
ExecutionUtils.run(frame, new RunnableEx() {
public void run() throws Exception {
panel.insertRow(2);
}
});
assertEditor(
"public class Test implements EntryPoint {",
" public void onModuleLoad() {",
" RootPanel rootPanel = RootPanel.get();",
" FlexTable panel = new FlexTable();",
" rootPanel.add(panel);",
" panel.setWidget(0, 0, new Button('A'));",
" panel.setWidget(1, 1, new Button('B'));",
" panel.setWidget(3, 2, new Button('C'));",
" panel.getFlexCellFormatter().setRowSpan(1, 1, 3);",
" }",
"}");
assertThat(panel.getColumns()).hasSize(3);
assertThat(panel.getRows()).hasSize(4);
assertEquals("3 4 [3, 3, 3, 3] {"
+ "(0,0)=(1,1) (1,0)=(1,1) (2,0)=(1,1) "
+ "(0,1)=(1,1) (1,1)=(1,3) (2,1)=(1,1) "
+ "(0,2)=(1,1) (1,2)=(1,1) (2,2)=(1,1) "
+ "(0,3)=(1,1) (1,3)=(1,1) (2,3)=(1,1)}", panel.getStatus().toString());
}