Class MapGeneratorButton

All Implemented Interfaces:
EventListener, javafx.event.EventHandler<javafx.event.ActionEvent>

public class MapGeneratorButton extends Object implements javafx.event.EventHandler<javafx.event.ActionEvent>
MapGeneratorButton acts as the event handler for the actual JavaFX button that will generate a map.
  • Constructor Details

    • MapGeneratorButton

      public MapGeneratorButton(@NotNull @NotNull MapGeneratorInterpreterInterface interpreter, @NotNull @NotNull Toggler toggler)
      Create a new MapGeneratorButton.
      interpreter - the interpreter for the map generator button
      toggler - the toggler used to close the user interface once pressed.
  • Method Details

    • handle

      public void handle(javafx.event.ActionEvent event)
      This method is called when the button is pressed. It passes control to the appropriate interpreter.
      Specified by:
      handle in interface javafx.event.EventHandler<javafx.event.ActionEvent>
      event - the event which occurred