diff options
| author | shedaniel <daniel@shedaniel.me> | 2020-01-16 16:10:19 +0800 |
|---|---|---|
| committer | shedaniel <daniel@shedaniel.me> | 2020-01-16 16:10:19 +0800 |
| commit | b4be45e414504afb49910d766bebcd00f55b052b (patch) | |
| tree | 05c36b311681a120c0e3c85131531a159fbc59c2 /src/main/java/me/shedaniel/rei/gui/widget/WidgetWithBounds.java | |
| parent | 01e8ede4fc41f6f113ae623044c3a4e98ed81eb4 (diff) | |
| download | RoughlyEnoughItems-b4be45e414504afb49910d766bebcd00f55b052b.tar.gz RoughlyEnoughItems-b4be45e414504afb49910d766bebcd00f55b052b.tar.bz2 RoughlyEnoughItems-b4be45e414504afb49910d766bebcd00f55b052b.zip | |
3.3.11
Diffstat (limited to 'src/main/java/me/shedaniel/rei/gui/widget/WidgetWithBounds.java')
| -rw-r--r-- | src/main/java/me/shedaniel/rei/gui/widget/WidgetWithBounds.java | 16 |
1 files changed, 1 insertions, 15 deletions
diff --git a/src/main/java/me/shedaniel/rei/gui/widget/WidgetWithBounds.java b/src/main/java/me/shedaniel/rei/gui/widget/WidgetWithBounds.java index 4032a037d..910137d55 100644 --- a/src/main/java/me/shedaniel/rei/gui/widget/WidgetWithBounds.java +++ b/src/main/java/me/shedaniel/rei/gui/widget/WidgetWithBounds.java @@ -5,28 +5,14 @@ package me.shedaniel.rei.gui.widget; -import me.shedaniel.math.api.Point; import me.shedaniel.math.api.Rectangle; public abstract class WidgetWithBounds extends Widget { - abstract public Rectangle getBounds(); - - public final boolean containsMouse(int mouseX, int mouseY) { - return containsMouse((double) mouseX, (double) mouseY); - } - - public final boolean containsMouse(Point point) { - return containsMouse(point.x, point.y); - } + public abstract Rectangle getBounds(); public boolean containsMouse(double mouseX, double mouseY) { return getBounds().contains(mouseX, mouseY); } - @Override - public final boolean isMouseOver(double double_1, double double_2) { - return containsMouse(double_1, double_2); - } - } |
