Class OverlayTextInputAction

java.lang.Object
app.ui.windows.Window
app.ui.windows.WindowOverlayClass
app.ui.overlayactions.OverlayTextInputAction
Direct Known Subclasses:
OverlayTextInputActionToggles

public class OverlayTextInputAction extends WindowOverlayClass
The OverlayTextInputAction class represents an overlay window for receiving text input with options to enter or cancel. It extends the WindowOverlayClass and implements the ICallBack interface.
  • Field Details

    • exitButton

      protected WidgetButton exitButton
      The button to exit the text input.
    • abordButton

      protected WidgetButton abordButton
      The button to abort the text input.
    • textInput

      protected WidgetTextBox textInput
      The text input box.
    • abord

      protected boolean abord
      Indicates whether the text input is aborted.
  • Constructor Details

    • OverlayTextInputAction

      public OverlayTextInputAction(int x, int offsetY, int offsetX, String windowName, String prompt, Window callbackWindow)
      Constructs an instance of OverlayTextInputAction.
      Parameters:
      x - The x-coordinate of the window.
      offsetY - The y-coordinate offset of the window.
      offsetX - The x-coordinate offset of the window.
      windowName - The name of the window.
      prompt - The prompt message for text input.
      callbackWindow - The callback window to notify upon completion.
    • OverlayTextInputAction

      public OverlayTextInputAction(int x, int offsetY, int offsetX, String windowName, String prompt, Window callbackWindow, int returnCode)
      Constructs an instance of OverlayTextInputAction with a specified return code.
      Parameters:
      x - The x-coordinate of the window.
      offsetY - The y-coordinate offset of the window.
      offsetX - The x-coordinate offset of the window.
      windowName - The name of the window.
      prompt - The prompt message for text input.
      callbackWindow - The callback window to notify upon completion.
      returnCode - The return code to be passed to the callback window.
    • OverlayTextInputAction

      public OverlayTextInputAction(int x, int offsetY, int offsetX, String windowName, String prompt, Window callbackWindow, String loadText)
      Constructs an instance of OverlayTextInputAction with a specified pre-loaded text.
      Parameters:
      x - The x-coordinate of the window.
      offsetY - The y-coordinate offset of the window.
      offsetX - The x-coordinate offset of the window.
      windowName - The name of the window.
      prompt - The prompt message for text input.
      callbackWindow - The callback window to notify upon completion.
      loadText - The pre-loaded text in the text input box.
  • Method Details

    • messageLoop

      public void messageLoop()
      Handles the message loop for the overlay window.
      Overrides:
      messageLoop in class WindowOverlayClass
    • onExit

      public void onExit()
      Performs actions upon exiting the overlay window.
      Overrides:
      onExit in class Window