Class BasicPopupPanelUI.WindowTracker
java.lang.Object
org.pushingpixels.radiance.component.internal.ui.common.popup.BasicPopupPanelUI.WindowTracker
- All Implemented Interfaces:
AWTEventListener, ComponentListener, WindowListener, EventListener, PopupPanelManager.PopupListener
- Enclosing class:
BasicPopupPanelUI
protected static class BasicPopupPanelUI.WindowTracker
extends Object
implements PopupPanelManager.PopupListener, AWTEventListener, ComponentListener, WindowListener
This class is used to dismiss popup panels on the following events:
- Mouse click outside any shown popup panel.
- Closing, iconifying or deactivation of a top-level window.
- Any change in the component hierarchy of a top-level window.
Only one top-level window is tracked at any time. The assumption is that
the PopupPanelManager only shows popup panels originating from
one top-level window.
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) WindowThe currently tracked window.(package private) List<PopupPanelManager.PopupInfo> Last selected path in thePopupPanelManager. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidvoidvoidvoid(package private) voidgrabWindow(List<PopupPanelManager.PopupInfo> shownPath) Grabs the window of the first popup panel in the specified popup panel sequence.voidFired when a popup panel has been hidden.voidFired when a popup panel has been shown.(package private) voidUngrabs the currently tracked window.voidvoidvoidvoidvoidvoidvoid
-
Field Details
-
grabbedWindow
Window grabbedWindowThe currently tracked window. It is the window of the originating component of the first popup panel in the currently shown sequence ofPopupPanelManager. -
lastPathSelected
List<PopupPanelManager.PopupInfo> lastPathSelectedLast selected path in thePopupPanelManager.
-
-
Constructor Details
-
WindowTracker
public WindowTracker()Creates the new window tracker.
-
-
Method Details
-
grabWindow
Grabs the window of the first popup panel in the specified popup panel sequence.- Parameters:
shownPath- Sequence of the currently shown popup panels.
-
ungrabWindow
void ungrabWindow()Ungrabs the currently tracked window. -
popupShown
Description copied from interface:PopupPanelManager.PopupListenerFired when a popup panel has been shown.- Specified by:
popupShownin interfacePopupPanelManager.PopupListener- Parameters:
event- Popup event.
-
popupHidden
Description copied from interface:PopupPanelManager.PopupListenerFired when a popup panel has been hidden.- Specified by:
popupHiddenin interfacePopupPanelManager.PopupListener- Parameters:
event- Popup event.
-
eventDispatched
- Specified by:
eventDispatchedin interfaceAWTEventListener
-
componentResized
- Specified by:
componentResizedin interfaceComponentListener
-
componentMoved
- Specified by:
componentMovedin interfaceComponentListener
-
componentShown
- Specified by:
componentShownin interfaceComponentListener
-
componentHidden
- Specified by:
componentHiddenin interfaceComponentListener
-
windowClosing
- Specified by:
windowClosingin interfaceWindowListener
-
windowClosed
- Specified by:
windowClosedin interfaceWindowListener
-
windowIconified
- Specified by:
windowIconifiedin interfaceWindowListener
-
windowDeactivated
- Specified by:
windowDeactivatedin interfaceWindowListener
-
windowOpened
- Specified by:
windowOpenedin interfaceWindowListener
-
windowDeiconified
- Specified by:
windowDeiconifiedin interfaceWindowListener
-
windowActivated
- Specified by:
windowActivatedin interfaceWindowListener
-