org.tentackle.fx.container.FxTilePane Maven / Gradle / Ivy
/*
* Tentackle - https://tentackle.org.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/
package org.tentackle.fx.container;
import javafx.beans.property.BooleanProperty;
import javafx.beans.property.ReadOnlyBooleanProperty;
import javafx.collections.ObservableList;
import javafx.geometry.Orientation;
import javafx.scene.Node;
import javafx.scene.layout.TilePane;
import org.tentackle.fx.FxContainer;
import org.tentackle.fx.FxController;
import org.tentackle.fx.ModelToViewListener;
import org.tentackle.fx.ViewToModelListener;
import org.tentackle.fx.container.delegate.FxTilePaneDelegate;
/**
* Extended TilePane.
*
* @author harald
*/
public class FxTilePane extends TilePane implements FxContainer {
/**
* Creates a horizontal TilePane layout with prefColumn = 5 and hgap/vgap = 0.
*/
public FxTilePane() {
super();
}
/**
* Creates a TilePane layout with the specified orientation, prefColumn/prefRows = 5 and hgap/vgap = 0.
*
* @param orientation the direction the tiles should flow and wrap
*/
public FxTilePane(Orientation orientation) {
super(orientation);
}
/**
* Creates a horizontal TilePane layout with prefColumn = 5 and the specified hgap/vgap.
*
* @param hgap the amount of horizontal space between each tile
* @param vgap the amount of vertical space between each tile
*/
public FxTilePane(double hgap, double vgap) {
super(hgap, vgap);
}
/**
* Creates a TilePane layout with the specified orientation, hgap/vgap, and prefRows/prefColumns = 5.
*
* @param orientation the direction the tiles should flow and wrap
* @param hgap the amount of horizontal space between each tile
* @param vgap the amount of vertical space between each tile
*/
public FxTilePane(Orientation orientation, double hgap, double vgap) {
super(orientation, hgap, vgap);
}
/**
* Creates a horizontal TilePane layout with prefColumn = 5 and hgap/vgap = 0.
*
* @param children The initial set of children for this pane.
*/
public FxTilePane(Node... children) {
super(children);
}
/**
* Creates a TilePane layout with the specified orientation, prefColumn/prefRows = 5 and hgap/vgap = 0.
*
* @param orientation the direction the tiles should flow and wrap
* @param children The initial set of children for this pane.
*/
public FxTilePane(Orientation orientation, Node... children) {
super(orientation, children);
}
/**
* Creates a horizontal TilePane layout with prefColumn = 5 and the specified hgap/vgap.
*
* @param hgap the amount of horizontal space between each tile
* @param vgap the amount of vertical space between each tile
* @param children The initial set of children for this pane.
*/
public FxTilePane(double hgap, double vgap, Node... children) {
super(hgap, vgap, children);
}
/**
* Creates a TilePane layout with the specified orientation, hgap/vgap, and prefRows/prefColumns = 5.
*
* @param orientation the direction the tiles should flow and wrap
* @param hgap the amount of horizontal space between each tile
* @param vgap the amount of vertical space between each tile
* @param children The initial set of children for this pane.
*/
public FxTilePane(Orientation orientation, double hgap, double vgap, Node... children) {
super(orientation, hgap, vgap, children);
}
// @wurblet delegate Include $currentDir/fxcontainer.include
////GEN-BEGIN:delegate
private /**/FxTilePaneDelegate/**/ delegate; // @wurblet < Inject ${classname}Delegate
/**
* Creates the delegate.
*
* @return the delegate
*/
protected /**/FxTilePaneDelegate/**/ createDelegate() { // @wurblet < Inject ${classname}Delegate
return new /**/FxTilePaneDelegate/**/(this); // @wurblet < Inject ${classname}Delegate
}
@Override
public /**/FxTilePaneDelegate/**/ getDelegate() { // @wurblet < Inject ${classname}Delegate
if (delegate == null) {
delegate = createDelegate();
}
return delegate;
}
@Override
public FxContainer getParentContainer() {
return getDelegate().getParentContainer();
}
@Override
public ObservableList> getComponents() {
return getDelegate().getComponents();
}
@Override
public void setChangeable(boolean changeable) {
getDelegate().setChangeable(changeable);
}
@Override
public boolean isChangeable() {
return getDelegate().isChangeable();
}
@Override
public void setContainerChangeable(boolean containerChangeable) {
getDelegate().setContainerChangeable(containerChangeable);
}
@Override
public void setContainerChangableIgnored(boolean containerChangeableIgnored) {
getDelegate().setContainerChangableIgnored(containerChangeableIgnored);
}
@Override
public boolean isContainerChangeableIgnored() {
return getDelegate().isContainerChangeableIgnored();
}
@Override
public ReadOnlyBooleanProperty changeableProperty() {
return getDelegate().changeableProperty();
}
@Override
public void updateViewNonFocused() {
getDelegate().updateViewNonFocused();
}
@Override
public void updateView() {
getDelegate().updateView();
}
@Override
public void updateModel() {
getDelegate().updateModel();
}
@Override
public void saveView() {
getDelegate().saveView();
}
@Override
public void invalidateSavedView() {
getDelegate().invalidateSavedView();
}
@Override
public void triggerViewModified() {
getDelegate().triggerViewModified();
}
@Override
public void setViewModified(boolean viewModified) {
getDelegate().setViewModified(viewModified);
}
@Override
public boolean isViewModified() {
return getDelegate().isViewModified();
}
@Override
public BooleanProperty viewModifiedProperty() {
return getDelegate().viewModifiedProperty();
}
@Override
public void setBindable(boolean bindable) {
getDelegate().setBindable(bindable);
}
@Override
public boolean isBindable() {
return getDelegate().isBindable();
}
@Override
public void setHelpUrl(String helpUrl) {
getDelegate().setHelpUrl(helpUrl);
}
@Override
public String getHelpUrl() {
return getDelegate().getHelpUrl();
}
@Override
public void showHelp() {
getDelegate().showHelp();
}
@Override
public String toGenericString() {
return getDelegate().toGenericString();
}
@Override
public void clearErrors() {
getDelegate().clearErrors();
}
@Override
public FxController getController() {
return getDelegate().getController();
}
@Override
public void setController(FxController controller) {
getDelegate().setController(controller);
}
@Override
public C getController(Class clazz) {
return getDelegate().getController(clazz);
}
@Override
public void addModelToViewListener(ModelToViewListener listener) {
getDelegate().addModelToViewListener(listener);
}
@Override
public void removeModelToViewListener(ModelToViewListener listener) {
getDelegate().removeModelToViewListener(listener);
}
@Override
public void addViewToModelListener(ViewToModelListener listener) {
getDelegate().addViewToModelListener(listener);
}
@Override
public void removeViewToModelListener(ViewToModelListener listener) {
getDelegate().removeViewToModelListener(listener);
}
// //GEN-END:delegate
}