Auto-format spaces to tabs (#2)

This commit is contained in:
mezz committed 2016-10-27 02:49:49 -07:00
1 parent 25be7fd254
commit 5bb4b5d9a5
756 files changed
+49198 -48489

No files matched your search

@@ -12,49 +12,49 @@ import binnie.craftgui.events.EventMouse;
import binnie.craftgui.resource.minecraft.CraftGUITexture;
public class ControlButton extends Control {
private ControlText textWidget;
private String text;
private ControlText textWidget;
private String text;
public ControlButton(final IWidget parent, final float x, final float y, final float width, final float height) {
super(parent, x, y, width, height);
this.addAttribute(Attribute.MouseOver);
this.addEventHandler(new EventMouse.Down.Handler() {
@Override
public void onEvent(final EventMouse.Down event) {
ControlButton.this.callEvent(new EventButtonClicked(ControlButton.this.getWidget()));
ControlButton.this.onMouseClick(event);
}
}.setOrigin(EventHandler.Origin.Self, this));
}
public ControlButton(final IWidget parent, final float x, final float y, final float width, final float height) {
super(parent, x, y, width, height);
this.addAttribute(Attribute.MouseOver);
this.addEventHandler(new EventMouse.Down.Handler() {
@Override
public void onEvent(final EventMouse.Down event) {
ControlButton.this.callEvent(new EventButtonClicked(ControlButton.this.getWidget()));
ControlButton.this.onMouseClick(event);
}
}.setOrigin(EventHandler.Origin.Self, this));
}
protected void onMouseClick(final EventMouse.Down event) {
}
protected void onMouseClick(final EventMouse.Down event) {
}
public ControlButton(final IWidget parent, final float x, final float y, final float width, final float height, final String text) {
this(parent, x, y, width, height);
this.text = text;
this.textWidget = new ControlText(this, this.getArea(), text, TextJustification.MiddleCenter);
}
public ControlButton(final IWidget parent, final float x, final float y, final float width, final float height, final String text) {
this(parent, x, y, width, height);
this.text = text;
this.textWidget = new ControlText(this, this.getArea(), text, TextJustification.MiddleCenter);
}
@Override
public void onUpdateClient() {
if (this.textWidget != null) {
this.textWidget.setValue(this.getText());
}
}
@Override
public void onUpdateClient() {
if (this.textWidget != null) {
this.textWidget.setValue(this.getText());
}
}
public String getText() {
return this.text;
}
public String getText() {
return this.text;
}
@Override
public void onRenderBackground() {
Object texture = CraftGUITexture.ButtonDisabled;
if (this.isMouseOver()) {
texture = CraftGUITexture.ButtonHighlighted;
} else if (this.isEnabled()) {
texture = CraftGUITexture.Button;
}
CraftGUI.Render.texture(texture, this.getArea());
}
@Override
public void onRenderBackground() {
Object texture = CraftGUITexture.ButtonDisabled;
if (this.isMouseOver()) {
texture = CraftGUITexture.ButtonHighlighted;
} else if (this.isEnabled()) {
texture = CraftGUITexture.Button;
}
CraftGUI.Render.texture(texture, this.getArea());
}
}