Yahoo! UI Library

Menu  2.4.1

Yahoo! UI Library > menu > YAHOO.widget.MenuManager

Show Private Show Protected

static Class YAHOO.widget.MenuManager

Singleton that manages a collection of all menus and menu items. Listens for DOM events at the document level and dispatches the events to the corresponding menu or menu item.

Methods

addMenu

void addMenu ( p_oMenu )
Adds a menu to the collection of known menus.
Parameters:
p_oMenu <YAHOO.widget.Menu> Object specifying the Menu instance to be added.
Returns: void

getFocusedMenu

YAHOO.widget.Menu getFocusedMenu ( )
Returns a reference to the menu that currently has focus.
Returns: YAHOO.widget.Menu

getFocusedMenuItem

YAHOO.widget.MenuItem getFocusedMenuItem ( )
Returns a reference to the menu item that currently has focus.
Returns: YAHOO.widget.MenuItem

getMenu

YAHOO.widget.Menu getMenu ( p_sId )
Returns a menu with the specified id.
Parameters:
p_sId <String> String specifying the id of the <div> element representing the menu to be retrieved.
Returns: YAHOO.widget.Menu

getMenuItem

YAHOO.widget.MenuItem getMenuItem ( p_sId )
Returns a menu item with the specified id.
Parameters:
p_sId <String> String specifying the id of the <li> element representing the menu item to be retrieved.
Returns: YAHOO.widget.MenuItem

getMenuItemGroup

Array getMenuItemGroup ( p_sId )
Returns an array of menu item instances whose corresponding <li> elements are child nodes of the <ul> element with the specified id.
Parameters: