mirror of
https://github.com/GTNewHorizons/NotEnoughItems.git
synced 2026-11-18 03:25:38 +00:00
Align panels from center to edges
This commit is contained in:
1 parent
805b90d6f8
commit
ebe95b3cf1
3 files changed
+42
-40
No files matched your search
@@ -84,6 +84,10 @@ public abstract class PanelWidget<T extends ItemsGrid<? extends ItemsGridSlot, ?
|
||||
|
||||
public abstract Rectangle4i calculateBounds();
|
||||
|
||||
protected static int snapDownToMultiple(int value, int multiple) {
|
||||
return (value / multiple) * multiple;
|
||||
}
|
||||
|
||||
public void resize(GuiContainer gui) {
|
||||
final Rectangle4i bounds = calculateBounds();
|
||||
|
||||
|
||||
Reference in new issue
Block a user