Package bibliothek.gui.dock.facile.menu
Class PreferenceMenuPiece
java.lang.Object
bibliothek.gui.dock.support.menu.MenuPiece
bibliothek.gui.dock.support.menu.BaseMenuPiece
bibliothek.gui.dock.facile.menu.PreferenceMenuPiece
A menu piece that allows the user to change the preferences of the framework.
- Author:
- Benjamin Sigg
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCreates a new unlinked menu piecePreferenceMenuPiece(DockController controller) Creates a new menu piece -
Method Summary
Modifier and TypeMethodDescriptionvoidbind()This method is called if there is a possibility for the user to see this menu.protected PreferenceTreeModelCreates a new model for this piece.Gets the controller for which this piece works.getModel()voidsetController(DockController controller) Sets the controller for which this piece works.voidunbind()This method is called if the user has no longer any possibility to see this menu.Methods inherited from class bibliothek.gui.dock.support.menu.BaseMenuPiece
add, addSeparator, fill, getItem, getItemCount, insert, insertSeparator, remove, remove, removeAllMethods inherited from class bibliothek.gui.dock.support.menu.MenuPiece
addListener, fireInsert, fireRemove, getMenu, getParent, isBound, items, removeListener, setParent
-
Constructor Details
-
PreferenceMenuPiece
protected PreferenceMenuPiece()Creates a new unlinked menu piece -
PreferenceMenuPiece
Creates a new menu piece- Parameters:
controller- the controller for which this piece will work
-
-
Method Details
-
createModel
Creates a new model for this piece.- Returns:
- the model
-
getModel
-
bind
public void bind()Description copied from class:MenuPieceThis method is called if there is a possibility for the user to see this menu. The menu should register listeners, update its text etc. to be ready for that event. This method must never be called twice in a row. -
unbind
public void unbind()Description copied from class:MenuPieceThis 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. -
setController
Sets the controller for which this piece works.- Parameters:
controller- the controller
-
getController
Gets the controller for which this piece works.- Returns:
- the controller
-