Package | com.gestureworks.cml.elements |
Class | public class PopupMenu |
Inheritance | PopupMenu ![]() ![]() ![]() |
var ppMenu:PopupMenu = new PopupMenu(); ppMenu.x = 500; ppMenu.y = 150; ppMenu.fill = 0xf2d4c2; ppMenu.color = 0xA66874; ppMenu.fontSize = 36; ppMenu.menuTitle = "Images"; ppMenu.menuItems = "Image1,Image2,Image3,Image4,Image5"; addChild(ppMenu); ppMenu.init(); // This is the event listener for when a menu item has been selected. ddMenu.addEventListener(StateEvent.CHANGE, onItemSelected); function onItemSelected(e:StateEvent):void { trace("OnItemSelected", e.value); }
See also
Method | Defined By | ||
---|---|---|---|
Constructor
| PopupMenu | ||
![]() | activateTouch():void | TouchContainer | |
![]() | addAllChildren():void
method searches the child and adds to the list
| TouchContainer | |
![]() | addChild(child:DisplayObject):DisplayObject [override]
Adds child to display list and, if not already added, the child list
| TouchContainer | |
![]() | addChildAt(child:DisplayObject, index:int):DisplayObject [override]
Adds child to display list and, if not already added, the child list
| TouchContainer | |
![]() | applyLayout(value:* = null):void
Apply the containers layout
| TouchContainer | |
![]() | childToList(id:String, child:*):void
child appended to the childlist
| TouchContainer | |
![]() | clone():*
Clone method
| TouchContainer | |
![]() | dispose():void [override]
Destructor
| DropDownMenu | |
![]() | getElementById(id:String):*
Searches CML childList by id. | TouchContainer | |
![]() | getElementsByClassName(className:String):Array
Searches the CML childList by className. | TouchContainer | |
![]() | getElementsByTagName(tagName:Class):Array
Searches the CML childList by tagName as Class. | TouchContainer | |
![]() | hideMenu(noDispatch:Boolean = false):void | DropDownMenu | |
init():void [override]
inialization method
| PopupMenu | ||
![]() | loadState(sId:* = null, recursion:Boolean = false):void
Loads state by index number. | TouchContainer | |
![]() | makeGestureList(value:XMLList):Object
Creates gestureList object from XML
| TouchContainer | |
onDownHit(event:* = null):void [override] | PopupMenu | ||
![]() | parseCML(cml:XMLList):XMLList
Parse cml for local layouts. | TouchContainer | |
![]() | postparseCML(cml:XMLList):void
Abstract method allows the setting of a postparse CML routine. | TouchContainer | |
![]() | querySelector(selector:String):*
Searches the CML childList by selector. | TouchContainer | |
![]() | querySelectorAll(selector:*):Array
Search the CML childList by selector. | TouchContainer | |
![]() | removeChild(child:DisplayObject):DisplayObject [override]
Removes child from display list and, if not already removed, the child list
| TouchContainer | |
![]() | removeChildAt(index:int):DisplayObject [override]
Removes child from display list and, if not already removed, the child list
| TouchContainer | |
![]() | removeChildren(beginIndex:int = 0, endIndex:int = 2147483647):void [override]
Removes children from display list and, if not already removed, the child list
| TouchContainer | |
![]() | saveState(sId:* = null, recursion:Boolean = false):void
Save state by index number. | TouchContainer | |
![]() | searchChildren(value:*, returnType:Class = null):*
This method does a depth first search of childLists. | TouchContainer | |
![]() | setDimensionsToChild():void
method sets the dimensions of each child
| TouchContainer | |
![]() | showMenu(noDispatch:Boolean = false):void | DropDownMenu | |
![]() | tweenState(sId:* = null, tweenTime:Number = 1):void
Tween state by stateIndex from current to given state index. | TouchContainer | |
![]() | updatePadding():void
Updates child padding within this container
| TouchContainer | |
![]() | updatePercentDim():void
Updates child percent dimensions within this container
| TouchContainer | |
![]() | updateProperties(state:* = 0):void
Updates properties from state. | TouchContainer | |
![]() | updateRelativePos():void
Updates child relative positions within this container
| TouchContainer |
Method | Defined By | ||
---|---|---|---|
![]() | createHit():void | DropDownMenu | |
![]() | createMenu():void | DropDownMenu | |
![]() | createMenuItem(s:String, idIn:String):Text | DropDownMenu | |
![]() | onItemOut(event:*):void | DropDownMenu | |
onItemSelected(event:*):void [override] | PopupMenu | ||
![]() | onMenuOut(event:*):void | DropDownMenu | |
![]() | onOver(event:*):void | DropDownMenu |
PopupMenu | () | Constructor |
public function PopupMenu()
Constructor
init | () | method |
override public function init():void
inialization method
onDownHit | () | method |
override public function onDownHit(event:* = null):void
Parameters
event:* (default = null )
|
onItemSelected | () | method |
override protected function onItemSelected(event:*):void
Parameters
event:* |