Parallax (Parallax)
UIComponent
|
+--Parallax
- class Parallax
extends UIComponent
The Parallax class creates an object that tweens the contents left/right or up/down based on where the mouseX, mouseY is located within the area of the Parallax.
Property summary
| Property | Description |
|---|---|
| content:* | Reference to the components content container |
| direction:String | Gets or sets the layout of the Parallax
Accepts the strings: horizontal or vertical. The default value is ‘vertical’ |
| width:Number | Gets or sets the width of the component |
| height:Number | Gets or sets the height of the component |
Method summary
| Method | Description |
|---|---|
| redraw() : void | Initiates the internal draw() function |
| setSize(w:Number, h:Number) : void | Sets the component to the specified width and height. |
Parallax()
Description
Creates a new Parallax component instance
redraw() : void
Usage
public function redraw():void
Parameters
Returns
Nothing.
Description
Initiates the internal draw() function
setSize(w:Number, h:Number) : void
Usage
override public function setSize(w:Number, h:Number):void
Parameters
Returns
Nothing.
Description
Sets the component to the specified width and height.
content : *
Usage
public function get content():*
Description
Reference to the components content container
direction : String
Usage
public function get direction():String
Description
Gets or sets the layout of the Parallax
Accepts the strings: horizontal or vertical.
The default value is ‘vertical’
width : Number
Usage
override public function get width():Number
Description
Gets or sets the width of the component
height : Number
Usage
override public function get height():Number
Description
Gets or sets the height of the component