MidnightLib 1.4.1 - Fix tabs & Re-enable Quilt and Forge

- Fix tabs not being visible
- Re-enable Forge and Quilt support
- Fix #28
This commit is contained in:
Motschen
2023-06-09 18:46:53 +02:00
parent 9074abc331
commit dbbf546551
5 changed files with 18 additions and 15 deletions

View File

@@ -214,7 +214,6 @@ public abstract class MidnightConfig {
}
}
tabNavigation = TabNavigationWidget.builder(tabManager, this.width).tabs(tabs.values().toArray(new Tab[0])).build();
if (tabs.size() > 1) this.addDrawableChild(tabNavigation);
tabNavigation.selectTab(0, false);
tabNavigation.init();
prevTab = tabManager.getCurrentTab();
@@ -276,6 +275,9 @@ public abstract class MidnightConfig {
@Override
public void init() {
super.init();
tabNavigation.setWidth(this.width);
tabNavigation.init();
if (tabs.size() > 1) this.addDrawableChild(tabNavigation);
this.addDrawableChild(ButtonWidget.builder(ScreenTexts.CANCEL, button -> {
loadValues();