Packagecom.adobe.portfolio.layouts
Classpublic class WaveLayout
InheritanceWaveLayout Inheritance spark.layouts.supportClasses.LayoutBase
Implements IListenAndWatch, ICardLayout, ICardProvider

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The WaveLayout class extends LayoutBase to implement the layout of the Wave navigator.



Public Properties
 PropertyDefined By
  cardLayoutHelper : CardLayoutHelper
[read-only] The instance of the CardLayoutHelper used by this layout
WaveLayout
  cardPosition : Number
The horizontal position of the card, in pixels.
WaveLayout
  easer : EaseInOutBase
The easer used for the card animation effect
WaveLayout
  fieldOfView : Number
The angle, specified in degrees greater than 0 and less than 180, for the field of view in three dimensions.
WaveLayout
  focusAttachment : IAttachment
WaveLayout
  itemDistance : Number
The pre-transform distance between each visual item in the wave layout in pixels
WaveLayout
  itemHeight : Number
An explicit height for cards in the layout.
WaveLayout
  itemWidth : Number
An explicit width for cards in the layout.
WaveLayout
  list : CardList
The list of attachments being displayed (as cards)
WaveLayout
  maxCardPosition : Number
The maximum horizontal position that a card can have.
WaveLayout
  pendingCardPosition : Number
The pendingCard position
WaveLayout
  sineAmp : Number
The amplitude of the sine wave used to place cards in the layout, given as a fraction of the target height (nominally, sineAmp is in the range 0 to 1).
WaveLayout
  sinePhase : Number
The starting phase angle for the wave function
WaveLayout
  target : GroupBase
[override] The target component
WaveLayout
  thumbFitSize : Point
The size to use for preview thumbnails
WaveLayout
  yAngle : Number
Controls the y-axis rotation of cards other than the focus card
WaveLayout
  zAngle : Number
The y-axis rotation of cards other than the focus card
WaveLayout
  zDistance : Number
Controls the z-distance of cards other than the focus card
WaveLayout
  zDistancePower : Number
The z-distance of cards is determined (in part) by zDistance^^zDistancePower
WaveLayout
Protected Properties
 PropertyDefined By
  animate : Animate
WaveLayout
  autoListen : AutoListen
WaveLayout
  cardDistance : Number
[read-only]
WaveLayout
  cardPositionTimer : Timer
WaveLayout
  cardSizesInvalid : Boolean
WaveLayout
  focusCardInvalid : Boolean
WaveLayout
  layoutWidth : Number
WaveLayout
  perspectiveProjection : PerspectiveProjection
WaveLayout
  scrollAgain : Boolean
WaveLayout
  sizeInvalid : Boolean
WaveLayout
  totalWidth : Number
WaveLayout
Public Methods
 MethodDefined By
  
Constructor
WaveLayout
  
Add event listeners and change watchers to the navigator.
WaveLayout
  
elementAdded(index:int):void
[override]
WaveLayout
  
elementRemoved(index:int):void
[override]
WaveLayout
  
findCardsThatIntersect(marqueeRect:Rectangle):Vector.<int>
Find the list of cards that overlap the specified marquee rectangle.
WaveLayout
  
getCard(cardPosition:Number):ISimpleCard
Get the card that has the specified card position
WaveLayout
  
measure():void
[override]
WaveLayout
  
nudgeCard(delta:Number):void
nudgeCard is called when the user drags a card either left or right.
WaveLayout
  
Remove all event listeners and change watchers from the navigator
WaveLayout
  
scroll(duration:Number):void
Scroll the cards to the current focusIndex
WaveLayout
  
setFocusAttachment(attachment:Object):void
Set the target's focus to be the specified attachment
WaveLayout
  
updateDisplayList(width:Number, height:Number):void
[override]
WaveLayout
Protected Methods
 MethodDefined By
  
cardIndexFromPosition(cardPosition:Number):int
Returns the index value for the card at the given horizontal position the cards index value.
WaveLayout
  
cardPositionFromIndex(index:int):Number
Returns the horizontal card position, in pixels, given the cards index value.
WaveLayout
  
centerCard(newCardPosition:Number):void
WaveLayout
  
WaveLayout
  
enableCards(enabled:Boolean):void
WaveLayout
  
Runs the fadeInCards animation effect.
WaveLayout
  
WaveLayout
  
WaveLayout
  
WaveLayout
  
WaveLayout
  
Invalidate the current targer
WaveLayout
  
WaveLayout
  
WaveLayout
  
onEndScroll(e:EffectEvent):void
WaveLayout
  
onResize(event:ResizeEvent):void
WaveLayout
  
WaveLayout
  
WaveLayout
  
resetSize():void
Resets the target's content size
WaveLayout
  
rotateY(card:IVisualElement, matrix:Matrix3D, indexedPosition:Number):void
WaveLayout
  
rotateZ(card:IVisualElement, matrix:Matrix3D, indexedPosition:Number):void
WaveLayout
  
scrollTo(cardIndex:int):void
Scroll the wave layout display to the card with the specified index.
WaveLayout
  
setAlpha(card:IVisualElement, indexedPosition:Number):void
WaveLayout
  
setFilters(layoutElement:ILayoutElement, indexedPosition:Number):void
WaveLayout
  
setXPosition(matrix:Matrix3D, position:Number):void
WaveLayout
  
setYPosition(matrix:Matrix3D, indexedPosition:Number, scale:Number):void
WaveLayout
  
setZDistance(card:IVisualElement, matrix:Matrix3D, indexedPosition:Number):void
WaveLayout
  
WaveLayout
Events
 Event Summary Defined By
  Dispatched after the layout has set its focus to a valid attachment.WaveLayout
Protected Constants
 ConstantDefined By
  DEG2RAD : Number = 0.017453292519943295
WaveLayout
Property Detail
animateproperty
protected var animate:Animate

autoListenproperty 
protected var autoListen:AutoListen

cardDistanceproperty 
cardDistance:Number  [read-only]


Implementation
    protected function get cardDistance():Number
cardLayoutHelperproperty 
cardLayoutHelper:CardLayoutHelper  [read-only]

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The instance of the CardLayoutHelper used by this layout


Implementation
    public function get cardLayoutHelper():CardLayoutHelper
cardPositionproperty 
cardPosition:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The horizontal position of the card, in pixels.

This property can be used as the source for data binding.


Implementation
    public function get cardPosition():Number
    public function set cardPosition(value:Number):void
cardPositionTimerproperty 
protected var cardPositionTimer:Timer

cardSizesInvalidproperty 
protected var cardSizesInvalid:Boolean

easerproperty 
easer:EaseInOutBase

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The easer used for the card animation effect

This property can be used as the source for data binding.


Implementation
    public function get easer():EaseInOutBase
    public function set easer(value:EaseInOutBase):void

See also

spark.effects.easing
fieldOfViewproperty 
fieldOfView:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The angle, specified in degrees greater than 0 and less than 180, for the field of view in three dimensions.

This property can be used as the source for data binding.


Implementation
    public function get fieldOfView():Number
    public function set fieldOfView(value:Number):void

See also

flash.geom.PerspectiveProjection
focusAttachmentproperty 
focusAttachment:IAttachment

This property can be used as the source for data binding.


Implementation
    public function get focusAttachment():IAttachment
    public function set focusAttachment(value:IAttachment):void
focusCardInvalidproperty 
protected var focusCardInvalid:Boolean

itemDistanceproperty 
itemDistance:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The pre-transform distance between each visual item in the wave layout in pixels

This property can be used as the source for data binding.


Implementation
    public function get itemDistance():Number
    public function set itemDistance(value:Number):void
itemHeightproperty 
itemHeight:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

An explicit height for cards in the layout. Setting it to NaN provides automatic sizing.

This property can be used as the source for data binding.


Implementation
    public function get itemHeight():Number
    public function set itemHeight(value:Number):void
itemWidthproperty 
itemWidth:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

An explicit width for cards in the layout. Setting it to NaN provides automatic sizing.

This property can be used as the source for data binding.


Implementation
    public function get itemWidth():Number
    public function set itemWidth(value:Number):void
layoutWidthproperty 
protected var layoutWidth:Number

listproperty 
list:CardList

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The list of attachments being displayed (as cards)

This property can be used as the source for data binding.


Implementation
    public function get list():CardList
    public function set list(value:CardList):void
maxCardPositionproperty 
maxCardPosition:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The maximum horizontal position that a card can have. This is dependent on the target width.

This property can be used as the source for data binding.


Implementation
    public function get maxCardPosition():Number
    public function set maxCardPosition(value:Number):void
pendingCardPositionproperty 
pendingCardPosition:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The pendingCard position


Implementation
    public function get pendingCardPosition():Number
    public function set pendingCardPosition(value:Number):void
perspectiveProjectionproperty 
protected var perspectiveProjection:PerspectiveProjection

scrollAgainproperty 
protected var scrollAgain:Boolean

sineAmpproperty 
sineAmp:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The amplitude of the sine wave used to place cards in the layout, given as a fraction of the target height (nominally, sineAmp is in the range 0 to 1).

This property can be used as the source for data binding.


Implementation
    public function get sineAmp():Number
    public function set sineAmp(value:Number):void
sinePhaseproperty 
sinePhase:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The starting phase angle for the wave function

This property can be used as the source for data binding.


Implementation
    public function get sinePhase():Number
    public function set sinePhase(value:Number):void
sizeInvalidproperty 
protected var sizeInvalid:Boolean

targetproperty 
target:GroupBase[override]

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The target component


Implementation
    public function get target():GroupBase
    public function set target(value:GroupBase):void
thumbFitSizeproperty 
thumbFitSize:Point

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The size to use for preview thumbnails


Implementation
    public function get thumbFitSize():Point
    public function set thumbFitSize(value:Point):void
totalWidthproperty 
protected var totalWidth:Number

yAngleproperty 
yAngle:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Controls the y-axis rotation of cards other than the focus card

This property can be used as the source for data binding.


Implementation
    public function get yAngle():Number
    public function set yAngle(value:Number):void
zAngleproperty 
zAngle:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The y-axis rotation of cards other than the focus card

This property can be used as the source for data binding.


Implementation
    public function get zAngle():Number
    public function set zAngle(value:Number):void
zDistanceproperty 
zDistance:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Controls the z-distance of cards other than the focus card

This property can be used as the source for data binding.


Implementation
    public function get zDistance():Number
    public function set zDistance(value:Number):void

See also

flash.geom.PerspectiveProjection
zDistancePowerproperty 
zDistancePower:Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

The z-distance of cards is determined (in part) by zDistance^^zDistancePower

This property can be used as the source for data binding.


Implementation
    public function get zDistancePower():Number
    public function set zDistancePower(value:Number):void
Constructor Detail
WaveLayout()Constructor
public function WaveLayout()

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Constructor

Method Detail
addListenAndWatch()method
public function addListenAndWatch():void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Add event listeners and change watchers to the navigator.

cardIndexFromPosition()method 
protected function cardIndexFromPosition(cardPosition:Number):int

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Returns the index value for the card at the given horizontal position the cards index value.

Parameters

cardPosition:Number — The horizontal position of the card, in pixels

Returns
int — The index value of the card at the given position
cardPositionFromIndex()method 
protected function cardPositionFromIndex(index:int):Number

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Returns the horizontal card position, in pixels, given the cards index value.

Parameters

index:int — The index value for the card

Returns
Number — the horizontal position of the card, given in pixels
centerCard()method 
protected function centerCard(newCardPosition:Number):void

Parameters

newCardPosition:Number (default = NaN)

commitProperties()method 
protected function commitProperties():void

elementAdded()method 
override public function elementAdded(index:int):void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Parameters

index:int

elementRemoved()method 
override public function elementRemoved(index:int):void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Parameters

index:int

enableCards()method 
protected function enableCards(enabled:Boolean):void

Parameters

enabled:Boolean

fadeInCards()method 
protected function fadeInCards():void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Runs the fadeInCards animation effect.

findCardsThatIntersect()method 
public function findCardsThatIntersect(marqueeRect:Rectangle):Vector.<int>

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Find the list of cards that overlap the specified marquee rectangle.

Parameters

marqueeRect:Rectangle — A bounding rectangle

Returns
Vector.<int> — A vector of integers that represent the indexes of the cards in the layout that intersect the specified marquee rectangle.
getCard()method 
public function getCard(cardPosition:Number):ISimpleCard

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Get the card that has the specified card position

Parameters

cardPosition:Number — The horizontal position of the card, in pixels.

Returns
ISimpleCard
getProjectionCenter()method 
protected function getProjectionCenter():Point

Returns
Point
initBlurFilters()method 
protected function initBlurFilters():void

initColorFilters()method 
protected function initColorFilters():void

invalidateSize()method 
protected function invalidateSize():void

invalidateTarget()method 
protected function invalidateTarget():void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Invalidate the current targer

measure()method 
override public function measure():void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

notifyCardPosition()method 
protected function notifyCardPosition():void

nudgeCard()method 
public function nudgeCard(delta:Number):void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

nudgeCard is called when the user drags a card either left or right. In response the function scrolls one card to the left or right.

Parameters

delta:Number — The amount of the drag move. This must be at least 20 pixels to trigger a scroll.

onAspectRatioChanged()method 
protected function onAspectRatioChanged(event:ThumbnailManagerEvent):void

Parameters

event:ThumbnailManagerEvent

onEndScroll()method 
protected function onEndScroll(e:EffectEvent):void

Parameters

e:EffectEvent

onResize()method 
protected function onResize(event:ResizeEvent):void

Parameters

event:ResizeEvent

removeListenAndWatch()method 
public function removeListenAndWatch():void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Remove all event listeners and change watchers from the navigator

resetCardSizes()method 
protected function resetCardSizes():void

resetPerspective()method 
protected function resetPerspective():void

resetSize()method 
protected function resetSize():void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Resets the target's content size

rotateY()method 
protected function rotateY(card:IVisualElement, matrix:Matrix3D, indexedPosition:Number):void

Parameters

card:IVisualElement
 
matrix:Matrix3D
 
indexedPosition:Number

rotateZ()method 
protected function rotateZ(card:IVisualElement, matrix:Matrix3D, indexedPosition:Number):void

Parameters

card:IVisualElement
 
matrix:Matrix3D
 
indexedPosition:Number

scroll()method 
public function scroll(duration:Number):void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Scroll the cards to the current focusIndex

Parameters

duration:Number (default = NaN) — The duration in miliseconds for the scrolling.

scrollTo()method 
protected function scrollTo(cardIndex:int):void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Scroll the wave layout display to the card with the specified index.

Parameters

cardIndex:int — The index of the card that is to be made the focus

setAlpha()method 
protected function setAlpha(card:IVisualElement, indexedPosition:Number):void

Parameters

card:IVisualElement
 
indexedPosition:Number

setFilters()method 
protected function setFilters(layoutElement:ILayoutElement, indexedPosition:Number):void

Parameters

layoutElement:ILayoutElement
 
indexedPosition:Number

setFocusAttachment()method 
public function setFocusAttachment(attachment:Object):void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Set the target's focus to be the specified attachment

Parameters

attachment:Object — The IAttachement element that is to be the new focus

setXPosition()method 
protected function setXPosition(matrix:Matrix3D, position:Number):void

Parameters

matrix:Matrix3D
 
position:Number

setYPosition()method 
protected function setYPosition(matrix:Matrix3D, indexedPosition:Number, scale:Number):void

Parameters

matrix:Matrix3D
 
indexedPosition:Number
 
scale:Number

setZDistance()method 
protected function setZDistance(card:IVisualElement, matrix:Matrix3D, indexedPosition:Number):void

Parameters

card:IVisualElement
 
matrix:Matrix3D
 
indexedPosition:Number

updateDisplayList()method 
override public function updateDisplayList(width:Number, height:Number):void

Language Version : ActionScript 3.0
Product Version : Portfolio 10.0
Runtime Versions : Flash Player 10.1, AIR 2.0

Parameters

width:Number
 
height:Number

updateMaxCardPosition()method 
protected function updateMaxCardPosition():void

Event Detail
HANDLED_ATTACHMENT_FOCUS Event
Event Object Type: com.adobe.portfolio.events.LayoutEvent
LayoutEvent.type property = com.adobe.portfolio.events.NavLayoutEvent.HANDLED_ATTACHMENT_FOCUS

Dispatched after the layout has set its focus to a valid attachment.

Constant Detail
DEG2RADConstant
protected const DEG2RAD:Number = 0.017453292519943295