aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/me/shedaniel/rei/impl/RecipeHelperImpl.java
diff options
context:
space:
mode:
authorUnknown <shekwancheung0528@gmail.com>2019-08-18 01:50:55 +0800
committerUnknown <shekwancheung0528@gmail.com>2019-08-18 01:50:55 +0800
commitb65de8ed7fe045df451130e3c790613c4f002e2c (patch)
tree3412946f5dbf218e34bb7e7b94694768dae89e97 /src/main/java/me/shedaniel/rei/impl/RecipeHelperImpl.java
parent2000b84ad41de1b4729b153091699baad15d6237 (diff)
downloadRoughlyEnoughItems-b65de8ed7fe045df451130e3c790613c4f002e2c.tar.gz
RoughlyEnoughItems-b65de8ed7fe045df451130e3c790613c4f002e2c.tar.bz2
RoughlyEnoughItems-b65de8ed7fe045df451130e3c790613c4f002e2c.zip
Bye Bye java.awt
Diffstat (limited to 'src/main/java/me/shedaniel/rei/impl/RecipeHelperImpl.java')
-rw-r--r--src/main/java/me/shedaniel/rei/impl/RecipeHelperImpl.java7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/main/java/me/shedaniel/rei/impl/RecipeHelperImpl.java b/src/main/java/me/shedaniel/rei/impl/RecipeHelperImpl.java
index 5f2b7dacc..42eaba8dd 100644
--- a/src/main/java/me/shedaniel/rei/impl/RecipeHelperImpl.java
+++ b/src/main/java/me/shedaniel/rei/impl/RecipeHelperImpl.java
@@ -7,6 +7,7 @@ package me.shedaniel.rei.impl;
import com.google.common.collect.Lists;
import com.google.common.collect.Maps;
+import me.shedaniel.math.api.Rectangle;
import me.shedaniel.rei.RoughlyEnoughItemsCore;
import me.shedaniel.rei.api.*;
import me.shedaniel.rei.api.plugins.REIPluginV0;
@@ -20,8 +21,6 @@ import net.minecraft.recipe.RecipeManager;
import net.minecraft.util.ActionResult;
import net.minecraft.util.Identifier;
-import java.awt.*;
-import java.util.List;
import java.util.*;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.function.Function;
@@ -198,7 +197,7 @@ public class RecipeHelperImpl implements RecipeHelper {
@Override
public Optional<ButtonAreaSupplier> getSpeedCraftButtonArea(RecipeCategory category) {
if (!speedCraftAreaSupplierMap.containsKey(category.getIdentifier()))
- return Optional.ofNullable(bounds -> new Rectangle((int) bounds.getMaxX() - 16, (int) bounds.getMaxY() - 16, 10, 10));
+ return Optional.ofNullable(bounds -> new Rectangle(bounds.getMaxX() - 16, bounds.getMaxY() - 16, 10, 10));
return Optional.ofNullable(speedCraftAreaSupplierMap.get(category.getIdentifier()));
}
@@ -214,7 +213,7 @@ public class RecipeHelperImpl implements RecipeHelper {
@SuppressWarnings("deprecation")
@Override
public void registerDefaultSpeedCraftButtonArea(Identifier category) {
- registerSpeedCraftButtonArea(category, bounds -> new Rectangle((int) bounds.getMaxX() - 16, (int) bounds.getMaxY() - 16, 10, 10));
+ registerSpeedCraftButtonArea(category, bounds -> new Rectangle(bounds.getMaxX() - 16, bounds.getMaxY() - 16, 10, 10));
}
@SuppressWarnings("deprecation")