@Override
protected void onSelectionChanged(String tileTypeName) {
;
if (tileTypeName == null) {
EmptyPanel ep = new EmptyPanel(newTileEditor.getId());
newTileEditor.replaceWith(ep);
newTileEditor = ep;
} else {
final Brix brix = NewTileFragment.this.getModelObject().getBrix();
final Tile tile = Tile.Helper.getTileOfType(tileTypeName, brix);
TileEditorPanel ed = tile.newEditor(newTileEditor.getId(), nodeModel);
newTileEditor.replaceWith(ed);
newTileEditor = ed;
}
}
}.setRequired(true));
newTileEditor = new EmptyPanel("tile-editor");
form.add(newTileEditor);
form.add(new SubmitLink("add") {
@Override
public void onSubmit() {