C# Class Flood.GUI.Controls.Menu

Popup menu.
Inheritance: Flood.GUI.Controls.ScrollControl
Afficher le fichier Open project: FloodProject/flood Class Usage Examples

Private Properties

Свойство Type Description

Méthodes publiques

Méthode Description
AddDivider ( ) : void

Adds a divider menu item.

AddItem ( String text ) : MenuItem

Adds a new menu item.

AddItem ( String text, String iconName, String accelerator = "" ) : MenuItem

Adds a new menu item.

Close ( ) : void

Closes the current menu.

CloseAll ( ) : void

Closes all submenus.

CloseMenus ( ) : void

Closes all submenus and the current menu.

IsMenuOpen ( ) : bool

Indicates whether any (sub)menu is open.

Menu ( Control parent ) : System

Initializes a new instance of the Menu class.

Open ( Pos pos ) : void

Opens the menu.

Méthodes protégées

Méthode Description
Layout ( Skins skin ) : void

Lays out the control's interior according to alignment, padding, dock etc.

OnAddItem ( MenuItem item ) : void

Add item handler.

OnHoverItem ( Control control ) : void

Mouse hover handler.

Render ( Skins skin ) : void

Renders the control using specified skin.

RenderUnder ( Skins skin ) : void

Renders under the actual control (shadows etc).

Method Details

AddDivider() public méthode

Adds a divider menu item.
public AddDivider ( ) : void
Résultat void

AddItem() public méthode

Adds a new menu item.
public AddItem ( String text ) : MenuItem
text String Item text.
Résultat MenuItem

AddItem() public méthode

Adds a new menu item.
public AddItem ( String text, String iconName, String accelerator = "" ) : MenuItem
text String Item text.
iconName String Icon texture name.
accelerator String Accelerator for this item.
Résultat MenuItem

Close() public méthode

Closes the current menu.
public Close ( ) : void
Résultat void

CloseAll() public méthode

Closes all submenus.
public CloseAll ( ) : void
Résultat void

CloseMenus() public méthode

Closes all submenus and the current menu.
public CloseMenus ( ) : void
Résultat void

IsMenuOpen() public méthode

Indicates whether any (sub)menu is open.
public IsMenuOpen ( ) : bool
Résultat bool

Layout() protected méthode

Lays out the control's interior according to alignment, padding, dock etc.
protected Layout ( Skins skin ) : void
skin Skins Skin to use.
Résultat void

Menu() public méthode

Initializes a new instance of the Menu class.
public Menu ( Control parent ) : System
parent Control Parent control.
Résultat System

OnAddItem() protected méthode

Add item handler.
protected OnAddItem ( MenuItem item ) : void
item MenuItem Item added.
Résultat void

OnHoverItem() protected méthode

Mouse hover handler.
protected OnHoverItem ( Control control ) : void
control Control Event source.
Résultat void

Open() public méthode

Opens the menu.
public Open ( Pos pos ) : void
pos Pos Unused.
Résultat void

Render() protected méthode

Renders the control using specified skin.
protected Render ( Skins skin ) : void
skin Skins Skin to use.
Résultat void

RenderUnder() protected méthode

Renders under the actual control (shadows etc).
protected RenderUnder ( Skins skin ) : void
skin Skins Skin to use.
Résultat void