Package org.ka2ddo.yaac.gui
Class WindowPersister
java.lang.Object
org.ka2ddo.yaac.gui.WindowPersister
- All Implemented Interfaces:
ComponentListener
,WindowListener
,Iterable<Map.Entry<Window,
,String>> EventListener
public class WindowPersister
extends Object
implements ComponentListener, WindowListener, Iterable<Map.Entry<Window,String>>
This class manages persisting the location and size of windows in the YAAC
application.
- Author:
- Andrew Pavlin, KA2DDO
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Register another listener for top-level window changes.void
DO NOT CALL.void
DO NOT CALL.void
DO NOT CALL.void
DO NOT CALL.static WindowPersister
Get the singleton WindowPersister object.iterator()
Returns an iterator over the currently monitored set of Windows.void
Register a Window for having its position and sizing persisted (and restored, if previously persisted values are found).void
Deregister a listener for top-level window changes.void
DO NOT CALL.void
DO NOT CALL.void
DO NOT CALL.void
DO NOT CALL.void
DO NOT CALL.void
DO NOT CALL.void
DO NOT CALL.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Method Details
-
getInstance
Get the singleton WindowPersister object.- Returns:
- the WindowPersister
-
register
Register a Window for having its position and sizing persisted (and restored, if previously persisted values are found).- Parameters:
window
- Window whose size and screen location should be preservedname
- unique identification String of the Window's content
-
addWindowPersisterListener
Register another listener for top-level window changes.- Parameters:
l
- WindowPersisterListener
-
removeWindowPersisterListener
Deregister a listener for top-level window changes.- Parameters:
l
- WindowPersisterListener
-
iterator
Returns an iterator over the currently monitored set of Windows. -
componentHidden
DO NOT CALL.- Specified by:
componentHidden
in interfaceComponentListener
- Parameters:
e
- ComponentEvent
-
componentMoved
DO NOT CALL.- Specified by:
componentMoved
in interfaceComponentListener
- Parameters:
e
- ComponentEvent
-
componentResized
DO NOT CALL.- Specified by:
componentResized
in interfaceComponentListener
- Parameters:
e
- ComponentEvent
-
componentShown
DO NOT CALL.- Specified by:
componentShown
in interfaceComponentListener
- Parameters:
e
- ComponentEvent
-
windowActivated
DO NOT CALL.- Specified by:
windowActivated
in interfaceWindowListener
- Parameters:
e
- WindowEvent
-
windowClosed
DO NOT CALL.- Specified by:
windowClosed
in interfaceWindowListener
- Parameters:
e
- WindowEvent
-
windowClosing
DO NOT CALL.- Specified by:
windowClosing
in interfaceWindowListener
- Parameters:
e
- WindowEvent
-
windowDeactivated
DO NOT CALL.- Specified by:
windowDeactivated
in interfaceWindowListener
- Parameters:
e
- WindowEvent
-
windowDeiconified
DO NOT CALL.- Specified by:
windowDeiconified
in interfaceWindowListener
- Parameters:
e
- WindowEvent
-
windowIconified
DO NOT CALL.- Specified by:
windowIconified
in interfaceWindowListener
- Parameters:
e
- WindowEvent
-
windowOpened
DO NOT CALL.- Specified by:
windowOpened
in interfaceWindowListener
- Parameters:
e
- WindowEvent
-