HLayout actionsButtonBar = new HLayout();
actionsButtonBar.setWidth100();
actionsButtonBar.setAutoHeight();
actionsButtonBar.setMembersMargin(10);
btnPoint = new IButton(messages.geometricSearchWidgetFreeDrawingPoint());
btnPoint.setIcon(BTN_POINT_CREATE_IMG);
btnPoint.setAutoFit(true);
btnPoint.setActionType(SelectionType.RADIO);
btnPoint.setRadioGroup("drawType");
btnPoint.addClickHandler(new ClickHandler() {
public void onClick(ClickEvent event) {
onDrawPoint();
}
});
btnLine = new IButton(messages.geometricSearchWidgetFreeDrawingLine());
btnLine.setIcon(BTN_LINE_CREATE_IMG);
btnLine.setAutoFit(true);
btnLine.setActionType(SelectionType.RADIO);
btnLine.setRadioGroup("drawType");
btnLine.addClickHandler(new ClickHandler() {
public void onClick(ClickEvent event) {
onDrawLine();
}
});
btnPolygon = new IButton(messages.geometricSearchWidgetFreeDrawingPolygon());
btnPolygon.setIcon(BTN_POLYGON_CREATE_IMG);
btnPolygon.setAutoFit(true);
btnPolygon.setActionType(SelectionType.RADIO);
btnPolygon.setRadioGroup("drawType");
btnPolygon.addClickHandler(new ClickHandler() {
public void onClick(ClickEvent event) {
onDrawPolygon();
}
});
IButton btnAdd = new IButton(messages.geometricSearchWidgetFreeDrawingAdd());
btnAdd.setIcon(BTN_ADD_IMG);
btnAdd.setAutoFit(true);
btnAdd.addClickHandler(new ClickHandler() {
public void onClick(ClickEvent event) {
onAdd();
}
});
btnUndo = new IButton(messages.geometricSearchWidgetFreeDrawingUndo());
btnUndo.setIcon(BTN_UNDO_IMG);
btnUndo.setAutoFit(true);
btnUndo.setDisabled(true);
btnUndo.setShowDisabledIcon(false);
btnUndo.addClickHandler(new ClickHandler() {
public void onClick(ClickEvent event) {
onUndo();
}
});
btnRedo = new IButton(messages.geometricSearchWidgetFreeDrawingRedo());
btnRedo.setIcon(BTN_REDO_IMG);
btnRedo.setAutoFit(true);
btnRedo.setDisabled(true);
btnRedo.setShowDisabledIcon(false);
btnRedo.addClickHandler(new ClickHandler() {