aboutsummaryrefslogtreecommitdiff
path: root/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/cc/polyfrost/oneconfig/gui/elements/ColorSelector.java4
-rw-r--r--src/main/java/cc/polyfrost/oneconfig/gui/pages/HomePage.java10
-rw-r--r--src/main/java/cc/polyfrost/oneconfig/lwjgl/RenderManager.java4
-rw-r--r--src/main/java/cc/polyfrost/oneconfig/utils/NetworkUtils.java (renamed from src/main/java/cc/polyfrost/oneconfig/utils/InternetUtils.java)2
4 files changed, 10 insertions, 10 deletions
diff --git a/src/main/java/cc/polyfrost/oneconfig/gui/elements/ColorSelector.java b/src/main/java/cc/polyfrost/oneconfig/gui/elements/ColorSelector.java
index e85e223..4e04f5c 100644
--- a/src/main/java/cc/polyfrost/oneconfig/gui/elements/ColorSelector.java
+++ b/src/main/java/cc/polyfrost/oneconfig/gui/elements/ColorSelector.java
@@ -11,7 +11,7 @@ import cc.polyfrost.oneconfig.lwjgl.image.Images;
import cc.polyfrost.oneconfig.lwjgl.image.SVGs;
import cc.polyfrost.oneconfig.utils.ColorUtils;
import cc.polyfrost.oneconfig.utils.InputUtils;
-import cc.polyfrost.oneconfig.utils.InternetUtils;
+import cc.polyfrost.oneconfig.utils.NetworkUtils;
import cc.polyfrost.oneconfig.utils.MathUtils;
import org.lwjgl.input.Mouse;
@@ -318,7 +318,7 @@ public class ColorSelector {
hueInput.setInput(String.format("%.01f", (float) color.getHue()));
hexInput.setInput("#" + color.getHex());
}
- if(guideBtn.isClicked()) InternetUtils.browseLink("https://www.youtube.com/watch?v=dQw4w9WgXcQ");
+ if(guideBtn.isClicked()) NetworkUtils.browseLink("https://www.youtube.com/watch?v=dQw4w9WgXcQ");
// draw the color preview
diff --git a/src/main/java/cc/polyfrost/oneconfig/gui/pages/HomePage.java b/src/main/java/cc/polyfrost/oneconfig/gui/pages/HomePage.java
index e2c342c..db19226 100644
--- a/src/main/java/cc/polyfrost/oneconfig/gui/pages/HomePage.java
+++ b/src/main/java/cc/polyfrost/oneconfig/gui/pages/HomePage.java
@@ -10,7 +10,7 @@ import cc.polyfrost.oneconfig.lwjgl.font.Fonts;
import cc.polyfrost.oneconfig.lwjgl.image.SVGs;
import cc.polyfrost.oneconfig.utils.ColorUtils;
import cc.polyfrost.oneconfig.utils.InputUtils;
-import cc.polyfrost.oneconfig.utils.InternetUtils;
+import cc.polyfrost.oneconfig.utils.NetworkUtils;
import java.awt.*;
@@ -32,11 +32,11 @@ public class HomePage extends Page {
public HomePage() {
super("Home Dashboard");
- socialsBtn.setClickAction(() -> InternetUtils.browseLink("https://twitter.com/polyfrost"));
- discordBtn.setClickAction(() -> InternetUtils.browseLink("https://discord.gg/4BdUuGpMdf"));
- webBtn.setClickAction(() -> InternetUtils.browseLink("https://polyfrost.cc"));
+ socialsBtn.setClickAction(() -> NetworkUtils.browseLink("https://twitter.com/polyfrost"));
+ discordBtn.setClickAction(() -> NetworkUtils.browseLink("https://discord.gg/4BdUuGpMdf"));
+ webBtn.setClickAction(() -> NetworkUtils.browseLink("https://polyfrost.cc"));
creditsBtn.setClickAction(new CreditsPage());
- guideBtn.setClickAction(() -> InternetUtils.browseLink("https://www.youtube.com/watch?v=dQw4w9WgXcQ"));
+ guideBtn.setClickAction(() -> NetworkUtils.browseLink("https://www.youtube.com/watch?v=dQw4w9WgXcQ"));
}
diff --git a/src/main/java/cc/polyfrost/oneconfig/lwjgl/RenderManager.java b/src/main/java/cc/polyfrost/oneconfig/lwjgl/RenderManager.java
index 8f43aa7..8d68715 100644
--- a/src/main/java/cc/polyfrost/oneconfig/lwjgl/RenderManager.java
+++ b/src/main/java/cc/polyfrost/oneconfig/lwjgl/RenderManager.java
@@ -12,7 +12,7 @@ import cc.polyfrost.oneconfig.libs.universal.UGraphics;
import cc.polyfrost.oneconfig.libs.universal.UMinecraft;
import cc.polyfrost.oneconfig.libs.universal.UResolution;
import cc.polyfrost.oneconfig.utils.InputUtils;
-import cc.polyfrost.oneconfig.utils.InternetUtils;
+import cc.polyfrost.oneconfig.utils.NetworkUtils;
import net.minecraft.client.gui.Gui;
import net.minecraft.client.shader.Framebuffer;
import org.lwjgl.nanovg.*;
@@ -199,7 +199,7 @@ public final class RenderManager {
float length = getTextWidth(vg, url, size, font);
drawRectangle(vg, x, y + size / 2, length, 1, OneConfigConfig.PRIMARY_500);
if(InputUtils.isAreaClicked((int) (x - 2), (int) (y - 1), (int) (length + 4), (int) (size / 2 + 3))) {
- InternetUtils.browseLink(url);
+ NetworkUtils.browseLink(url);
}
}
diff --git a/src/main/java/cc/polyfrost/oneconfig/utils/InternetUtils.java b/src/main/java/cc/polyfrost/oneconfig/utils/NetworkUtils.java
index 6d6d7ed..3192a2e 100644
--- a/src/main/java/cc/polyfrost/oneconfig/utils/InternetUtils.java
+++ b/src/main/java/cc/polyfrost/oneconfig/utils/NetworkUtils.java
@@ -11,7 +11,7 @@ import java.net.URL;
import java.nio.charset.StandardCharsets;
import java.security.MessageDigest;
-public class InternetUtils {
+public class NetworkUtils {
private static InputStream setupConnection(String url, String userAgent, int timeout, boolean useCaches) throws IOException {
HttpURLConnection connection = ((HttpURLConnection) new URL(url).openConnection());
connection.setRequestMethod("GET");