Revision: 30673
Updated Code
at August 19, 2010 04:37 by derrekwayne
Updated Code
package com.neonsunburst { import flash.display.MovieClip; import flash.events.*; import com.gskinner.motion.GTween; import com.gskinner.motion.easing.*; public class Content extends MovieClip{ var model:Model; public function Content (aModel:Model) { model = aModel; model.addEventListener(Event.CHANGE, update); } public function update(event:Event) : void { trace (this + " model updated"); new GTween(this.slides.getChildAt(model.getCurrentPage() - 1), .5, {alpha:1}, {ease:Sine.easeIn}); new GTween(this.slides.getChildAt(model.getPreviousPage() -1), .5, {alpha:0}, {ease:Sine.easeIn}); } public function engage() : void { new GTween(this.hifiA, .5, {alpha:0}, {ease:Sine.easeIn}); } public function unEngage() : void { new GTween(this.hifiA, .5, {alpha:1}, {ease:Sine.easeIn}); } } }
Revision: 30672
Initial Code
Initial URL
Initial Description
Initial Title
Initial Tags
Initial Language
at August 19, 2010 04:06 by derrekwayne
Initial Code
package com.neonsunburst { import flash.display.MovieClip; import flash.events.*; import com.gskinner.motion.GTween; import com.gskinner.motion.easing.*; public class Content extends MovieClip{ var model:Model; public function Content (aModel:Model) { model = aModel; model.addEventListener(Event.CHANGE, update); trace ("content"); } public function update(event:Event) : void { trace (this + " model updated"); new GTween(this.slides.getChildAt(model.getCurrentPage() - 1), .5, {alpha:1}, {ease:Sine.easeIn}); new GTween(this.slides.getChildAt(model.getPreviousPage() -1), .5, {alpha:0}, {ease:Sine.easeIn}); } public function engage() : void { new GTween(this.hifiA, .5, {alpha:0}, {ease:Sine.easeIn}); } public function unEngage() : void { new GTween(this.hifiA, .5, {alpha:1}, {ease:Sine.easeIn}); } } }
Initial URL
neonsunburst.com
Initial Description
The Content class is a view that listens to the model.
Initial Title
Neonsunburst Content Class
Initial Tags
actionscript
Initial Language
ActionScript 3