Package gaiasky.gui

Class GuiRegistry

java.lang.Object
gaiasky.gui.GuiRegistry
All Implemented Interfaces:
IObserver

public class GuiRegistry extends Object implements IObserver
  • Field Details Link icon

    • scene Link icon

      protected final Scene scene
      Scene reference.
    • modeChangeInfoPopup Link icon

      public com.badlogic.gdx.scenes.scene2d.ui.Table modeChangeInfoPopup
      Mode change info popup.
    • current Link icon

      public IGui current
      Current GUI object.
    • previous Link icon

      public IGui previous
      Previous GUI object, if any.
  • Constructor Details Link icon

    • GuiRegistry Link icon

      public GuiRegistry(com.badlogic.gdx.scenes.scene2d.ui.Skin skin, Scene scene, CatalogManager catalogManager)
      Create new GUI registry object.
  • Method Details Link icon

    • getInputMultiplexer Link icon

      public com.badlogic.gdx.InputMultiplexer getInputMultiplexer()
    • setInputMultiplexer Link icon

      public void setInputMultiplexer(com.badlogic.gdx.InputMultiplexer inputMultiplexer)
    • change Link icon

      public void change(IGui gui, IGui previous)
      Switches the current GUI with the given one, updating the processors. It also sets the previous GUI to the given value.
      Parameters:
      gui - The new GUI.
      previous - The new previous GUI.
    • change Link icon

      public void change(IGui gui)
      Switches the current GUI with the given one, updating the processors.
      Parameters:
      gui - The new gui.
    • unset Link icon

      public void unset()
      Unsets the current GUI and sets it as previous.
    • unset Link icon

      public void unset(IGui gui)
      Unsets the given GUI and sets it as previous.
      Parameters:
      gui - The GUI.
    • set Link icon

      public void set(IGui gui)
      Sets the given GUI as current.
      Parameters:
      gui - The new GUI.
    • setPrevious Link icon

      public void setPrevious(IGui gui)
      Sets the given GUI as previous.
      Parameters:
      gui - The new previous GUI.
    • registerGui Link icon

      public void registerGui(IGui gui)
      Registers a new GUI.
      Parameters:
      gui - The GUI to register.
    • unregisterGui Link icon

      public void unregisterGui(IGui gui)
      Unregisters a GUI.
      Parameters:
      gui - The GUI to unregister.
    • unregisterAll Link icon

      public void unregisterAll()
      Unregisters all GUIs.
    • render Link icon

      public void render(int rw, int rh)
      Renders the registered GUIs.
      Parameters:
      rw - The render width.
      rh - The render height.
    • addProcessor Link icon

      public void addProcessor(IGui gui)
      Adds the stage of the given GUI to the processors in the input multiplexer.
      Parameters:
      gui - The gui.
    • removeProcessor Link icon

      public void removeProcessor(IGui gui)
    • update Link icon

      public void update(double dt)
      Updates the registered GUIs.
      Parameters:
      dt - The delta time in seconds.
    • publishReleaseNotes Link icon

      public void publishReleaseNotes()
    • dispose Link icon

      public void dispose()
    • notify Link icon

      public void notify(Event event, Object source, Object... data)
      Description copied from interface: IObserver
      Event notification call.
      Specified by:
      notify in interface IObserver
      Parameters:
      event - The event type.
      source - The source object, if any.
      data - The data associated with this event.
    • removeGamepadGui Link icon

      public boolean removeGamepadGui()
    • removeModeChangePopup Link icon

      public boolean removeModeChangePopup()