Class BaseSimpleItemGUIPane<S extends BaseSimpleItemGUIPane<S>>
java.lang.Object
de.placeblock.betterinventories.content.GUISection
de.placeblock.betterinventories.content.pane.GUIPane
de.placeblock.betterinventories.content.pane.impl.simple.BaseSimpleGUIPane<GUIItem,S>
de.placeblock.betterinventories.content.pane.impl.simple.BaseSimpleItemGUIPane<S>
- Type Parameters:
S- The implementing class to return this-type correctly e.g.BaseSimpleGUIPane.addItemEmptySlot(GUIItem)
- All Implemented Interfaces:
Sizeable
- Direct Known Subclasses:
BaseIOGUIPane,BasePaginatorControlsPane,SimpleItemGUIPane
public abstract class BaseSimpleItemGUIPane<S extends BaseSimpleItemGUIPane<S>>
extends BaseSimpleGUIPane<GUIItem,S>
Base class for various SimpleItemGUIPanes.
Implementation of
BaseSimpleGUIPane that can contain only GUIItem.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classBaseSimpleItemGUIPane.AbstractBuilder<B extends BaseSimpleItemGUIPane.AbstractBuilder<B,P>, P extends BaseSimpleItemGUIPane<P>> Builder for creatingBaseSimpleItemGUIPaneNested classes/interfaces inherited from class de.placeblock.betterinventories.content.pane.impl.simple.BaseSimpleGUIPane
BaseSimpleGUIPane.ChildData<C extends GUISection> -
Field Summary
Fields inherited from class de.placeblock.betterinventories.content.pane.impl.simple.BaseSimpleGUIPane
autoSize, contentFields inherited from class de.placeblock.betterinventories.content.GUISection
maxSize, minSize -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedBaseSimpleItemGUIPane(GUI gui, Vector2d minSize, Vector2d maxSize, boolean autoSize) Creates a new SimpleGUIPane -
Method Summary
Modifier and TypeMethodDescriptionvoidflipX()Flips all items on the X axis.voidflipY()Flips all items on the Y axis.getItem(int slot) Returns an item for a given slotReturns an item for a given positionvoidshiftX(int delta) Shifts Items to the left or rightvoidshiftY(int delta) Shifts Items to the top or bottomMethods inherited from class de.placeblock.betterinventories.content.pane.impl.simple.BaseSimpleGUIPane
addItemEmptySlot, clear, fill, getChildren, getNextEmptySlot, getSections, onItemProvide, removeSection, removeSection, render, search, setSection, setSectionAt, setSectionAt, updateSize, updateSizeRecursiveMethods inherited from class de.placeblock.betterinventories.content.pane.GUIPane
onItemAdd, onItemAmount, onItemClick, onItemRemove, onItemRemoveTroughInventoryClose, onSizeChange, provideItem, renderOnList, setHeight, setSize, setWidth, updateChildrenRecursiveMethods inherited from class de.placeblock.betterinventories.content.GUISection
getEmptyContentList, getHeight, getSlots, getWidth, slotToVector, vectorToSlotMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface de.placeblock.betterinventories.Sizeable
clampSize, getMaxSize, getMinSize, getSize
-
Constructor Details
-
BaseSimpleItemGUIPane
Creates a new SimpleGUIPane- Parameters:
gui- The GUIminSize- The minimum size of the PanemaxSize- The maximum size of the PaneautoSize- Whether to automatically resize the pane according to the children. If true it will set the size to the bounding box of all children.
-
-
Method Details
-
flipY
public void flipY()Flips all items on the Y axis. Items on the left will be on the right and vice versa. -
flipX
public void flipX()Flips all items on the X axis. Items on the top will be on the bottom and vice versa. -
shiftX
public void shiftX(int delta) Shifts Items to the left or right- Parameters:
delta- The delta (positive to shift to the right)
-
shiftY
public void shiftY(int delta) Shifts Items to the top or bottom- Parameters:
delta- The delta (positive to shift to the bottom)
-
getItem
Returns an item for a given slot- Parameters:
slot- The slot- Returns:
- The item or null
-
getItem
Returns an item for a given position- Parameters:
position- The position- Returns:
- The item or null
-