Main Page | Packages | Class Tree | Index | Help

mx.controls

class MenuBar

Object
  |
  +--MovieClip
        |
        +--mx.core.UIObject
              |
              +--mx.core.UIComponent
                    |
                    +--mx.controls.MenuBar


class MenuBar
extends UIComponent

MenuBar class - extends UIComponent - gives the user the ability to select an option from a menu within a series of menus



Field Summary


__backgroundWidth



__labels: Array
Local properties Live Preview support


__marginWidth



__menuBarItems: Array
Runtime operations


__menuDataProvider: Object



__menuEventHandler: Object



__menus: Object



__selectFirstItem


static
_s_MenuIndex
Private statics


background_mc: MovieClip



boundingBox_mc: MovieClip



className: String



clipParameters: Object



enableByPass: Boolean



invUpdateDisplay: Boolean



invUpdateSize: Boolean



isDown



labelField: String



labelFunction: Function



mask_mc: MovieClip



menuBarBackLeftName: String



menuBarBackMiddleName: String



menuBarBackRightName: String



openMenuIndex: Number



rebroadcastEvents: Object



supposedToLoseFocus: Boolean


static
symbolName: String


static
symbolOwner: Object



tabChildren: Boolean



topItemDepth: Number


static
version: String
Version string Copyright (C) 2003 Macromedia, Inc.

Fields inherited from class mx.core.UIComponent

clipParameters, drawFocus, enabled, focusEnabled, focusManager, focusTextField, groupName, kStretch, mergedClipParameters, origBorderStyles, origBorderValues, popUp, symbolName, symbolOwner, tabEnabled, tabIndex, version

Fields inherited from class mx.core.UIObject

__height, __width, _color, _topmost, addEventListener, buildDepthTable, changeColorStyleInChildren, changeTextStyleInChildren, childrenCreated, className, clipParameters, color, createAccessibilityImplementation, createChildAtDepth, createEvent, ction, dispatchEvent, embedFonts, findNextAvailableDepth, fontFamily, fontSize, fontStyle, fontWeight, handleEvent, idNames, ignoreClassStyleDeclaration, initProperties, marginLeft, marginRight, methodTable, notifyStyleChangeInChildren, removeEventListener, setStyle, stylecache, styleName, symbolName, symbolOwner, textAlign, textColorList, textDecoration, textIndent, validateNow, version

Fields inherited from class MovieClip

_alpha, _currentframe, _droptarget, _focusrect, _framesloaded, _height, _lockroot, _name, _parent, _quality, _rotation, _soundbuftime, _target, _totalframes, _url, _visible, _width, _x, _xmouse, _xscale, _y, _ymouse, _yscale, enabled, focusEnabled, hitArea, tabChildren, tabEnabled, tabIndex, tooltipText, trackAsMenu, useHandCursor

Fields inherited from class Object

__proto__, constructor, prototype

Property Summary


dataProvider: Object (read, write)



labels: Array (read, write)
Live Preview support MR

Properties inherited from class mx.core.UIComponent

height, width

Properties inherited from class mx.core.UIObject

bottom, height, left, minHeight, minWidth, right, scaleX, scaleY, top, visible, width, x, y

Constructor


MenuBar ( )
Lifecycle

Method Summary


addMenu ( arg1, arg2 ): Menu
Append a menu and activator at the end of this menubar.


addMenuAt ( index, arg1, arg2 )
Insert a menu and activator into the menubar.


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



createChildren ( Void ): Void



draw ( Void ): Void



getMenuAt ( index ): Menu
Return the menu at the given index


getMenuEnabledAt ( index )
Return the enabled status of a menu


handleEvent ( event )



init ( Void ): Void
Generic initializer


invalidateStyle ( propName : String ): Void
Theme support


keyDown ( e: Object ): Void
Keyboard Navigation Handlers


notifyStyleChangeInChildren ( sheet, styleProp: String, newValue )



onItemDragOut ( index : Number )



onItemDragOver ( index : Number )



onItemPress ( index : Number ): Void



onItemRelease ( index : Number )



onItemRollOut ( index : Number )



onItemRollOver ( index: Number ): Void
Mouse Event Handlers


onKillFocus ( )



onSetFocus ( )



removeMenuAt ( index )
Remove the menu at the given index


removeMenuBarItemAt ( index )



setDataProvider ( dp )
Load the state from the given XMLNode object


setEnabled ( b: Boolean ): Void



setMenuEnabledAt ( index, enable )
Enable/disable a menu


showMenu ( index: Number ): Void
Show a menuBarItem's menu


size ( Void ): Void



updateBackgroundDisplay ( )
Update the width and placement of the background graphic


updateDisplay ( resize: Boolean ): Void
Display support Layout current representation of items

Methods inherited from class mx.core.UIComponent

dispatchValueChangedEvent, enabledChanged, findFocusFromObject, findFocusInChildren, getFocus, getFocusManager, init, isParent, onKillFocus, onSetFocus, pressFocus, releaseFocus, setEnabled, setFocus, setVisible, size

Methods inherited from class mx.core.UIObject

__getTextFormat, _createChildren, _getTextFormat, cancelAllDoLaters, constructObject, createChildren, createClassObject, createEmptyObject, createLabel, createObject, createSkin, destroyObject, doLater, doLaterDispatcher, draw, drawRect, getClassStyleDeclaration, getMinHeight, getMinWidth, getSkinIDName, getStyle, getStyleName, init, initFromClipParameters, invalidate, invalidateStyle, mergeClipParameters, move, redraw, setColor, setMinHeight, setMinWidth, setSize, setSkin, setVisible, size

Methods inherited from class MovieClip

attachAudio, attachMovie, beginFill, beginGradientFill, clear, createEmptyMovieClip, createTextField, curveTo, duplicateMovieClip, endFill, getBounds, getBytesLoaded, getBytesTotal, getDepth, getInstanceAtDepth, getNextHighestDepth, getSWFVersion, getTextSnapshot, getURL, globalToLocal, gotoAndPlay, gotoAndStop, hitTest, lineStyle, lineTo, loadMovie, loadVariables, localToGlobal, moveTo, nextFrame, onData, onDragOut, onDragOver, onEnterFrame, onKeyDown, onKeyUp, onKillFocus, onLoad, onMouseDown, onMouseMove, onMouseUp, onPress, onRelease, onReleaseOutside, onRollOut, onRollOver, onSetFocus, onUnload, play, prevFrame, removeMovieClip, setMask, startDrag, stop, stopDrag, swapDepths, unloadMovie, valueOf

Methods inherited from class Object

addProperty, hasOwnProperty, isPropertyEnumerable, isPrototypeOf, registerClass, toLocaleString, toString, unwatch, valueOf, watch



Field Documentation

__backgroundWidth

var __backgroundWidth

__labels

var __labels: Array
Local properties Live Preview support

__marginWidth

var __marginWidth

__menuBarItems

var __menuBarItems: Array
Runtime operations

__menuDataProvider

var __menuDataProvider: Object

__menuEventHandler

var __menuEventHandler: Object

__menus

var __menus: Object

__selectFirstItem

var __selectFirstItem

_s_MenuIndex

static var _s_MenuIndex
Private statics

background_mc

var background_mc: MovieClip

boundingBox_mc

var boundingBox_mc: MovieClip

className

var className: String

clipParameters

var clipParameters: Object

enableByPass

var enableByPass: Boolean

invUpdateDisplay

var invUpdateDisplay: Boolean

invUpdateSize

var invUpdateSize: Boolean

isDown

var isDown

labelField

var labelField: String

labelFunction

var labelFunction: Function

mask_mc

var mask_mc: MovieClip

menuBarBackLeftName

var menuBarBackLeftName: String

menuBarBackMiddleName

var menuBarBackMiddleName: String

menuBarBackRightName

var menuBarBackRightName: String

openMenuIndex

var openMenuIndex: Number

rebroadcastEvents

var rebroadcastEvents: Object

supposedToLoseFocus

var supposedToLoseFocus: Boolean

symbolName

static var symbolName: String

symbolOwner

static var symbolOwner: Object

tabChildren

var tabChildren: Boolean

topItemDepth

var topItemDepth: Number

version

static var version: String
Version string Copyright (C) 2003 Macromedia, Inc.

All Rights Reserved. The following is Sample Code and is subject to all restrictions on such code as contained in the End User License Agreement accompanying this product.


Property Documentation

dataProvider

dataProvider: Object (read, write)

labels

labels: Array (read, write)
Live Preview support MR


Constructor Documentation

MenuBar

function MenuBar()
Lifecycle


Method Documentation

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
Overrides:

createChildren

function createChildren(Void): Void
Overrides:

draw

function draw(Void): Void
Overrides:

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)
Overrides:

init

function init(Void): Void
Generic initializer

Overrides:

invalidateStyle

function invalidateStyle(propName : String): Void
Theme support

Overrides:

keyDown

function keyDown(e: Object): Void
Keyboard Navigation Handlers

notifyStyleChangeInChildren

function notifyStyleChangeInChildren(sheet,
 styleProp: String,
 newValue)
Overrides:

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
Mouse Event Handlers

onKillFocus

function onKillFocus()
Overrides:

onSetFocus

function onSetFocus()
Overrides:

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
Overrides:

setMenuEnabledAt

function setMenuEnabledAt(index,
 enable)
Enable/disable a menu

Parameters:
index
the index of the menu instance to enable
enable
menu the Menu instance to remove

showMenu

function showMenu(index: Number): Void
Show a menuBarItem's menu

size

function size(Void): Void
Overrides:

updateBackgroundDisplay

function updateBackgroundDisplay()
Update the width and placement of the background graphic

updateDisplay

function updateDisplay(resize: Boolean): Void
Display support Layout current representation of items


The documentation was generated from the following file:


Copyright © 1997-2005 Macromedia, Inc. All rights reserved. Generated with AS2Doc