Basics

Guides

API Reference

Menu

Basics

Guides

API Reference

class: UIController

[15:7] extends: FxObj

Wraps an AussomUIController (implements FXGL's UIController interface) so Aussom code can act as the controller for an FXML layout. Wire the onInit callback before passing this controller to a UI; FXGL invokes init() after field injection.

Methods

  • UIController ()

    Creates a new UIController bridge.

  • adopt (object Ajo)

    Wraps an existing controller AussomJavaObject.

    • @p Ajo is an AussomJavaObject around an AussomUIController.
    • @r A new wrapper.
  • onInit (callback Cb)

    Registers the onInit callback (fires after FXML field injection completes). The callback takes no arguments.

    • @p Cb is a callback () -> void.
    • @r this object