Class NullCloseButton

java.lang.Object
ch.swingfx.twinkle.style.closebutton.NullCloseButton
All Implemented Interfaces:
ICloseButton

public class NullCloseButton extends Object implements ICloseButton
A NullCloseButton is an invisible close button. So if you don't want to display a close button use this class.
  • Constructor Details

    • NullCloseButton

      public NullCloseButton()
  • Method Details

    • paintCloseButton

      public void paintCloseButton(Graphics g)
      Description copied from interface: ICloseButton
      Paint the close button
      Specified by:
      paintCloseButton in interface ICloseButton
      Parameters:
      g - Graphics to paint on
    • isMouseOverCloseButton

      public boolean isMouseOverCloseButton(Point mousePosition)
      Description copied from interface: ICloseButton
      Test if the mouse is over the close button
      Specified by:
      isMouseOverCloseButton in interface ICloseButton
      Parameters:
      mousePosition - position of the mouse
      Returns:
      true if mouse if over the button
    • withPosition

      public ICloseButton withPosition(int x, int y)
      Description copied from interface: ICloseButton
      Set the position of the close button
      Specified by:
      withPosition in interface ICloseButton
      Parameters:
      x - x position
      y - y position
      Returns:
      this ICloseButton