Class Button

  • All Implemented Interfaces:
    Drawable, Updatable

    public class Button
    extends Widget
    Simple button widget with graphics and interaction entirely managed by the renderer, not using the native widget. Buttons can consist of a flat background or an image background, combined with a text label.
    • Constructor Detail

      • Button

        public Button​(WidgetStyle style,
                      java.lang.String label)
    • Method Detail

      • setClickHandler

        public void setClickHandler​(InputDevice input,
                                    java.lang.Runnable onClick)
      • update

        public void update​(float deltaTime)
        Description copied from interface: Updatable
        Updates this object for the current frame.
        Parameters:
        deltaTime - Elapsed time since the last frame, in seconds.