### Hierarchy

- Menu

## Index

### Constructors

- constructor

### Properties

- _activeItem
- _alignment
- _background
- _controls
- _counterOverride
- _counterPretext
- _counterText
- _descriptionBar
- _descriptionRectangle
- _descriptionText
- _drawOffset
- _extraRectangleDown
- _extraRectangleUp
- _justOpened
- _lastLeftRightNavigation
- _lastUpDownNavigation
- _logo
- _mainMenu
- _maxItem
- _maxItemsOnScreen
- _minItem
- _mousePressed
- _navigationDelay
- _offset
- _settings
- _subtitle
- _subtitleResRectangle
- _title
- _upAndDownSprite
- _widthOffset
- checkboxChange
- children
- id
- indexChange
- itemSelect
- items
- listChange
- listSelect
- menuChange
- menuClose
- menuOpen
- panelActivated
- parentItem
- parentMenu
- sliderChange
- sliderSelect
- visible
- screenAspectRatio
- screenHeight
- screenResolution
- screenWidth

### Accessors

- Alignment
- Controls
- CurrentItem
- CurrentSelection
- DrawOffset
- Settings
- Subtitle
- SubtitleBackColor
- SubtitleFont
- SubtitleForeColor
- Title
- TitleFont
- WidthOffset

### Methods

- _calculateItemHeight
- _calculatePanelPosition
- _disEnableControls
- _isThereAnyItemExcludingSeparators
- _playSoundAndReleaseId
- _processControl
- _processMouse
- _recalculateDescriptionPosition
- _recalculateUpAndDown
- _render
- addItem
- addNewSubMenu
- addSubMenu
- bindMenuToItem
- clear
- close
- goBack
- goDown
- goLeft
- goRight
- goUp
- isMouseInBounds
- open
- refreshIndex
- releaseMenuFromItem
- removeItem
- selectItem

## Constructors

### constructor

- new Menu(title: string, subtitle: string, offset?: Point, spriteLibrary?: string, spriteName?: string): Menu

- - Defined in ui/menu/Menu.ts:79

  #### Parameters

  - ##### title: string

  - ##### subtitle: string

  - ##### offset: Point = ...

  - ##### spriteLibrary: string = 'commonmenu'

  - ##### spriteName: string = 'interaction_bgd'

  #### Returns Menu

## Properties

### Private _activeItem

_activeItem: number = 1000

- Defined in ui/menu/Menu.ts:54

### Private _alignment

_alignment: MenuAlignment = ...

- Defined in ui/menu/Menu.ts:49

### Private Readonly _background

_background: Sprite

- Defined in ui/menu/Menu.ts:77

### Private _controls

_controls: MenuControls = ...

- Defined in ui/menu/Menu.ts:62

### Private _counterOverride

_counterOverride: string = ''

- Defined in ui/menu/Menu.ts:48

### Private _counterPretext

_counterPretext: string = ''

- Defined in ui/menu/Menu.ts:47

### Private Readonly _counterText

_counterText: Text

- Defined in ui/menu/Menu.ts:76

### Private Readonly _descriptionBar

_descriptionBar: Rectangle

- Defined in ui/menu/Menu.ts:73

### Private Readonly _descriptionRectangle

_descriptionRectangle: Sprite

- Defined in ui/menu/Menu.ts:74

### Private Readonly _descriptionText

_descriptionText: Text

- Defined in ui/menu/Menu.ts:75

### Private _drawOffset

_drawOffset: Point = ...

- Defined in ui/menu/Menu.ts:56

### Private Readonly _extraRectangleDown

_extraRectangleDown: Rectangle

- Defined in ui/menu/Menu.ts:72

### Private Readonly _extraRectangleUp

_extraRectangleUp: Rectangle

- Defined in ui/menu/Menu.ts:71

### Private _justOpened

_justOpened: boolean = true

- Defined in ui/menu/Menu.ts:57

### Private _lastLeftRightNavigation

_lastLeftRightNavigation: number = 0

- Defined in ui/menu/Menu.ts:53

### Private _lastUpDownNavigation

_lastUpDownNavigation: number = 0

- Defined in ui/menu/Menu.ts:52

### Private Readonly _logo

_logo: Sprite

- Defined in ui/menu/Menu.ts:68

### Private Readonly _mainMenu

_mainMenu: Container

- Defined in ui/menu/Menu.ts:67

### Private _maxItem

_maxItem: number = 9

- Defined in ui/menu/Menu.ts:60

### Private _maxItemsOnScreen

_maxItemsOnScreen: number = ...

- Defined in ui/menu/Menu.ts:61

### Private _minItem

_minItem: number = 0

- Defined in ui/menu/Menu.ts:59

### Private _mousePressed

_mousePressed: boolean = false

- Defined in ui/menu/Menu.ts:58

### Private _navigationDelay

_navigationDelay: number = 140

- Defined in ui/menu/Menu.ts:51

### Private _offset

_offset: Point

- Defined in ui/menu/Menu.ts:50

### Private _settings

_settings: MenuSettings = ...

- Defined in ui/menu/Menu.ts:63

### Private Readonly _subtitle

_subtitle: Text

- Defined in ui/menu/Menu.ts:66

### Private Readonly _subtitleResRectangle

_subtitleResRectangle: Rectangle

- Defined in ui/menu/Menu.ts:70

### Private Readonly _title

_title: Text

- Defined in ui/menu/Menu.ts:65

### Private Readonly _upAndDownSprite

_upAndDownSprite: Sprite

- Defined in ui/menu/Menu.ts:69

### Private _widthOffset

_widthOffset: number = 0

- Defined in ui/menu/Menu.ts:55

### Readonly checkboxChange

checkboxChange: LiteEvent = ...

- Defined in ui/menu/Menu.ts:39

### children

children: Map<string, Menu> = ...

- Defined in ui/menu/Menu.ts:30

### Readonly id

id: string = ...

- Defined in ui/menu/Menu.ts:23

### Readonly indexChange

indexChange: LiteEvent = ...

- Defined in ui/menu/Menu.ts:36

### Readonly itemSelect

itemSelect: LiteEvent = ...

- Defined in ui/menu/Menu.ts:43

### items

items: UIMenuItem[] = []

- Defined in ui/menu/Menu.ts:29

### Readonly listChange

listChange: LiteEvent = ...

- Defined in ui/menu/Menu.ts:37

### Readonly listSelect

listSelect: LiteEvent = ...

- Defined in ui/menu/Menu.ts:41

### Readonly menuChange

menuChange: LiteEvent = ...

- Defined in ui/menu/Menu.ts:34

### Readonly menuClose

menuClose: LiteEvent = ...

- Defined in ui/menu/Menu.ts:33

### Readonly menuOpen

menuOpen: LiteEvent = ...

- Defined in ui/menu/Menu.ts:32

### Readonly panelActivated

panelActivated: LiteEvent = ...

- Defined in ui/menu/Menu.ts:45

### parentItem

parentItem: undefined | UIMenuItem

- Defined in ui/menu/Menu.ts:28

### parentMenu

parentMenu: undefined | Menu

- Defined in ui/menu/Menu.ts:27

### Readonly sliderChange

sliderChange: LiteEvent = ...

- Defined in ui/menu/Menu.ts:38

### Readonly sliderSelect

sliderSelect: LiteEvent = ...

- Defined in ui/menu/Menu.ts:42

### visible

visible: boolean = false

- Defined in ui/menu/Menu.ts:25

### Static screenAspectRatio

screenAspectRatio: number = ...

- Defined in ui/menu/Menu.ts:18

### Static screenHeight

screenHeight: number = 1080

- Defined in ui/menu/Menu.ts:19

### Static screenResolution

screenResolution: Size = ...

- Defined in ui/menu/Menu.ts:21

### Static screenWidth

screenWidth: number = ...

- Defined in ui/menu/Menu.ts:20

## Accessors

### Alignment

- get Alignment(): MenuAlignment
- set Alignment(alignment: MenuAlignment): void

- - Defined in ui/menu/Menu.ts:257

  #### Returns MenuAlignment

- - Defined in ui/menu/Menu.ts:261

  #### Parameters

  - ##### alignment: MenuAlignment

  #### Returns void

### Controls

- get Controls(): MenuControls

- - Defined in ui/menu/Menu.ts:304

  #### Returns MenuControls

### CurrentItem

- get CurrentItem(): UIMenuItem
- set CurrentItem(value: UIMenuItem): void

- - Defined in ui/menu/Menu.ts:229

  #### Returns UIMenuItem

- - Defined in ui/menu/Menu.ts:233

  #### Parameters

  - ##### value: UIMenuItem

  #### Returns void

### CurrentSelection

- get CurrentSelection(): number
- set CurrentSelection(v: number): void

- - Defined in ui/menu/Menu.ts:240

  #### Returns number

- - Defined in ui/menu/Menu.ts:244

  #### Parameters

  - ##### v: number

  #### Returns void

### DrawOffset

- get DrawOffset(): Point

- - Defined in ui/menu/Menu.ts:300

  #### Returns Point

### Settings

- get Settings(): MenuSettings

- - Defined in ui/menu/Menu.ts:308

  #### Returns MenuSettings

### Subtitle

- get Subtitle(): string
- set Subtitle(text: string): void

- - Defined in ui/menu/Menu.ts:201

  #### Returns string

- - Defined in ui/menu/Menu.ts:197

  #### Parameters

  - ##### text: string

  #### Returns void

### SubtitleBackColor

- get SubtitleBackColor(): Color
- set SubtitleBackColor(color: Color): void

- - Defined in ui/menu/Menu.ts:225

  #### Returns Color

- - Defined in ui/menu/Menu.ts:221

  #### Parameters

  - ##### color: Color

  #### Returns void

### SubtitleFont

- get SubtitleFont(): Font
- set SubtitleFont(font: Font): void

- - Defined in ui/menu/Menu.ts:209

  #### Returns Font

- - Defined in ui/menu/Menu.ts:205

  #### Parameters

  - ##### font: Font

  #### Returns void

### SubtitleForeColor

- get SubtitleForeColor(): Color
- set SubtitleForeColor(color: Color): void

- - Defined in ui/menu/Menu.ts:217

  #### Returns Color

- - Defined in ui/menu/Menu.ts:213

  #### Parameters

  - ##### color: Color

  #### Returns void

### Title

- get Title(): string
- set Title(text: string): void

- - Defined in ui/menu/Menu.ts:185

  #### Returns string

- - Defined in ui/menu/Menu.ts:181

  #### Parameters

  - ##### text: string

  #### Returns void

### TitleFont

- get TitleFont(): Font
- set TitleFont(font: Font): void

- - Defined in ui/menu/Menu.ts:189

  #### Returns Font

- - Defined in ui/menu/Menu.ts:193

  #### Parameters

  - ##### font: Font

  #### Returns void

### WidthOffset

- get WidthOffset(): number
- set WidthOffset(widthOffset: number): void

- - Defined in ui/menu/Menu.ts:265

  #### Returns number

- - Defined in ui/menu/Menu.ts:269

  #### Parameters

  - ##### widthOffset: number

  #### Returns void

## Methods

### Private _calculateItemHeight

- _calculateItemHeight(): number

- - Defined in ui/menu/Menu.ts:860

  #### Returns number

### Private _calculatePanelPosition

- _calculatePanelPosition(hasDescription: boolean): number

- - Defined in ui/menu/Menu.ts:871

  #### Parameters

  - ##### hasDescription: boolean

  #### Returns number

### Private _disEnableControls

- _disEnableControls(): void

- - Defined in ui/menu/Menu.ts:832

  #### Returns void

### Private _isThereAnyItemExcludingSeparators

- _isThereAnyItemExcludingSeparators(): boolean

- - Defined in ui/menu/Menu.ts:823

  #### Returns boolean

### Private _playSoundAndReleaseId

- _playSoundAndReleaseId(sound: string, set?: string): void

- - Defined in ui/menu/Menu.ts:827

  #### Parameters

  - ##### sound: string

  - ##### Optional set: string

  #### Returns void

### Private _processControl

- _processControl(): void

- - Defined in ui/menu/Menu.ts:761

  #### Returns void

### Private _processMouse

- _processMouse(): void

- - Defined in ui/menu/Menu.ts:607

  #### Returns void

### Private _recalculateDescriptionPosition

- _recalculateDescriptionPosition(): void

- - Defined in ui/menu/Menu.ts:846

  #### Returns void

### Private _recalculateUpAndDown

- _recalculateUpAndDown(): void

- - Defined in ui/menu/Menu.ts:839

  #### Returns void

### Private _render

- _render(): void

- - Defined in ui/menu/Menu.ts:879

  #### Returns void

### addItem

- addItem(items: UIMenuItem | UIMenuItem[]): void

- - Defined in ui/menu/Menu.ts:350

  #### Parameters

  - ##### items: UIMenuItem | UIMenuItem[]

  #### Returns void

### addNewSubMenu

- addNewSubMenu(text: string, description?: string, inherit?: boolean): Menu

- - Defined in ui/menu/Menu.ts:312

  #### Parameters

  - ##### text: string

  - ##### Optional description: string

  - ##### inherit: boolean = true

  #### Returns Menu

### addSubMenu

- addSubMenu(subMenuToAdd: Menu, text: string, description?: string, inherit?: boolean): Menu

- - Defined in ui/menu/Menu.ts:336

  #### Parameters

  - ##### subMenuToAdd: Menu

  - ##### text: string

  - ##### Optional description: string

  - ##### inherit: boolean = true

  #### Returns Menu

### bindMenuToItem

- bindMenuToItem(menuToBind: Menu, itemToBindTo: UIMenuItem): void

- - Defined in ui/menu/Menu.ts:375

  #### Parameters

  - ##### menuToBind: Menu

  - ##### itemToBindTo: UIMenuItem

  #### Returns void

### clear

- clear(): void

- - Defined in ui/menu/Menu.ts:418

  #### Returns void

### close

- close(): void

- - Defined in ui/menu/Menu.ts:435

  #### Returns void

### goBack

- goBack(): void

- - Defined in ui/menu/Menu.ts:595

  #### Returns void

### goDown

- goDown(): void

- - Defined in ui/menu/Menu.ts:563

  #### Returns void

### goLeft

- goLeft(): void

- - Defined in ui/menu/Menu.ts:442

  #### Returns void

### goRight

- goRight(): void

- - Defined in ui/menu/Menu.ts:463

  #### Returns void

### goUp

- goUp(): void

- - Defined in ui/menu/Menu.ts:530

  #### Returns void

### isMouseInBounds

- isMouseInBounds(pos: Point, size: Size, drawOffset?: boolean): boolean

- - Defined in ui/menu/Menu.ts:515

  #### Parameters

  - ##### pos: Point

  - ##### size: Size

  - ##### drawOffset: boolean = true

  #### Returns boolean

### open

- open(): void

- - Defined in ui/menu/Menu.ts:424

  #### Returns void

### refreshIndex

- refreshIndex(): void

- - Defined in ui/menu/Menu.ts:394

  #### Returns void

### releaseMenuFromItem

- releaseMenuFromItem(releaseFrom: UIMenuItem): boolean

- - Defined in ui/menu/Menu.ts:381

  #### Parameters

  - ##### releaseFrom: UIMenuItem

  #### Returns boolean

### removeItem

- removeItem(itemOrIndex: number | UIMenuItem): void

- - Defined in ui/menu/Menu.ts:366

  #### Parameters

  - ##### itemOrIndex: number | UIMenuItem

  #### Returns void

### selectItem

- selectItem(): void

- - Defined in ui/menu/Menu.ts:481

  #### Returns void

Generated using TypeDoc