public class ToolboxFragment extends java.lang.Object implements IFragment, ISelectable, IInteractable
Modifier and Type | Field and Description |
---|---|
javafx.scene.paint.Color |
color |
javafx.scene.layout.BorderPane |
uiBorderPane |
javafx.scene.image.ImageView |
uiIcon |
ToolboxItem |
uiToolboxItem |
Constructor and Description |
---|
ToolboxFragment(ToolboxItem toolboxItem,
javafx.scene.image.ImageView icon)
Constructs a ToolboxFragment.
|
Modifier and Type | Method and Description |
---|---|
private void |
build()
Helper method to build the view and keep constructor more clear.
|
void |
deselect()
Is called when item is deselected, changes look.
|
void |
exit()
Is called on mouse exit, changes look.
|
javafx.scene.Node |
getFragment()
Get main view fragment
|
SelectionType |
getType()
Specifies what kind of SelectionType this object is.
|
void |
hover()
Is called on mouse hover, changes look.
|
void |
select()
Is called when item is selected, changes look.
|
void |
setColor(javafx.scene.paint.Color color) |
public javafx.scene.paint.Color color
public final javafx.scene.layout.BorderPane uiBorderPane
public final javafx.scene.image.ImageView uiIcon
public final ToolboxItem uiToolboxItem
public ToolboxFragment(ToolboxItem toolboxItem, javafx.scene.image.ImageView icon)
toolboxItem
- ToolboxItem.icon
- ImageView.private void build()
public void deselect()
deselect
in interface ISelectable
public void exit()
exit
in interface IInteractable
public javafx.scene.Node getFragment()
getFragment
in interface IFragment
public SelectionType getType()
getType
in interface ISelectable
public void hover()
hover
in interface IInteractable
public void select()
select
in interface ISelectable
public void setColor(javafx.scene.paint.Color color)