Class AWTEvents

java.lang.Object
org.fest.swing.util.AWTEvents

public final class AWTEvents extends Object
Understands utility methods related to AWT events.
  • Constructor Details

    • AWTEvents

      private AWTEvents()
  • Method Details

    • windowOpened

      public static boolean windowOpened(AWTEvent e)
      Returns true if the id of the given event is equal to WINDOW_OPENED
      Parameters:
      e - the given event.
      Returns:
      true if the id of the given event is equal to WINDOW_OPENED; false otherwise.
    • windowShown

      public static boolean windowShown(AWTEvent e)
      Returns true if the id of the given event is equal to COMPONENT_SHOWN and the source of the event is a Window.
      Parameters:
      e - the given event.
      Returns:
      true if the id of the given event is equal to COMPONENT_SHOWN and the source of the event is a window; false otherwise.
    • windowClosed

      public static boolean windowClosed(AWTEvent e)
      Returns true if the id of the given event is equal to WINDOW_CLOSED
      Parameters:
      e - the given event.
      Returns:
      true if the id of the given event is equal to WINDOW_CLOSED; false otherwise.
    • idEquals

      private static boolean idEquals(AWTEvent e, int expectedId)