Examples of GuiToggleButtonSmall


Examples of mods.railcraft.client.gui.buttons.GuiToggleButtonSmall

        int h = (height - ySize) / 2;

        buttonList.add(new GuiButton(0, w + 10, h + 25, 30, 20, "<"));
        buttonList.add(new GuiButton(1, w + 135, h + 25, 30, 20, ">"));

        buttonList.add(any = new GuiToggleButtonSmall(2, w + 10, h + 55, 45, LocalizationPlugin.translate("railcraft.gui.detector.villager.any"), mode == Mode.ANY));
        buttonList.add(none = new GuiToggleButtonSmall(3, w + 10, h + 75, 45, LocalizationPlugin.translate("railcraft.gui.detector.villager.none"), mode == Mode.NONE));
        buttonList.add(equals = new GuiToggleButtonSmall(4, w + 122, h + 55, 45, LocalizationPlugin.translate("railcraft.gui.detector.villager.equals"), mode == Mode.EQUALS));
        buttonList.add(not = new GuiToggleButtonSmall(5, w + 122, h + 75, 45, LocalizationPlugin.translate("railcraft.gui.detector.villager.not"), mode == Mode.NOT));
    }
View Full Code Here

Examples of mods.railcraft.client.gui.buttons.GuiToggleButtonSmall

        buttonList.clear();
        int w = (width - xSize) / 2;
        int h = (height - ySize) / 2;

        List<GuiBetterButton> buttons = new ArrayList<GuiBetterButton>();
        running = new GuiToggleButtonSmall(0, 0, h + ySize - 129, 55, LocalizationPlugin.translate("railcraft.gui.locomotive.mode.running"), loco.clientMode == LocoMode.RUNNING);
        buttons.add(running);
        idle = new GuiToggleButtonSmall(1, 0, h + ySize - 129, 45, LocalizationPlugin.translate("railcraft.gui.locomotive.mode.idle"), loco.clientMode == LocoMode.IDLE);
        if (hasIdleMode)
            buttons.add(idle);
        shutdown = new GuiToggleButtonSmall(2, 0, h + ySize - 129, 55, LocalizationPlugin.translate("railcraft.gui.locomotive.mode.shutdown"), loco.clientMode == LocoMode.SHUTDOWN);
        buttons.add(shutdown);

        running.setToolTip(ToolTip.buildToolTip("railcraft.gui.locomotive." + typeTag + ".tip.button.mode.running"));
        idle.setToolTip(ToolTip.buildToolTip("railcraft.gui.locomotive." + typeTag + ".tip.button.mode.idle"));
        shutdown.setToolTip(ToolTip.buildToolTip("railcraft.gui.locomotive." + typeTag + ".tip.button.mode.shutdown"));

        GuiTools.newButtonRowAuto(buttonList, w + 3, 171, buttons);

        List<GuiBetterButton> speedButtons = new ArrayList<GuiBetterButton>();
        reverse = new GuiToggleButtonSmall(3, 0, h + ySize - 112, 12, "<", loco.clientSpeed == LocoSpeed.REVERSE);
        speedButtons.add(reverse);
        slowest = new GuiToggleButtonSmall(4, 0, h + ySize - 112, 12, ">", loco.clientSpeed == LocoSpeed.SLOWEST);
        speedButtons.add(slowest);
        slower = new GuiToggleButtonSmall(5, 0, h + ySize - 112, 17, ">>", loco.clientSpeed == LocoSpeed.SLOWER);
        speedButtons.add(slower);
        slow = new GuiToggleButtonSmall(6, 0, h + ySize - 112, 22, ">>>", loco.clientSpeed == LocoSpeed.SLOW);
        speedButtons.add(slow);
        max = new GuiToggleButtonSmall(7, 0, h + ySize - 112, 27, ">>>>", loco.clientSpeed == LocoSpeed.MAX);
        speedButtons.add(max);

        GuiTools.newButtonRow(buttonList, w + 8, 3, speedButtons);

        buttonList.add(lockButton = new GuiMultiButton(8, w + 152, h + ySize - 111, 16, loco.getLockController()));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.