bibliothek.gui.dock.common.menu
Class CLookAndFeelMenuPiece

java.lang.Object
  extended by bibliothek.gui.dock.support.menu.MenuPiece
      extended by bibliothek.gui.dock.support.menu.BaseMenuPiece
          extended by bibliothek.gui.dock.facile.menu.LookAndFeelMenuPiece
              extended by bibliothek.gui.dock.common.menu.CLookAndFeelMenuPiece
All Implemented Interfaces:
DestroyHook

public class CLookAndFeelMenuPiece
extends LookAndFeelMenuPiece
implements DestroyHook

A menupiece that shows an entry for each available LookAndFeel. The user can select a LookAndFeel which will be set immediately.

Author:
Benjamin Sigg

Constructor Summary
CLookAndFeelMenuPiece(CControl control)
          Creates a new menu.
CLookAndFeelMenuPiece(CControl control, LookAndFeelList list)
          Creates a new menu.
 
Method Summary
 void bind()
          This method is called if there is a possibility for the user to see this menu.
 void destroy()
          Deprecated. 
 void unbind()
          This method is called if the user has no longer any possibility to see this menu.
 
Methods inherited from class bibliothek.gui.dock.facile.menu.LookAndFeelMenuPiece
getList
 
Methods inherited from class bibliothek.gui.dock.support.menu.BaseMenuPiece
add, addSeparator, fill, getItem, getItemCount, insert, insertSeparator, remove, remove, removeAll
 
Methods inherited from class bibliothek.gui.dock.support.menu.MenuPiece
addListener, fireInsert, fireRemove, getMenu, getParent, isBound, items, removeListener, setParent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CLookAndFeelMenuPiece

public CLookAndFeelMenuPiece(CControl control)
Creates a new menu.

Parameters:
control - needed to load the last LookAndFeel

CLookAndFeelMenuPiece

public CLookAndFeelMenuPiece(CControl control,
                             LookAndFeelList list)
Creates a new menu.

Parameters:
control - needed to access the list of dockables
list - the list of available LookAndFeels, can be null
Method Detail

bind

public void bind()
Description copied from class: MenuPiece
This method is called if there is a possibility for the user to see this menu. The menu shoudl register listeners, update its text etc. to be ready for that event. This method must never be called twice in a row.

Overrides:
bind in class LookAndFeelMenuPiece
See Also:
MenuPiece.unbind()

unbind

public void unbind()
Description copied from class: MenuPiece
This method is called if the user has no longer any possibility to see this menu. The menu should unregister its listeners. This method must never be called twice in a row.

Overrides:
unbind in class LookAndFeelMenuPiece
See Also:
MenuPiece.bind()

destroy

@Deprecated
public void destroy()
Deprecated. 

Description copied from class: LookAndFeelMenuPiece
Frees resources and cuts connections to other objects such that this piece can be removed by the garbage collector.

Specified by:
destroy in interface DestroyHook
Overrides:
destroy in class LookAndFeelMenuPiece