forked from RepoMirrors/seppuku
Update proper positioning of module list & hub elements
This commit is contained in:
parent
f264b7fbc3
commit
ed0bd8c187
|
@ -87,7 +87,7 @@ public final class HubComponent extends DraggableHudComponent {
|
|||
|
||||
final boolean inside = mouseX >= this.getX() && mouseX <= this.getX() + this.getW() && mouseY >= this.getY() && mouseY <= this.getY() + this.getH();
|
||||
if (inside && button == 0) {
|
||||
int offsetY = 0;
|
||||
int offsetY = BORDER;
|
||||
for (HudComponent component : Seppuku.INSTANCE.getHudManager().getComponentList()) {
|
||||
if (component != this) {
|
||||
final boolean insideTitlebar = mouseY <= this.getY() + BORDER + Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT + 1;
|
||||
|
|
|
@ -88,7 +88,7 @@ public final class ModuleListComponent extends DraggableHudComponent {
|
|||
|
||||
final boolean inside = mouseX >= this.getX() && mouseX <= this.getX() + this.getW() && mouseY >= this.getY() && mouseY <= this.getY() + this.getH();
|
||||
if (inside && button == 0) {
|
||||
int offsetY = 0;
|
||||
int offsetY = BORDER;
|
||||
for (Module module : Seppuku.INSTANCE.getModuleManager().getModuleList(this.type)) {
|
||||
final boolean insideTitlebar = mouseY <= this.getY() + BORDER + Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT + 1;
|
||||
final boolean insideComponent = mouseX >= (this.getX() + BORDER) && mouseX <= (this.getX() + this.getW() - BORDER - SCROLL_WIDTH) && mouseY >= (this.getY() + BORDER + Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT + 1 + offsetY - this.scroll) && mouseY <= (this.getY() + BORDER + (Minecraft.getMinecraft().fontRenderer.FONT_HEIGHT * 2) + 1 + offsetY - this.scroll);
|
||||
|
|
Loading…
Reference in New Issue