Modifier and Type | Method and Description |
---|---|
static Window |
windowAncestorOf(Component c)
Similar to
, but returns the
itself if it is a , or the invoker's Window
if on a pop-up. |
@RunsInCurrentThread public static Window windowAncestorOf(Component c)
SwingUtilities.getWindowAncestor(Component)
, but returns the
Component
itself if it is a Window
, or the invoker's Window
if on a pop-up.
Note: This method is not guaranteed to be executed in the event dispatch thread (EDT.) Clients are responsible for calling this method from the EDT.
c
- the Component
to get the Window
ancestor of.Window
ancestor of the given Component
, the Component
itself if
it is a Window
, or the invoker's Window
if on a pop-up.Copyright © 2007-2013 FEST (Fixtures for Easy Software Testing). All Rights Reserved.