Constructors

Methods

PullOutMenu class

PullOutMenu

 

 

 

Overview

Author

Matt Przybylski [http://www.reintroducing.com]

Version

1.0

Description

Creates a menu like the classic dropdown menu with the options to direct it up, down, left, or right depending on values set.

Constructors

 

PullOutMenu

Usage

public function PullOutMenu($timeline:Object, $hitButton:MovieClip, $menu:MovieClip, $mask:MovieClip, $startHeight:Number, $endHeight:Number, $optionalParams:Object):void

Description

Creates a new instance of the PullOutMenu class.

The $optionalParams parameter takes in a couple of values.

  • openSpeed: An integer representing the speed you want your menu to open, in seconds (default: .25)
  • closeSpeed: An integer representing the speed you want your menu to close, in seconds (default: .25)
  • axis: A string representing the axis that the menu opens on, "x" or "y" (default: "y")
  • easeFunc: A function representing the ease type you'd like to use, as per the Tween class easing functions (default: Regular.easeOut)
  • eventType: A string representing when to trigger the showing of the menu, "rollover", "press", or "release" (default: "rollover")

Parameters

$timeline
A reference to the timeline that the menu is contained in
$hitButton
The MovieClip used as the button you initially roll over or press to see the menu
$menu
The MovieClip where the menu items are housed
$mask
The MovieClip acting as the mask for the menu
$startHeight
A number that represents the initial position of the menu (its resting state)
$endHeight
A number that represents the final position of the menu (after you have opened it)
$optionalParams
See above

Methods

 

closeMenu

Usage

public function closeMenu():void

Description

Closes the menu and puts it in the initial position. Used also when a button inside the menu is pressed and the need to close the menu right then arises.

Returns

void