MenuBar

Kind of class:class
Inherits from:UIComponent < UIObject < MovieClip
Classpath:mx.controls.MenuBar
File last modified:Tuesday, 18 December 2007, 15:44:37
MenuBar class
- extends UIComponent
- gives the user the ability to select an option from a menu within a series of menus

Summary


Constructor
Class properties
Instance properties
Class methods
Class methods inherited from UIObject
Instance methods
Event handlers
Event handlers inherited from UIComponent

Constructor

Class properties

_s_MenuIndex

static _s_MenuIndex = 0
(read)

symbolName

static symbolName:String = "MenuBar"
(read)

symbolOwner

static symbolOwner:Object = MenuBar
(read)

version

static version:String = "2.0.2.127"
(read)

Instance properties

__backgroundWidth

__backgroundWidth = 550
(read)

__labels

__labels:Array
(read)

__marginWidth

__marginWidth = 10
(read)

__menuBarItems

__menuBarItems:Array
(read)

__menuDataProvider

__menuDataProvider:Object
(read)

__menuEventHandler

__menuEventHandler:Object
(read)

__menus

__menus:Object
(read)

__selectFirstItem

__selectFirstItem
(read)

background_mc

background_mc:MovieClip
(read)

boundingBox_mc

boundingBox_mc:MovieClip
(read)

className

className:String = "MenuBar"
(read)

clipParameters

clipParameters:Object = { enabled:1, visible:1, labels:1, minWidth:1, minHeight:1}
(read)

dataProvider

dataProvider:Object
(read,write)

Component metadata:
    Bindable
    "XML"
    param1:
    "writeonly",type

    enableByPass

    enableByPass:Boolean
    (read)

    invUpdateDisplay

    invUpdateDisplay:Boolean
    (read)

    invUpdateSize

    invUpdateSize:Boolean
    (read)

    isDown

    isDown
    (read)

    labelField

    labelField:String = "label"
    (read)

    labelFunction

    labelFunction:Function
    (read)

    labels

    labels:Array
    (read,write)

    Component metadata:
      Inspectable
      defaultValue:
      ""

      mask_mc

      mask_mc:MovieClip
      (read)

      openMenuIndex

      openMenuIndex:Number
      (read)

      rebroadcastEvents

      rebroadcastEvents:Object = { menuHide:1, menuShow:1, rollOver:1, rollOut:1, change:1 }
      (read)

      supposedToLoseFocus

      supposedToLoseFocus:Boolean
      (read)

      tabChildren

      tabChildren:Boolean = false
      (read)

      topItemDepth

      topItemDepth:Number = 200
      (read)

      Instance methods

      addMenu

      function addMenu (
      arg1, arg2) : Menu

      Append a menu and activator at the end of this menubar.
      Parameters:
      arg1:
      may be either (1) a String (to be used as the item's label), (2) or an xmlNode
      arg2:
      may be either (1) undefined, (2) a menu, (3) or an xml/xmlNode
      Returns:
      • Return the reference to the new Menu.

      addMenuAt

      function addMenuAt (
      index, arg1, arg2)

      Insert a menu and activator into the menubar.
      Parameters:
      index:
      the index where the menu should be inserted
      arg1 :
      may be either (1) a String (to be used as the item's label), (2) or an xmlNode
      arg2 :
      may be either (1) undefined, (2) a menu, (3) or an xml/xmlNode
      Returns:
      • Return the reference to the new Menu.

      changeColorStyleInChildren

      function changeColorStyleInChildren (
      sheet, styleProp:String, newValue) : Void

      createChildren

      function createChildren (
      Void) : Void

      draw

      function draw (
      Void) : Void

      getMenuAt

      function getMenuAt (
      index) : Menu

      Return the menu at the given index
      Parameters:
      index:
      the index of the menu instance to return
      Returns:
      • a reference to the menu at that specified index

      getMenuEnabledAt

      function getMenuEnabledAt (
      index)

      Return the enabled status of a menu
      Parameters:
      index:
      the index of the menu instance
      Returns:
      • a Boolean of the enabled state of the specified menu

      handleEvent

      function handleEvent (
      event)

      init

      function init (
      Void) : Void

      Generic initializer

      insertMenuBarItem

      private function insertMenuBarItem (
      index, mdp)

      invalidateStyle

      function invalidateStyle (
      propName:String) : Void

      keyDown

      function keyDown (
      e:Object) : Void

      notifyStyleChangeInChildren

      function notifyStyleChangeInChildren (
      sheet, styleProp:String, newValue)

      removeAll

      private function removeAll (
      )

      removeMenuAt

      function removeMenuAt (
      index)

      Remove the menu at the given index
      Parameters:
      index:
      the index of the menu instance to remove
      Returns:
      • a reference to the menu that was removed

      removeMenuBarItemAt

      function removeMenuBarItemAt (
      index)

      setDataProvider

      function setDataProvider (
      dp)

      Load the state from the given XMLNode object

      setEnabled

      function setEnabled (
      b:Boolean) : Void

      setMenuEnabledAt

      function setMenuEnabledAt (
      index, enable)

      Enable/disable a menu
      Parameters:
      index:
      the index of the menu instance to enable
      menu :
      the Menu instance to remove

      showMenu

      function showMenu (
      index:Number) : Void

      size

      function size (
      Void) : Void

      updateBackgroundDisplay

      function updateBackgroundDisplay (
      )

      updateDisplay

      function updateDisplay (
      resize:Boolean) : Void

      Event handlers

      onItemDragOut

      function onItemDragOut (
      index:Number)

      onItemDragOver

      function onItemDragOver (
      index:Number)

      onItemPress

      function onItemPress (
      index:Number) : Void

      onItemRelease

      function onItemRelease (
      index:Number)

      onItemRollOut

      function onItemRollOut (
      index:Number)

      onItemRollOver

      function onItemRollOver (
      index:Number) : Void

      onKillFocus

      function onKillFocus (
      )

      onSetFocus

      function onSetFocus (
      )