use of net.minecraft.client.gui.GuiButton in project LogisticsPipes by RS485.
the class FluidGuiOrderer method initGui.
@SuppressWarnings("unchecked")
@Override
public void initGui() {
boolean setItemDisplay = itemDisplay == null;
super.initGui();
// Refresh
buttonList.add(new GuiButton(3, guiLeft + 10, bottom - 25, 46, 20, "Refresh"));
if (setItemDisplay) {
itemDisplay = new ItemDisplay(this, mc.fontRenderer, this, this, guiLeft + 10, guiTop + 18, xSize - 20, ySize - 100, new int[] { 1, 1000, 16000, 100 }, false);
}
itemDisplay.reposition(guiLeft + 10, guiTop + 18, xSize - 20, ySize - 100);
}
use of net.minecraft.client.gui.GuiButton in project LogisticsPipes by RS485.
the class GuiOrderer method initGui.
@SuppressWarnings("unchecked")
@Override
public void initGui() {
super.initGui();
buttonList.clear();
// Request
buttonList.add(new GuiButton(0, right - 55, bottom - 25, 50, 20, "Request"));
// Next page
buttonList.add(new SmallGuiButton(1, right - 15, guiTop + 5, 10, 10, ">"));
// Prev page
buttonList.add(new SmallGuiButton(2, right - 90, guiTop + 5, 10, 10, "<"));
// -64
buttonList.add(new SmallGuiButton(10, xCenter - 51, bottom - 15, 26, 10, "---"));
// -10
buttonList.add(new SmallGuiButton(4, xCenter - 51, bottom - 26, 15, 10, "--"));
// -1
buttonList.add(new SmallGuiButton(5, xCenter - 35, bottom - 26, 10, 10, "-"));
// +1
buttonList.add(new SmallGuiButton(6, xCenter + 26, bottom - 26, 10, 10, "+"));
// +10
buttonList.add(new SmallGuiButton(7, xCenter + 38, bottom - 26, 15, 10, "++"));
// +64
buttonList.add(new SmallGuiButton(11, xCenter + 26, bottom - 15, 26, 10, "+++"));
// Popup
buttonList.add(new GuiCheckBox(8, guiLeft + 9, bottom - 60, 14, 14, Configs.DISPLAY_POPUP));
// Sort
buttonList.add(new SmallGuiButton(20, xCenter - 13, bottom - 41, 26, 10, "Sort"));
if (search == null) {
search = new SearchBar(mc.fontRenderer, this, guiLeft + 30, bottom - 78, right - guiLeft - 58, 15);
}
search.reposition(guiLeft + 30, bottom - 78, right - guiLeft - 58, 15);
if (itemDisplay == null) {
itemDisplay = new ItemDisplay(this, mc.fontRenderer, this, this, guiLeft + 10, guiTop + 18, xSize - 20, ySize - 100, new int[] { 1, 10, 64, 64 }, true);
}
itemDisplay.reposition(guiLeft + 10, guiTop + 18, xSize - 20, ySize - 100);
}
use of net.minecraft.client.gui.GuiButton in project LogisticsPipes by RS485.
the class GuiRequestTable method initGui.
@Override
@SuppressWarnings("unchecked")
public void initGui() {
boolean reHide = false;
if (!showRequest) {
guiLeft = startLeft;
xSize = startXSize;
showRequest = true;
reHide = true;
}
super.initGui();
buttonList.clear();
// Request
buttonList.add(hideWhileSmall.addChain(new GuiButton(0, right - 55, bottom - 25, 50, 20, "Request")));
// Next page
buttonList.add(hideWhileSmall.addChain(new SmallGuiButton(1, right - 15, guiTop + 5, 10, 10, ">")));
// Prev page
buttonList.add(hideWhileSmall.addChain(new SmallGuiButton(2, right - 90, guiTop + 5, 10, 10, "<")));
// -64
buttonList.add(hideWhileSmall.addChain(new SmallGuiButton(10, right - 148, bottom - 15, 26, 10, "---")));
// -10
buttonList.add(hideWhileSmall.addChain(new SmallGuiButton(4, right - 148, bottom - 26, 15, 10, "--")));
// -1
buttonList.add(hideWhileSmall.addChain(new SmallGuiButton(5, right - 132, bottom - 26, 10, 10, "-")));
// +1
buttonList.add(hideWhileSmall.addChain(new SmallGuiButton(6, right - 86, bottom - 26, 10, 10, "+")));
// +10
buttonList.add(hideWhileSmall.addChain(new SmallGuiButton(7, right - 74, bottom - 26, 15, 10, "++")));
// +64
buttonList.add(hideWhileSmall.addChain(new SmallGuiButton(11, right - 86, bottom - 15, 26, 10, "+++")));
// Popup
buttonList.add(hideWhileSmall.addChain(new GuiCheckBox(8, guiLeft + 209, bottom - 60, 14, 14, Configs.DISPLAY_POPUP)));
// Refresh
buttonList.add(hideWhileSmall.addChain(new SmallGuiButton(3, guiLeft + 210, bottom - 15, 46, 10, "Refresh")));
// Component
buttonList.add(hideWhileSmall.addChain(new SmallGuiButton(13, guiLeft + 210, bottom - 28, 46, 10, "Content")));
buttonList.add(hideWhileSmall.addChain(new SmallGuiButton(9, guiLeft + 210, bottom - 41, 46, 10, "Both")));
// Sort
buttonList.add(hideWhileSmall.addChain(new SmallGuiButton(20, right - 116, bottom - 41, 26, 10, "Sort")));
// +1
buttonList.add(moveWhileSmall.addChain(new SmallGuiButton(14, guiLeft + 96, guiTop + 53, 10, 10, "+")));
// +10
buttonList.add(moveWhileSmall.addChain(new SmallGuiButton(15, guiLeft + 108, guiTop + 53, 15, 10, "++")));
// +64
buttonList.add(moveWhileSmall.addChain(new SmallGuiButton(16, guiLeft + 96, guiTop + 64, 26, 10, "+++")));
// x
buttonList.add(moveWhileSmall.addChain(new SmallGuiButton(30, guiLeft + 96 + 2, guiTop + 18, 10, 10, "X")));
// ~
buttonList.add(moveWhileSmall.addChain(new SmallGuiButton(31, guiLeft + 108 + 2, guiTop + 18, 10, 10, "~", 3)));
// Hide
buttonList.add(hideShowButton = new SmallGuiButton(17, guiLeft + 173, guiTop + 5, 36, 10, "Hide"));
buttonList.add(Macrobutton = new SmallGuiButton(18, right - 55, bottom - 60, 50, 10, "Disk"));
Macrobutton.enabled = false;
(sycleButtons[0] = addButton(new SmallGuiButton(21, guiLeft + 124, guiTop + 30, 15, 10, "/\\"))).visible = false;
(sycleButtons[1] = addButton(new SmallGuiButton(22, guiLeft + 124, guiTop + 42, 15, 10, "\\/"))).visible = false;
if (search == null) {
search = new SearchBar(mc.fontRenderer, this, guiLeft + 205, bottom - 78, 200, 15);
}
search.reposition(guiLeft + 205, bottom - 78, 200, 15);
if (itemDisplay == null) {
itemDisplay = new ItemDisplay(this, mc.fontRenderer, this, this, guiLeft + 205, guiTop + 18, 200, ySize - 100, new int[] { 1, 10, 64, 64 }, true);
}
itemDisplay.reposition(guiLeft + 205, guiTop + 18, 200, ySize - 100);
startLeft = guiLeft;
startXSize = xSize;
if (reHide) {
showRequest = false;
xSize = startXSize - 210;
guiLeft = startLeft + 105;
for (GuiButton button : moveWhileSmall) {
button.xPosition += 105;
}
hideShowButton.xPosition += 90;
hideShowButton.displayString = "Show";
for (GuiButton button : hideWhileSmall) {
button.visible = false;
}
Macrobutton.visible = false;
}
}
use of net.minecraft.client.gui.GuiButton in project LogisticsPipes by RS485.
the class DisconnectionConfigurationPopup method initGui.
@Override
public void initGui() {
super.initGui();
buttonList.clear();
configDisplay = new SideConfigDisplay(pipe) {
@Override
public void handleSelection(SelectedFace selection) {
DisconnectionConfigurationPopup.this.handleSelection(selection);
}
};
configDisplay.init();
configDisplay.renderNeighbours = true;
buttonList.add(new GuiButton(0, right - 106, bottom - 26, 100, 20, "OK"));
bounds = new Rectangle(guiLeft + 5, guiTop + 20, this.xSize - 10, this.ySize - 50);
}
use of net.minecraft.client.gui.GuiButton in project LogisticsPipes by RS485.
the class GuiPowerJunction method initGui.
@SuppressWarnings("unchecked")
@Override
public void initGui() {
super.initGui();
buttonList.clear();
if (LPConstants.DEBUG) {
buttonList.add(new GuiButton(0, guiLeft + 140, guiTop + 20, 20, 20, "+"));
}
}
Aggregations