Class EditorManager
java.lang.Object
de.luckymcdev.foundryengine.client.editor.EditorManager
The BuiltInEditor is a Handlder for all Panels.
To add a Panel to this Editor, register it via
RegisterPanelEvent
Methods provided are for opening and closing as well as registering / removing Panels from the Registry.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidCloses All Panels managed by the EditorManager.voidclosePanel(Panel panel) Closes a PanelGenericRegistry<net.minecraft.resources.Identifier, Panel> Returns theGenericRegistrywhich contains all PanelsvoidCalls thePanel.handleRender()method for all managed Panels.voidCalls thePanel.handleTick()method for all managed Panels.booleanReturns if a Panel is currently Open.voidOpens a PanelvoidRegisters a Panel.voidRemoves a PanelvoidtogglePanel(Panel panel) Toggles a Panel between Open and Close depending on current State.
-
Constructor Details
-
EditorManager
public EditorManager()
-
-
Method Details
-
register
-
remove
-
openPanel
-
closePanel
-
togglePanel
Toggles a Panel between Open and Close depending on current State.- Parameters:
panel- the Panel to Toggle.
-
isOpen
Returns if a Panel is currently Open. INFO: Panel open State is managed by the Panel itself.Panel.open- Parameters:
panel- the Panel to check- Returns:
- the current openState.
-
closeAllPanels
public void closeAllPanels()Closes All Panels managed by the EditorManager. -
handleTick
public void handleTick()Calls thePanel.handleTick()method for all managed Panels. -
handleRender
public void handleRender()Calls thePanel.handleRender()method for all managed Panels. -
getPanels
Returns theGenericRegistrywhich contains all Panels- Returns:
- the Panel Registry.
-