General warning cleanup

This commit is contained in:
johni0702
2015-07-19 16:18:34 +02:00
parent 4f718ab302
commit 6422558028
31 changed files with 88 additions and 281 deletions

View File

@@ -138,8 +138,8 @@ public class GuiDropdown<T extends GuiEntryListEntry> extends GuiAdvancedTextFie
}
public boolean mouseClickedResult(int xPos, int yPos) {
if(!isEnabled) return false;
boolean success = false;
if(!isEnabled) return success;
if(xPos > xPosition + width - height && xPos < xPosition + width && yPos > yPosition && yPos < yPosition + height) {
open = !open;
} else {

View File

@@ -1,12 +1,9 @@
package eu.crushedpixel.replaymod.gui.elements;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.FontRenderer;
public class GuiNumberInputWithText extends GuiNumberInput {
private final Minecraft mc = Minecraft.getMinecraft();
private String suffix;
public GuiNumberInputWithText(FontRenderer fontRenderer,

View File

@@ -136,14 +136,13 @@ public class GuiKeyframeTimeline extends GuiTimeline {
int i = iterator.nextIndex();
int nextSpectatorKeyframeRealTime = -1;
while(iterator.hasNext()) {
if (iterator.hasNext()) {
Keyframe<AdvancedPosition> kf2 = iterator.next();
if(kf.getValue().getSpectatedEntityID()
.equals(kf2.getValue().getSpectatedEntityID())) {
nextSpectatorKeyframeRealTime = kf2.getRealTimestamp();
}
break;
}
int i2 = iterator.previousIndex();
@@ -172,12 +171,11 @@ public class GuiKeyframeTimeline extends GuiTimeline {
int i = iterator.nextIndex();
int nextTimeKeyframeRealTime = -1;
while(iterator.hasNext()) {
if (iterator.hasNext()) {
Keyframe<TimestampValue> kf2 = iterator.next();
if(kf.getValue().asInt() > kf2.getValue().asInt()) {
nextTimeKeyframeRealTime = kf2.getRealTimestamp();
}
break;
}
int i2 = iterator.previousIndex();
@@ -232,7 +230,7 @@ public class GuiKeyframeTimeline extends GuiTimeline {
y += 0;
//If Spectator Keyframe, use different texture
if(((Keyframe<AdvancedPosition>) kf).getValue().getSpectatedEntityID() != null) {
if(((AdvancedPosition) kf.getValue()).getSpectatedEntityID() != null) {
textureX = KEYFRAME_SPEC_X;
textureY = KEYFRAME_SPEC_Y;
}