Region spacer = new Region();
HBox.setHgrow(spacer, Priority.ALWAYS);
// add close min max
Button closeButton = createWindowButton("close");
closeButton.setOnAction(new EventHandler() {
@Override public void handle(Event event) {
FXDialog.this.hide();
}
});
minButton = createWindowButton("minimize");
minButton.setOnAction(new EventHandler() {
@Override public void handle(Event event) {
setIconified(!isIconified());
}
});
maxButton = createWindowButton("maximize");
maxButton.setOnAction(new EventHandler() {
private double restoreX;
private double restoreY;
private double restoreW;
private double restoreH;