public abstract class ScrollPanel extends FocusableGui implements IRenderable
Modifier and Type | Field and Description |
---|---|
private int |
barLeft |
private int |
barWidth |
protected int |
border |
protected int |
bottom |
protected boolean |
captureMouse |
private Minecraft |
client |
protected int |
height |
protected int |
left |
protected int |
right |
protected float |
scrollDistance |
private boolean |
scrolling |
protected int |
top |
protected int |
width |
BACKGROUND_LOCATION, GUI_ICONS_LOCATION, STATS_ICON_LOCATION
Constructor and Description |
---|
ScrollPanel(Minecraft client,
int width,
int height,
int top,
int left) |
Modifier and Type | Method and Description |
---|---|
private void |
applyScrollLimits() |
java.util.List<? extends IGuiEventListener> |
children() |
protected boolean |
clickPanel(double mouseX,
double mouseY,
int button) |
protected void |
drawBackground() |
protected void |
drawGradientRect(int left,
int top,
int right,
int bottom,
int color1,
int color2) |
protected abstract void |
drawPanel(int entryRight,
int relativeY,
Tessellator tess,
int mouseX,
int mouseY)
Draw anything special on the screen.
|
private int |
getBarHeight() |
protected abstract int |
getContentHeight() |
private int |
getMaxScroll() |
protected int |
getScrollAmount() |
boolean |
isMouseOver(double mouseX,
double mouseY) |
boolean |
mouseClicked(double mouseX,
double mouseY,
int button) |
boolean |
mouseDragged(double mouseX,
double mouseY,
int button,
double deltaX,
double deltaY) |
boolean |
mouseReleased(double p_mouseReleased_1_,
double p_mouseReleased_3_,
int p_mouseReleased_5_) |
boolean |
mouseScrolled(double mouseX,
double mouseY,
double scroll) |
void |
render(int mouseX,
int mouseY,
float partialTicks) |
getFocused, isDragging, setDragging, setFocused
blit, blit, blit, blit, blit, drawCenteredString, drawRightAlignedString, drawString, fill, fill, fillGradient, getBlitOffset, hLine, innerBlit, setBlitOffset, vLine
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
changeFocus, charTyped, func_212932_b, getEventListenerForPos, keyPressed, keyReleased, setFocusedDefault
mouseMoved
private final Minecraft client
protected final int width
protected final int height
protected final int top
protected final int bottom
protected final int right
protected final int left
private boolean scrolling
protected float scrollDistance
protected boolean captureMouse
protected final int border
private final int barWidth
private final int barLeft
public ScrollPanel(Minecraft client, int width, int height, int top, int left)
protected abstract int getContentHeight()
protected void drawBackground()
protected abstract void drawPanel(int entryRight, int relativeY, Tessellator tess, int mouseX, int mouseY)
mouseY
- mouseX
- protected boolean clickPanel(double mouseX, double mouseY, int button)
private int getMaxScroll()
private void applyScrollLimits()
public boolean mouseScrolled(double mouseX, double mouseY, double scroll)
mouseScrolled
in interface IGuiEventListener
mouseScrolled
in interface INestedGuiEventHandler
protected int getScrollAmount()
public boolean isMouseOver(double mouseX, double mouseY)
isMouseOver
in interface IGuiEventListener
public boolean mouseClicked(double mouseX, double mouseY, int button)
mouseClicked
in interface IGuiEventListener
mouseClicked
in interface INestedGuiEventHandler
public boolean mouseReleased(double p_mouseReleased_1_, double p_mouseReleased_3_, int p_mouseReleased_5_)
mouseReleased
in interface IGuiEventListener
mouseReleased
in interface INestedGuiEventHandler
private int getBarHeight()
public boolean mouseDragged(double mouseX, double mouseY, int button, double deltaX, double deltaY)
mouseDragged
in interface IGuiEventListener
mouseDragged
in interface INestedGuiEventHandler
public void render(int mouseX, int mouseY, float partialTicks)
render
in interface IRenderable
protected void drawGradientRect(int left, int top, int right, int bottom, int color1, int color2)
public java.util.List<? extends IGuiEventListener> children()
children
in interface INestedGuiEventHandler