English | Site Directory

Android - An Open Handset Alliance Project

android.widget
public class

android.widget.SubMenuBuilder

java.lang.Object
android.widget.MenuBuilder ContextMenu Menu
android.widget.SubMenuBuilder SubMenu

The model for a sub menu, which is an extension of the menu. Most methods are proxied to the parent menu.

Summary

Constants inherited from class android.widget.MenuBuilder
Constants inherited from interface android.view.Menu

Public Constructors

          SubMenuBuilder(Context context, MenuBuilder parentMenu, MenuItemData item)

Public Methods

        Item  getItem()
Gets the Menu.Item that represents this submenu in the parent menu.
        Menu  getParentMenu()
        boolean  isQwertyMode()
        boolean  isShortcutsShown()
        void  setQwertyMode(boolean isQwerty)
Control whether the menu should be running in qwerty mode (alphabetic shortcuts) or 12-key mode (numeric shortcuts).
        void  setShortcutsShown(boolean shortcutsShown)
Sets whether the shortcuts should be shown on menus.
Methods inherited from class android.widget.MenuBuilder
Methods inherited from class java.lang.Object
Methods inherited from interface android.view.SubMenu
Methods inherited from interface android.view.ContextMenu
Methods inherited from interface android.view.Menu

Details

Public Constructors

public SubMenuBuilder(Context context, MenuBuilder parentMenu, MenuItemData item)

Public Methods

public Item getItem()

Gets the Menu.Item that represents this submenu in the parent menu. Use this for setting additional item attributes.

public Menu getParentMenu()

public boolean isQwertyMode()

public boolean isShortcutsShown()

public void setQwertyMode(boolean isQwerty)

Control whether the menu should be running in qwerty mode (alphabetic shortcuts) or 12-key mode (numeric shortcuts).

public void setShortcutsShown(boolean shortcutsShown)

Sets whether the shortcuts should be shown on menus.

Parameters

shortcutsShown Whether shortcuts should be shown (if true and a menu item does not have a shortcut defined, that item will still NOT show a shortcut)
Build m5-rc15i - 10 Jun 2008 13:54