aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorNopoTheGamer <40329022+NopoTheGamer@users.noreply.github.com>2022-09-30 01:25:12 +1000
committerGitHub <noreply@github.com>2022-09-29 17:25:12 +0200
commitcbcc4c3b4004cbf3f86aeab515ea94a93b4efd1e (patch)
tree970941cba5172370ee24487b14c32c4a3ceb1dfc /src/main
parent66a24df5731ad31ea9cbee5e80879e4169009ae7 (diff)
downloadNotEnoughUpdates-cbcc4c3b4004cbf3f86aeab515ea94a93b4efd1e.tar.gz
NotEnoughUpdates-cbcc4c3b4004cbf3f86aeab515ea94a93b4efd1e.tar.bz2
NotEnoughUpdates-cbcc4c3b4004cbf3f86aeab515ea94a93b4efd1e.zip
Fix for that 1 human who has gui scale 5 (#323)
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/profileviewer/GuiProfileViewer.java7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/profileviewer/GuiProfileViewer.java b/src/main/java/io/github/moulberry/notenoughupdates/profileviewer/GuiProfileViewer.java
index 8576f141..83d8fab9 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/profileviewer/GuiProfileViewer.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/profileviewer/GuiProfileViewer.java
@@ -55,7 +55,6 @@ import org.lwjgl.opengl.GL14;
import org.lwjgl.opengl.GL20;
import java.awt.*;
-import java.io.File;
import java.io.IOException;
import java.net.URI;
import java.net.URISyntaxException;
@@ -458,7 +457,7 @@ public class GuiProfileViewer extends GuiScreen {
new Color(63, 224, 208, 255).getRGB()
);
- if (profileDropdownSelected && !profile.getProfileNames().isEmpty() && scaledResolution.getScaleFactor() != 4) {
+ if (profileDropdownSelected && !profile.getProfileNames().isEmpty() && scaledResolution.getScaleFactor() < 4) {
int dropdownOptionSize = scaledResolution.getScaleFactor() == 3 ? 10 : 20;
int numProfiles = profile.getProfileNames().size();
@@ -912,7 +911,7 @@ public class GuiProfileViewer extends GuiScreen {
if (mouseX > guiLeft && mouseX < guiLeft + 100 && profile != null && !profile.getProfileNames().isEmpty()) {
ScaledResolution scaledResolution = new ScaledResolution(Minecraft.getMinecraft());
if (mouseY > guiTop + sizeY + 3 && mouseY < guiTop + sizeY + 23) {
- if (scaledResolution.getScaleFactor() == 4) {
+ if (scaledResolution.getScaleFactor() >= 4) {
profileDropdownSelected = false;
int profileNum = 0;
for (int index = 0; index < profile.getProfileNames().size(); index++) {
@@ -937,7 +936,7 @@ public class GuiProfileViewer extends GuiScreen {
} else {
profileDropdownSelected = !profileDropdownSelected;
}
- } else if (scaledResolution.getScaleFactor() != 4 && profileDropdownSelected) {
+ } else if (scaledResolution.getScaleFactor() < 4 && profileDropdownSelected) {
int dropdownOptionSize = scaledResolution.getScaleFactor() == 3 ? 10 : 20;
int extraY = mouseY - (guiTop + sizeY + 23);
int index = extraY / dropdownOptionSize;