Class ButtonSkin

    • Field Detail

      • highlighted

        protected boolean highlighted
    • Constructor Detail

      • ButtonSkin

        public ButtonSkin()
    • Method Detail

      • install

        public void install​(Component component)
        Description copied from class: ComponentSkin
        Must be implemented in every subclass in order to do component-specific operations at instantiation time, but every subclass must call this superclass method to setup the necessary listeners, etc.
        Specified by:
        install in interface Skin
        Overrides:
        install in class ComponentSkin
        Parameters:
        component - The component to which the skin is being attached.
      • layout

        public void layout()
        Description copied from interface: Skin
        If the component on which the skin is installed is a container, lays out the container's children.
        Specified by:
        layout in interface Skin
      • enabledChanged

        public void enabledChanged​(Component component)
        Description copied from interface: ComponentStateListener
        Called when a component's enabled state has changed.

        Called both when the component is enabled and when it is disabled. The component's enabled flag has already been set when this method is called so the new state can be determined by calling the Component.isEnabled() method.

        Specified by:
        enabledChanged in interface ComponentStateListener
        Overrides:
        enabledChanged in class ComponentSkin
        Parameters:
        component - The component whose enabled state is changing.
      • focusedChanged

        public void focusedChanged​(Component component,
                                   Component obverseComponent)
        Description copied from interface: ComponentStateListener
        Called when a component's focused state has changed.

        This will be called both when a component gains focus and when it loses focus. The currently focused component has already been set when this method is called, so that the new state of the component can be determined by calling the Component.isFocused() method.

        Specified by:
        focusedChanged in interface ComponentStateListener
        Overrides:
        focusedChanged in class ComponentSkin
        Parameters:
        component - The component that is either gaining focus or the one that previously had focus and is now losing it.
        obverseComponent - If the component is gaining focus, this is the component that is losing focus. If the component is losing focus this is the component that is gaining the focus instead.
      • buttonDataChanged

        public void buttonDataChanged​(Button button,
                                      java.lang.Object previousButtonData)
        Description copied from interface: ButtonListener
        Called when a button's data has changed.
        Specified by:
        buttonDataChanged in interface ButtonListener
        Parameters:
        button - The button that changed.
        previousButtonData - The previous value of the button data.
      • dataRendererChanged

        public void dataRendererChanged​(Button button,
                                        Button.DataRenderer previousDataRenderer)
        Description copied from interface: ButtonListener
        Called when a button's data renderer has changed.
        Specified by:
        dataRendererChanged in interface ButtonListener
        Parameters:
        button - The button that changed.
        previousDataRenderer - The previous data renderer for the button.
      • actionChanged

        public void actionChanged​(Button button,
                                  Action previousAction)
        Description copied from interface: ButtonListener
        Called when a button's action has changed.
        Specified by:
        actionChanged in interface ButtonListener
        Parameters:
        button - The button that changed.
        previousAction - The previous action that was assigned to the button.
      • toggleButtonChanged

        public void toggleButtonChanged​(Button button)
        Description copied from interface: ButtonListener
        Called when a button's toggle button flag has changed.
        Specified by:
        toggleButtonChanged in interface ButtonListener
        Parameters:
        button - The button that changed.
      • triStateChanged

        public void triStateChanged​(Button button)
        Description copied from interface: ButtonListener
        Called when a button's tri-state flag has changed.
        Specified by:
        triStateChanged in interface ButtonListener
        Parameters:
        button - The button that changed.
      • buttonGroupChanged

        public void buttonGroupChanged​(Button button,
                                       ButtonGroup previousButtonGroup)
        Description copied from interface: ButtonListener
        Called when a button's button group has changed.
        Specified by:
        buttonGroupChanged in interface ButtonListener
        Parameters:
        button - The button whose group changed.
        previousButtonGroup - The button group the button used to belong to (can be null).
      • stateChanged

        public void stateChanged​(Button button,
                                 Button.State previousState)
        Description copied from interface: ButtonStateListener
        Called when a button's state has changed.
        Specified by:
        stateChanged in interface ButtonStateListener
        Parameters:
        button - The button whose state changed.
        previousState - The previous state of the button.