bibliothek.gui.dock.station.flap
Class DefaultFlapWindowFactory

java.lang.Object
  extended by bibliothek.gui.dock.station.flap.DefaultFlapWindowFactory
All Implemented Interfaces:
FlapWindowFactory

public class DefaultFlapWindowFactory
extends Object
implements FlapWindowFactory

This default implementation of FlapWindowFactory creates new DefaultFlapWindows.

Author:
Benjamin Sigg

Constructor Summary
DefaultFlapWindowFactory()
           
 
Method Summary
 FlapWindow create(FlapDockStation station, ButtonPane buttonPane)
          Creates a new window for station.
protected  JDesktopPane getDesktopPaneOf(FlapDockStation station)
          Searches the JDesktopPane which shows station.
 void install(FlapDockStation station)
          Informs this factory that it will be used by station.
 boolean isValid(FlapWindow window, FlapDockStation station)
          Tells whether window can still be used by station.
 void uninstall(FlapDockStation station)
          Informs this factory that it will no longer be used by station.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultFlapWindowFactory

public DefaultFlapWindowFactory()
Method Detail

create

public FlapWindow create(FlapDockStation station,
                         ButtonPane buttonPane)
Description copied from interface: FlapWindowFactory
Creates a new window for station.

Specified by:
create in interface FlapWindowFactory
Parameters:
station - a known client of this factory
buttonPane - the panel which actually shows the buttons of station, may be needed to calculate the location and size of the window.
Returns:
the new window or null if this factory is unable to create a valid window for station

install

public void install(FlapDockStation station)
Description copied from interface: FlapWindowFactory
Informs this factory that it will be used by station.

Specified by:
install in interface FlapWindowFactory
Parameters:
station - a new client of this factory

isValid

public boolean isValid(FlapWindow window,
                       FlapDockStation station)
Description copied from interface: FlapWindowFactory
Tells whether window can still be used by station.

Specified by:
isValid in interface FlapWindowFactory
Parameters:
window - a window create by this factory, was not yet destroied
station - the owner of window
Returns:
true if station can show another Dockable on window

uninstall

public void uninstall(FlapDockStation station)
Description copied from interface: FlapWindowFactory
Informs this factory that it will no longer be used by station.

Specified by:
uninstall in interface FlapWindowFactory
Parameters:
station - a withdrawing client

getDesktopPaneOf

protected JDesktopPane getDesktopPaneOf(FlapDockStation station)
Searches the JDesktopPane which shows station.

Parameters:
station - the station whose parent is searched
Returns:
the parent or null