bibliothek.gui.dock.common
Class DefaultMultipleCDockable

java.lang.Object
  extended by bibliothek.gui.dock.common.intern.AbstractCDockable
      extended by bibliothek.gui.dock.common.intern.DefaultCDockable
          extended by bibliothek.gui.dock.common.DefaultMultipleCDockable
All Implemented Interfaces:
CDockable, MultipleCDockable

@ClientOnly
public class DefaultMultipleCDockable
extends DefaultCDockable
implements MultipleCDockable

A MultipleCDockable that contains a content-pane where the client might add or remove as many Components as it wishes.

Author:
Benjamin Sigg
See Also:
MultipleCDockable

Nested Class Summary
 
Nested classes/interfaces inherited from class bibliothek.gui.dock.common.intern.DefaultCDockable
DefaultCDockable.Permissions
 
Field Summary
 
Fields inherited from class bibliothek.gui.dock.common.intern.AbstractCDockable
listenerCollection
 
Fields inherited from interface bibliothek.gui.dock.common.intern.CDockable
ACTION_KEY_CLOSE, ACTION_KEY_EXTERNALIZE, ACTION_KEY_MAXIMIZE, ACTION_KEY_MINIMIZE, ACTION_KEY_NORMALIZE, ACTION_KEY_UNEXTERNALIZE, ACTION_KEY_UNMAXIMIZE_EXTERNALIZED
 
Constructor Summary
DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory, CAction... actions)
          Creates a new dockable
DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory, java.awt.Component content, CAction... actions)
          Creates a new dockable.
DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory, javax.swing.Icon icon, CAction... actions)
          Creates a new dockable.
DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory, javax.swing.Icon icon, java.awt.Component content, CAction... actions)
          Creates a new dockable.
DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory, javax.swing.Icon icon, java.lang.String title, CAction... actions)
          Creates a new dockable.
DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory, javax.swing.Icon icon, java.lang.String title, java.awt.Component content, CAction... actions)
          Creates a new dockable.
DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory, javax.swing.Icon icon, java.lang.String title, java.awt.Component content, DefaultCDockable.Permissions permissions, CAction... actions)
          Creates a new dockable.
DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory, java.lang.String title, CAction... actions)
          Creates a new dockable.
DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory, java.lang.String title, java.awt.Component content, CAction... actions)
          Creates a new dockable.
 
Method Summary
 MultipleCDockableFactory<?,?> getFactory()
          Gets the factory that created this dockable.
 boolean isRemoveOnClose()
          Tells whether this MultipleCDockable should be removed from the CControl when it is made invisible.
 void setControl(CControlAccess control)
          Sets the CControl which is responsible for this dockable.
 void setRemoveOnClose(boolean removeOnClose)
          Sets whether this dockable will be removed from the CControl when made invisible.
 
Methods inherited from class bibliothek.gui.dock.common.intern.DefaultCDockable
add, add, addAction, addSeparator, asStation, createCommonDockable, getAction, getActionCount, getContentPane, getTitleIcon, getTitleText, getTitleToolTip, insertAction, insertSeparator, intern, isCloseable, isExternalizable, isMaximizable, isMinimizable, isStackable, remove, removeAction, removeAction, setCloseable, setExternalizable, setLayout, setMaximizable, setMinimizable, setStackable, setTitleIcon, setTitleText, setTitleToolTip
 
Methods inherited from class bibliothek.gui.dock.common.intern.AbstractCDockable
addCDockableLocationListener, addCDockablePropertyListener, addCDockableStateListener, addDoubleClickListener, addFocusListener, addKeyboardListener, addVetoClosingListener, control, getAction, getAndClearResizeRequest, getBaseLocation, getClose, getColors, getControl, getDefaultLocation, getExtendedMode, getFocusComponent, getFonts, getMinimizedSize, getWorkingArea, hasParent, init, isDockableVisible, isMinimizedHold, isResizeLocked, isResizeLockedHorizontally, isResizeLockedVertically, isSingleTabShown, isTitleShown, isVisible, propertyListeners, putAction, removeCDockableLocationListener, removeCDockablePropertyListener, removeCDockableStateListener, removeDoubleClickListener, removeFocusListener, removeKeyboardListener, removeVetoClosingListener, setDefaultLocation, setExtendedMode, setFocusComponent, setLocation, setMinimizedHold, setMinimizedSize, setResizeLocked, setResizeLockedHorizontally, setResizeLockedVertically, setResizeRequest, setResizeRequest, setSingleTabShown, setTitleShown, setVisible, setWorkingArea, stateListeners, toFront
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface bibliothek.gui.dock.common.intern.CDockable
addCDockableLocationListener, addCDockablePropertyListener, addCDockableStateListener, addDoubleClickListener, addFocusListener, addKeyboardListener, addVetoClosingListener, asStation, getAction, getAndClearResizeRequest, getBaseLocation, getColors, getControl, getExtendedMode, getFocusComponent, getFonts, getMinimizedSize, getWorkingArea, hasParent, intern, isCloseable, isDockableVisible, isExternalizable, isMaximizable, isMinimizable, isMinimizedHold, isResizeLockedHorizontally, isResizeLockedVertically, isSingleTabShown, isStackable, isTitleShown, isVisible, removeCDockableLocationListener, removeCDockablePropertyListener, removeCDockableStateListener, removeDoubleClickListener, removeFocusListener, removeKeyboardListener, removeVetoClosingListener, setExtendedMode, setLocation, setMinimizedHold, setMinimizedSize, setVisible, setWorkingArea
 

Constructor Detail

DefaultMultipleCDockable

public DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory,
                                CAction... actions)
Creates a new dockable

Parameters:
factory - the factory which created or could create this kind of dockable.
actions - the actions shown in the title, can be null. A separator is inserted for every entry that is null of this array.

DefaultMultipleCDockable

public DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory,
                                java.awt.Component content,
                                CAction... actions)
Creates a new dockable.

Parameters:
factory - the factory which created or could create this kind of dockable.
content - a Component which will be shown in the middle of this dockable, can be null.
actions - the actions shown in the title, can be null. A separator is inserted for every entry that is null of this array.

DefaultMultipleCDockable

public DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory,
                                java.lang.String title,
                                java.awt.Component content,
                                CAction... actions)
Creates a new dockable.

Parameters:
factory - the factory which created or could create this kind of dockable.
title - the text shown in the title, can be null
content - a Component which will be shown in the middle of this dockable, can be null.
actions - the actions shown in the title, can be null. A separator is inserted for every entry that is null of this array.

DefaultMultipleCDockable

public DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory,
                                javax.swing.Icon icon,
                                java.awt.Component content,
                                CAction... actions)
Creates a new dockable.

Parameters:
factory - the factory which created or could create this kind of dockable.
icon - the icon shown in the title, can be null
content - a Component which will be shown in the middle of this dockable, can be null.
actions - the actions shown in the title, can be null. A separator is inserted for every entry that is null of this array.

DefaultMultipleCDockable

public DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory,
                                javax.swing.Icon icon,
                                java.lang.String title,
                                java.awt.Component content,
                                CAction... actions)
Creates a new dockable.

Parameters:
factory - the factory which created or could create this kind of dockable.
icon - the icon shown in the title, can be null
title - the text shown in the title, can be null
content - a Component which will be shown in the middle of this dockable, can be null.
actions - the actions shown in the title, can be null. A separator is inserted for every entry that is null of this array.

DefaultMultipleCDockable

public DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory,
                                java.lang.String title,
                                CAction... actions)
Creates a new dockable.

Parameters:
factory - the factory which created or could create this kind of dockable.
title - the text shown in the title, can be null
actions - the actions shown in the title, can be null. A separator is inserted for every entry that is null of this array.

DefaultMultipleCDockable

public DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory,
                                javax.swing.Icon icon,
                                CAction... actions)
Creates a new dockable.

Parameters:
factory - the factory which created or could create this kind of dockable.
icon - the icon shown in the title, can be null
actions - the actions shown in the title, can be null. A separator is inserted for every entry that is null of this array.

DefaultMultipleCDockable

public DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory,
                                javax.swing.Icon icon,
                                java.lang.String title,
                                CAction... actions)
Creates a new dockable.

Parameters:
factory - the factory which created or could create this kind of dockable.
icon - the icon shown in the title, can be null
title - the text shown in the title, can be null
actions - the actions shown in the title, can be null. A separator is inserted for every entry that is null of this array.

DefaultMultipleCDockable

public DefaultMultipleCDockable(MultipleCDockableFactory<?,?> factory,
                                javax.swing.Icon icon,
                                java.lang.String title,
                                java.awt.Component content,
                                DefaultCDockable.Permissions permissions,
                                CAction... actions)
Creates a new dockable.

Parameters:
factory - the factory which created or could create this kind of dockable.
icon - the icon shown in the title, can be null
title - the text shown in the title, can be null
content - a Component which will be shown in the middle of this dockable, can be null.
permissions - what actions the user is allowed to do, null will be replaced by DefaultCDockable.Permissions#DEFAULT.
actions - the actions shown in the title, can be null. A separator is inserted for every entry that is null of this array.
Method Detail

getFactory

public MultipleCDockableFactory<?,?> getFactory()
Gets the factory that created this dockable.

Specified by:
getFactory in interface MultipleCDockable
Returns:
the factory, not null

setControl

public void setControl(CControlAccess control)
Description copied from class: AbstractCDockable
Sets the CControl which is responsible for this dockable.

Specified by:
setControl in interface CDockable
Overrides:
setControl in class AbstractCDockable
Parameters:
control - the new control

isRemoveOnClose

public boolean isRemoveOnClose()
Description copied from interface: MultipleCDockable
Tells whether this MultipleCDockable should be removed from the CControl when it is made invisible. If in doubt, return true.

Specified by:
isRemoveOnClose in interface MultipleCDockable
Returns:
true if this dockable should be removed from the controller when made invisible.

setRemoveOnClose

public void setRemoveOnClose(boolean removeOnClose)
Sets whether this dockable will be removed from the CControl when made invisible.

Parameters:
removeOnClose - true if this element should be removed automatically.