C# Class ScreenManagement.Screens.Old.FancyMenuScreen

Inheritance: MenuScreen
Afficher le fichier Open project: giladgray/XNA-ScreenManager

Private Properties

Свойство Type Description
ChangeColumns void
ChangeColumnsRelative void

Méthodes publiques

Méthode Description
AddMenuEntry ( int column, MenuEntry entry, EventHandler evt = null ) : MenuEntry

Adds a new menu entry to the menu with the given event handler.

AddMenuEntry ( int column, string text, Alignment align = Alignment.Left, EventHandler evt = null ) : MenuEntry

Adds a new menu entry to the menu with the given text, alignment, and event handler.

Draw ( GameTime gameTime ) : void

Draws the menu.

FancyMenuScreen ( string title, int columns, Orientation orientation = Orientation.Vertical ) : System

Creates a new FancyMenuScreen with the given title, number of columns, and column orientation.

HandleInput ( InputState input ) : void

Responds to user input, changing the selected entry and accepting or cancelling the menu.

LoadContent ( ) : void
Update ( GameTime gameTime, bool otherScreenHasFocus, bool coveredByOtherScreen ) : void

Updates the menu.

Méthodes protégées

Méthode Description
DoLayout ( ) : void

Recalculate the positions and sizes of each menu entry.

OnSelectEntry ( Selection selected, PlayerIndex playerIndex ) : void

Handler for when the user has chosen a menu entry.

Private Methods

Méthode Description
ChangeColumns ( int dir ) : void
ChangeColumnsRelative ( int dir ) : void

Method Details

AddMenuEntry() public méthode

Adds a new menu entry to the menu with the given event handler.
public AddMenuEntry ( int column, MenuEntry entry, EventHandler evt = null ) : MenuEntry
column int
entry MenuEntry MenuEntry to add
evt EventHandler event handler for selected the menu entry
Résultat MenuEntry

AddMenuEntry() public méthode

Adds a new menu entry to the menu with the given text, alignment, and event handler.
public AddMenuEntry ( int column, string text, Alignment align = Alignment.Left, EventHandler evt = null ) : MenuEntry
column int
text string text of the menu entry
align Alignment horizontal alignment of menu entry
evt EventHandler event handler for selecting menu entry
Résultat MenuEntry

DoLayout() protected méthode

Recalculate the positions and sizes of each menu entry.
protected DoLayout ( ) : void
Résultat void

Draw() public méthode

Draws the menu.
public Draw ( GameTime gameTime ) : void
gameTime Microsoft.Xna.Framework.GameTime
Résultat void

FancyMenuScreen() public méthode

Creates a new FancyMenuScreen with the given title, number of columns, and column orientation.
public FancyMenuScreen ( string title, int columns, Orientation orientation = Orientation.Vertical ) : System
title string the title of the menu
columns int the number of menu columns
orientation Orientation
Résultat System

HandleInput() public méthode

Responds to user input, changing the selected entry and accepting or cancelling the menu.
public HandleInput ( InputState input ) : void
input InputState
Résultat void

LoadContent() public méthode

public LoadContent ( ) : void
Résultat void

OnSelectEntry() protected méthode

Handler for when the user has chosen a menu entry.
protected OnSelectEntry ( Selection selected, PlayerIndex playerIndex ) : void
selected Selection
playerIndex PlayerIndex
Résultat void

Update() public méthode

Updates the menu.
public Update ( GameTime gameTime, bool otherScreenHasFocus, bool coveredByOtherScreen ) : void
gameTime Microsoft.Xna.Framework.GameTime
otherScreenHasFocus bool
coveredByOtherScreen bool
Résultat void