diff options
| author | shedaniel <daniel@shedaniel.me> | 2020-08-27 20:11:03 +0800 |
|---|---|---|
| committer | shedaniel <daniel@shedaniel.me> | 2020-08-27 20:11:03 +0800 |
| commit | ff9c8e83f0eaf3791e4939b491979d23bdca5577 (patch) | |
| tree | ef323a6dc477a03f05b00c3d2e405f121ec97650 /RoughlyEnoughItems-api/src/main/java/me | |
| parent | 5bf10e476366e9aff291d55c050a324734bae911 (diff) | |
| download | RoughlyEnoughItems-ff9c8e83f0eaf3791e4939b491979d23bdca5577.tar.gz RoughlyEnoughItems-ff9c8e83f0eaf3791e4939b491979d23bdca5577.tar.bz2 RoughlyEnoughItems-ff9c8e83f0eaf3791e4939b491979d23bdca5577.zip | |
Put the search bar to the side automatically if there is no space.
Signed-off-by: shedaniel <daniel@shedaniel.me>
Diffstat (limited to 'RoughlyEnoughItems-api/src/main/java/me')
| -rw-r--r-- | RoughlyEnoughItems-api/src/main/java/me/shedaniel/rei/api/DisplayHelper.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/RoughlyEnoughItems-api/src/main/java/me/shedaniel/rei/api/DisplayHelper.java b/RoughlyEnoughItems-api/src/main/java/me/shedaniel/rei/api/DisplayHelper.java index 6693189ea..517597f8e 100644 --- a/RoughlyEnoughItems-api/src/main/java/me/shedaniel/rei/api/DisplayHelper.java +++ b/RoughlyEnoughItems-api/src/main/java/me/shedaniel/rei/api/DisplayHelper.java @@ -189,10 +189,14 @@ public interface DisplayHelper { * @param rectangle the overlay bounds * @return the item list bounds */ + @Deprecated + @ApiStatus.ScheduledForRemoval default Rectangle getItemListArea(Rectangle rectangle) { return new Rectangle(rectangle.x + 1, rectangle.y + 2 + (ConfigObject.getInstance().getSearchFieldLocation() == SearchFieldLocation.TOP_SIDE ? 24 : 0) + (ConfigObject.getInstance().isEntryListWidgetScrolled() ? 0 : 22), rectangle.width - 2, rectangle.height - (ConfigObject.getInstance().getSearchFieldLocation() != SearchFieldLocation.CENTER ? 27 + 22 : 27) + (!ConfigObject.getInstance().isEntryListWidgetScrolled() ? 0 : 22)); } + @Deprecated + @ApiStatus.ScheduledForRemoval default Rectangle getFavoritesListArea(Rectangle rectangle) { int offset = 31 + (ConfigObject.getInstance().doesShowUtilsButtons() ? 25 : 0); return new Rectangle(rectangle.x + 1, rectangle.y + 2 + offset, rectangle.width - 2, rectangle.height - 5 - offset); |
