Code style fixes

This commit is contained in:
Raoul Van den Berge
2016-03-25 22:22:31 +01:00
parent 25b302f914
commit 002b5c0dda

View File

@@ -49,11 +49,9 @@ public class GuiController extends GuiBase {
scrollbar.draw(this);
}
private int calculateOffsetOnScale(int pos ,float scale)
{
private int calculateOffsetOnScale(int pos, float scale) {
float multiplier = (pos / scale);
return (int) multiplier;
}
@Override
@@ -70,8 +68,6 @@ public class GuiController extends GuiBase {
RenderHelper.enableGUIStandardItemLighting();
ItemStack hoveringMachineStack = null;
for (int i = 0; i < 4; ++i) {
if (slot < controller.getMachines().size()) {
TileMachine machine = controller.getMachines().get(slot);
@@ -80,10 +76,6 @@ public class GuiController extends GuiBase {
ItemStack machineStack = new ItemStack(machineBlock, 1, machineBlock.getMetaFromState(machineState));
if (inBounds(x, y, 16, 16, mouseX, mouseY)) {
hoveringMachineStack = machineStack;
}
drawItem(x, y + 5, machineStack);
GlStateManager.pushMatrix();
float scale = 0.5f;
@@ -104,13 +96,6 @@ public class GuiController extends GuiBase {
slot++;
}
/* Not needed?
if (hoveringMachineStack != null) {
drawTooltip(mouseX, mouseY, hoveringMachineStack);
}
*/
if (inBounds(barX, barY, barWidth, barHeight, mouseX, mouseY)) {
drawTooltip(mouseX, mouseY, t("misc.refinedstorage:energy_usage", controller.getEnergyUsage()) + "\n" + t("misc.refinedstorage:energy_stored", controller.getEnergyStored(null), controller.getMaxEnergyStored(null)));
}