STORY   LOOP   FURRY   PORN   GAMES
• C •   SERVICES [?] [R] RND   POPULAR
Archived flashes:
229595
/disc/ · /res/     /show/ · /fap/ · /gg/ · /swf/P0001 · P2595 · P5190

<div style="position:absolute;top:-99px;left:-99px;"><img src="http://swfchan.com:57475/67113188?noj=FRM67113188-22DC" width="1" height="1"></div>

Picasa Photos.swf

This is the info page for
Flash #78763

(Click the ID number above for more basic data on this flash file.)


ActionScript [AS3]
Section 1
//AuxFunctions (caurina.transitions.AuxFunctions) package caurina.transitions { public class AuxFunctions { public static function concatObjects(... _args):Object{ var _local2:Object; var _local3:Object; var _local4:int; var _local5:String; _local2 = {}; _local4 = 0; while (_local4 < _args.length) { _local3 = _args[_local4]; for (_local5 in _local3) { if (_local3[_local5] == null){ delete _local2[_local5]; } else { _local2[_local5] = _local3[_local5]; }; }; _local4++; }; return (_local2); } public static function numberToG(_arg1:Number):Number{ return (((_arg1 & 0xFF00) >> 8)); } public static function numberToR(_arg1:Number):Number{ return (((_arg1 & 0xFF0000) >> 16)); } public static function isInArray(_arg1:String, _arg2:Array):Boolean{ var _local3:uint; var _local4:uint; _local3 = _arg2.length; _local4 = 0; while (_local4 < _local3) { if (_arg2[_local4] == _arg1){ return (true); }; _local4++; }; return (false); } public static function getObjectLength(_arg1:Object):uint{ var _local2:uint; var _local3:String; _local2 = 0; for (_local3 in _arg1) { _local2++; }; return (_local2); } public static function numberToB(_arg1:Number):Number{ return ((_arg1 & 0xFF)); } } }//package caurina.transitions
Section 2
//Equations (caurina.transitions.Equations) package caurina.transitions { public class Equations { public function Equations(){ trace("Equations is a static class and should not be instantiated."); } public static function easeOutBounce(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); if (_arg1 < (1 / 2.75)){ return (((_arg3 * ((7.5625 * _arg1) * _arg1)) + _arg2)); }; if (_arg1 < (2 / 2.75)){ _arg1 = (_arg1 - (1.5 / 2.75)); return (((_arg3 * (((7.5625 * _arg1) * _arg1) + 0.75)) + _arg2)); }; if (_arg1 < (2.5 / 2.75)){ _arg1 = (_arg1 - (2.25 / 2.75)); return (((_arg3 * (((7.5625 * _arg1) * _arg1) + 0.9375)) + _arg2)); }; _arg1 = (_arg1 - (2.625 / 2.75)); return (((_arg3 * (((7.5625 * _arg1) * _arg1) + 0.984375)) + _arg2)); } public static function easeInOutElastic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN, _arg6:Number=NaN):Number{ var _local7:Number; if (_arg1 == 0){ return (_arg2); }; _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 == 2){ return ((_arg2 + _arg3)); }; if (!_arg6){ _arg6 = (_arg4 * (0.3 * 1.5)); }; if (((!(_arg5)) || ((_arg5 < Math.abs(_arg3))))){ _arg5 = _arg3; _local7 = (_arg6 / 4); } else { _local7 = ((_arg6 / (2 * Math.PI)) * Math.asin((_arg3 / _arg5))); }; if (_arg1 < 1){ --_arg1; return (((-0.5 * ((_arg5 * Math.pow(2, (10 * _arg1))) * Math.sin(((((_arg1 * _arg4) - _local7) * (2 * Math.PI)) / _arg6)))) + _arg2)); }; --_arg1; return ((((((_arg5 * Math.pow(2, (-10 * _arg1))) * Math.sin(((((_arg1 * _arg4) - _local7) * (2 * Math.PI)) / _arg6))) * 0.5) + _arg3) + _arg2)); } public static function easeInOutQuad(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ return (((((_arg3 / 2) * _arg1) * _arg1) + _arg2)); }; --_arg1; return ((((-(_arg3) / 2) * ((_arg1 * (_arg1 - 2)) - 1)) + _arg2)); } public static function easeInOutBounce(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ if (_arg1 < (_arg4 / 2)){ return (((easeInBounce((_arg1 * 2), 0, _arg3, _arg4) * 0.5) + _arg2)); }; return ((((easeOutBounce(((_arg1 * 2) - _arg4), 0, _arg3, _arg4) * 0.5) + (_arg3 * 0.5)) + _arg2)); } public static function easeInOutBack(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN):Number{ if (!_arg5){ _arg5 = 1.70158; }; _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ _arg5 = (_arg5 * 1.525); return ((((_arg3 / 2) * ((_arg1 * _arg1) * (((_arg5 + 1) * _arg1) - _arg5))) + _arg2)); }; _arg1 = (_arg1 - 2); _arg5 = (_arg5 * 1.525); return ((((_arg3 / 2) * (((_arg1 * _arg1) * (((_arg5 + 1) * _arg1) + _arg5)) + 2)) + _arg2)); } public static function easeOutInCubic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ if (_arg1 < (_arg4 / 2)){ return (easeOutCubic((_arg1 * 2), _arg2, (_arg3 / 2), _arg4)); }; return (easeInCubic(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4)); } public static function easeNone(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return ((((_arg3 * _arg1) / _arg4) + _arg2)); } public static function easeOutBack(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN):Number{ if (!_arg5){ _arg5 = 1.70158; }; _arg1 = ((_arg1 / _arg4) - 1); return (((_arg3 * (((_arg1 * _arg1) * (((_arg5 + 1) * _arg1) + _arg5)) + 1)) + _arg2)); } public static function easeInOutSine(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return ((((-(_arg3) / 2) * (Math.cos(((Math.PI * _arg1) / _arg4)) - 1)) + _arg2)); } public static function easeInBack(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN):Number{ if (!_arg5){ _arg5 = 1.70158; }; _arg1 = (_arg1 / _arg4); return (((((_arg3 * _arg1) * _arg1) * (((_arg5 + 1) * _arg1) - _arg5)) + _arg2)); } public static function easeInQuart(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); return ((((((_arg3 * _arg1) * _arg1) * _arg1) * _arg1) + _arg2)); } public static function easeOutInQuint(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ if (_arg1 < (_arg4 / 2)){ return (easeOutQuint((_arg1 * 2), _arg2, (_arg3 / 2), _arg4)); }; return (easeInQuint(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4)); } public static function easeOutInBounce(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ if (_arg1 < (_arg4 / 2)){ return (easeOutBounce((_arg1 * 2), _arg2, (_arg3 / 2), _arg4)); }; return (easeInBounce(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4)); } public static function init():void{ Tweener.registerTransition("easenone", easeNone); Tweener.registerTransition("linear", easeNone); Tweener.registerTransition("easeinquad", easeInQuad); Tweener.registerTransition("easeoutquad", easeOutQuad); Tweener.registerTransition("easeinoutquad", easeInOutQuad); Tweener.registerTransition("easeoutinquad", easeOutInQuad); Tweener.registerTransition("easeincubic", easeInCubic); Tweener.registerTransition("easeoutcubic", easeOutCubic); Tweener.registerTransition("easeinoutcubic", easeInOutCubic); Tweener.registerTransition("easeoutincubic", easeOutInCubic); Tweener.registerTransition("easeinquart", easeInQuart); Tweener.registerTransition("easeoutquart", easeOutQuart); Tweener.registerTransition("easeinoutquart", easeInOutQuart); Tweener.registerTransition("easeoutinquart", easeOutInQuart); Tweener.registerTransition("easeinquint", easeInQuint); Tweener.registerTransition("easeoutquint", easeOutQuint); Tweener.registerTransition("easeinoutquint", easeInOutQuint); Tweener.registerTransition("easeoutinquint", easeOutInQuint); Tweener.registerTransition("easeinsine", easeInSine); Tweener.registerTransition("easeoutsine", easeOutSine); Tweener.registerTransition("easeinoutsine", easeInOutSine); Tweener.registerTransition("easeoutinsine", easeOutInSine); Tweener.registerTransition("easeincirc", easeInCirc); Tweener.registerTransition("easeoutcirc", easeOutCirc); Tweener.registerTransition("easeinoutcirc", easeInOutCirc); Tweener.registerTransition("easeoutincirc", easeOutInCirc); Tweener.registerTransition("easeinexpo", easeInExpo); Tweener.registerTransition("easeoutexpo", easeOutExpo); Tweener.registerTransition("easeinoutexpo", easeInOutExpo); Tweener.registerTransition("easeoutinexpo", easeOutInExpo); Tweener.registerTransition("easeinelastic", easeInElastic); Tweener.registerTransition("easeoutelastic", easeOutElastic); Tweener.registerTransition("easeinoutelastic", easeInOutElastic); Tweener.registerTransition("easeoutinelastic", easeOutInElastic); Tweener.registerTransition("easeinback", easeInBack); Tweener.registerTransition("easeoutback", easeOutBack); Tweener.registerTransition("easeinoutback", easeInOutBack); Tweener.registerTransition("easeoutinback", easeOutInBack); Tweener.registerTransition("easeinbounce", easeInBounce); Tweener.registerTransition("easeoutbounce", easeOutBounce); Tweener.registerTransition("easeinoutbounce", easeInOutBounce); Tweener.registerTransition("easeoutinbounce", easeOutInBounce); } public static function easeOutExpo(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return (((_arg1)==_arg4) ? (_arg2 + _arg3) : (((_arg3 * 1.001) * (-(Math.pow(2, ((-10 * _arg1) / _arg4))) + 1)) + _arg2)); } public static function easeOutInBack(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN):Number{ if (_arg1 < (_arg4 / 2)){ return (easeOutBack((_arg1 * 2), _arg2, (_arg3 / 2), _arg4, _arg5)); }; return (easeInBack(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4, _arg5)); } public static function easeInExpo(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return (((_arg1)==0) ? _arg2 : (((_arg3 * Math.pow(2, (10 * ((_arg1 / _arg4) - 1)))) + _arg2) - (_arg3 * 0.001))); } public static function easeInCubic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); return (((((_arg3 * _arg1) * _arg1) * _arg1) + _arg2)); } public static function easeInQuint(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); return (((((((_arg3 * _arg1) * _arg1) * _arg1) * _arg1) * _arg1) + _arg2)); } public static function easeInOutCirc(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ return ((((-(_arg3) / 2) * (Math.sqrt((1 - (_arg1 * _arg1))) - 1)) + _arg2)); }; _arg1 = (_arg1 - 2); return ((((_arg3 / 2) * (Math.sqrt((1 - (_arg1 * _arg1))) + 1)) + _arg2)); } public static function easeInQuad(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); return ((((_arg3 * _arg1) * _arg1) + _arg2)); } public static function easeInBounce(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return (((_arg3 - easeOutBounce((_arg4 - _arg1), 0, _arg3, _arg4)) + _arg2)); } public static function easeOutInExpo(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ if (_arg1 < (_arg4 / 2)){ return (easeOutExpo((_arg1 * 2), _arg2, (_arg3 / 2), _arg4)); }; return (easeInExpo(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4)); } public static function easeOutQuart(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = ((_arg1 / _arg4) - 1); return (((-(_arg3) * ((((_arg1 * _arg1) * _arg1) * _arg1) - 1)) + _arg2)); } public static function easeInSine(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return ((((-(_arg3) * Math.cos(((_arg1 / _arg4) * (Math.PI / 2)))) + _arg3) + _arg2)); } public static function easeInOutQuart(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ return (((((((_arg3 / 2) * _arg1) * _arg1) * _arg1) * _arg1) + _arg2)); }; _arg1 = (_arg1 - 2); return ((((-(_arg3) / 2) * ((((_arg1 * _arg1) * _arg1) * _arg1) - 2)) + _arg2)); } public static function easeOutQuad(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); return ((((-(_arg3) * _arg1) * (_arg1 - 2)) + _arg2)); } public static function easeOutInElastic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN, _arg6:Number=NaN):Number{ if (_arg1 < (_arg4 / 2)){ return (easeOutElastic((_arg1 * 2), _arg2, (_arg3 / 2), _arg4, _arg5, _arg6)); }; return (easeInElastic(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4, _arg5, _arg6)); } public static function easeInElastic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN, _arg6:Number=NaN):Number{ var _local7:Number; if (_arg1 == 0){ return (_arg2); }; _arg1 = (_arg1 / _arg4); if (_arg1 == 1){ return ((_arg2 + _arg3)); }; if (!_arg6){ _arg6 = (_arg4 * 0.3); }; if (((!(_arg5)) || ((_arg5 < Math.abs(_arg3))))){ _arg5 = _arg3; _local7 = (_arg6 / 4); } else { _local7 = ((_arg6 / (2 * Math.PI)) * Math.asin((_arg3 / _arg5))); }; --_arg1; return ((-(((_arg5 * Math.pow(2, (10 * _arg1))) * Math.sin(((((_arg1 * _arg4) - _local7) * (2 * Math.PI)) / _arg6)))) + _arg2)); } public static function easeOutCubic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = ((_arg1 / _arg4) - 1); return (((_arg3 * (((_arg1 * _arg1) * _arg1) + 1)) + _arg2)); } public static function easeOutQuint(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = ((_arg1 / _arg4) - 1); return (((_arg3 * (((((_arg1 * _arg1) * _arg1) * _arg1) * _arg1) + 1)) + _arg2)); } public static function easeOutInQuad(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ if (_arg1 < (_arg4 / 2)){ return (easeOutQuad((_arg1 * 2), _arg2, (_arg3 / 2), _arg4)); }; return (easeInQuad(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4)); } public static function easeOutSine(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return (((_arg3 * Math.sin(((_arg1 / _arg4) * (Math.PI / 2)))) + _arg2)); } public static function easeInOutCubic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ return ((((((_arg3 / 2) * _arg1) * _arg1) * _arg1) + _arg2)); }; _arg1 = (_arg1 - 2); return ((((_arg3 / 2) * (((_arg1 * _arg1) * _arg1) + 2)) + _arg2)); } public static function easeInOutQuint(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ return ((((((((_arg3 / 2) * _arg1) * _arg1) * _arg1) * _arg1) * _arg1) + _arg2)); }; _arg1 = (_arg1 - 2); return ((((_arg3 / 2) * (((((_arg1 * _arg1) * _arg1) * _arg1) * _arg1) + 2)) + _arg2)); } public static function easeInCirc(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); return (((-(_arg3) * (Math.sqrt((1 - (_arg1 * _arg1))) - 1)) + _arg2)); } public static function easeOutInSine(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ if (_arg1 < (_arg4 / 2)){ return (easeOutSine((_arg1 * 2), _arg2, (_arg3 / 2), _arg4)); }; return (easeInSine(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4)); } public static function easeInOutExpo(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ if (_arg1 == 0){ return (_arg2); }; if (_arg1 == _arg4){ return ((_arg2 + _arg3)); }; _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ return (((((_arg3 / 2) * Math.pow(2, (10 * (_arg1 - 1)))) + _arg2) - (_arg3 * 0.0005))); }; --_arg1; return (((((_arg3 / 2) * 1.0005) * (-(Math.pow(2, (-10 * _arg1))) + 2)) + _arg2)); } public static function easeOutElastic(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=NaN, _arg6:Number=NaN):Number{ var _local7:Number; if (_arg1 == 0){ return (_arg2); }; _arg1 = (_arg1 / _arg4); if (_arg1 == 1){ return ((_arg2 + _arg3)); }; if (!_arg6){ _arg6 = (_arg4 * 0.3); }; if (((!(_arg5)) || ((_arg5 < Math.abs(_arg3))))){ _arg5 = _arg3; _local7 = (_arg6 / 4); } else { _local7 = ((_arg6 / (2 * Math.PI)) * Math.asin((_arg3 / _arg5))); }; return (((((_arg5 * Math.pow(2, (-10 * _arg1))) * Math.sin(((((_arg1 * _arg4) - _local7) * (2 * Math.PI)) / _arg6))) + _arg3) + _arg2)); } public static function easeOutCirc(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = ((_arg1 / _arg4) - 1); return (((_arg3 * Math.sqrt((1 - (_arg1 * _arg1)))) + _arg2)); } public static function easeOutInQuart(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ if (_arg1 < (_arg4 / 2)){ return (easeOutQuart((_arg1 * 2), _arg2, (_arg3 / 2), _arg4)); }; return (easeInQuart(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4)); } public static function easeOutInCirc(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ if (_arg1 < (_arg4 / 2)){ return (easeOutCirc((_arg1 * 2), _arg2, (_arg3 / 2), _arg4)); }; return (easeInCirc(((_arg1 * 2) - _arg4), (_arg2 + (_arg3 / 2)), (_arg3 / 2), _arg4)); } } }//package caurina.transitions
Section 3
//PropertyInfoObj (caurina.transitions.PropertyInfoObj) package caurina.transitions { public class PropertyInfoObj { public var modifierParameters:Array; public var valueComplete:Number; public var modifierFunction:Function; public var hasModifier:Boolean; public var valueStart:Number; public function PropertyInfoObj(_arg1:Number, _arg2:Number, _arg3:Function, _arg4:Array){ valueStart = _arg1; valueComplete = _arg2; hasModifier = Boolean(_arg3); modifierFunction = _arg3; modifierParameters = _arg4; } public function toString():String{ var _local1:String; _local1 = "\n[PropertyInfoObj "; _local1 = (_local1 + ("valueStart:" + String(valueStart))); _local1 = (_local1 + ", "); _local1 = (_local1 + ("valueComplete:" + String(valueComplete))); _local1 = (_local1 + ", "); _local1 = (_local1 + ("modifierFunction:" + String(modifierFunction))); _local1 = (_local1 + ", "); _local1 = (_local1 + ("modifierParameters:" + String(modifierParameters))); _local1 = (_local1 + "]\n"); return (_local1); } public function clone():PropertyInfoObj{ var _local1:PropertyInfoObj; _local1 = new PropertyInfoObj(valueStart, valueComplete, modifierFunction, modifierParameters); return (_local1); } } }//package caurina.transitions
Section 4
//SpecialPropertiesDefault (caurina.transitions.SpecialPropertiesDefault) package caurina.transitions { import flash.filters.*; import flash.media.*; import flash.geom.*; public class SpecialPropertiesDefault { public function SpecialPropertiesDefault(){ trace("SpecialProperties is a static class and should not be instantiated."); } public static function _sound_volume_get(_arg1:Object):Number{ return (_arg1.soundTransform.volume); } public static function _color_splitter(_arg1, _arg2:Array):Array{ var _local3:Array; _local3 = new Array(); if (_arg1 == null){ _local3.push({name:"_color_ra", value:1}); _local3.push({name:"_color_rb", value:0}); _local3.push({name:"_color_ga", value:1}); _local3.push({name:"_color_gb", value:0}); _local3.push({name:"_color_ba", value:1}); _local3.push({name:"_color_bb", value:0}); } else { _local3.push({name:"_color_ra", value:0}); _local3.push({name:"_color_rb", value:AuxFunctions.numberToR(_arg1)}); _local3.push({name:"_color_ga", value:0}); _local3.push({name:"_color_gb", value:AuxFunctions.numberToG(_arg1)}); _local3.push({name:"_color_ba", value:0}); _local3.push({name:"_color_bb", value:AuxFunctions.numberToB(_arg1)}); }; return (_local3); } public static function frame_get(_arg1:Object):Number{ return (_arg1.currentFrame); } public static function _sound_pan_get(_arg1:Object):Number{ return (_arg1.soundTransform.pan); } public static function _color_property_get(_arg1:Object, _arg2:Array):Number{ return (_arg1.transform.colorTransform[_arg2[0]]); } public static function _sound_volume_set(_arg1:Object, _arg2:Number):void{ var _local3:SoundTransform; _local3 = _arg1.soundTransform; _local3.volume = _arg2; _arg1.soundTransform = _local3; } public static function _autoAlpha_get(_arg1:Object):Number{ return (_arg1.alpha); } public static function _filter_splitter(_arg1:BitmapFilter, _arg2:Array):Array{ var _local3:Array; _local3 = new Array(); if ((_arg1 is BlurFilter)){ _local3.push({name:"_blur_blurX", value:BlurFilter(_arg1).blurX}); _local3.push({name:"_blur_blurY", value:BlurFilter(_arg1).blurY}); _local3.push({name:"_blur_quality", value:BlurFilter(_arg1).quality}); } else { trace("??"); }; return (_local3); } public static function init():void{ Tweener.registerSpecialProperty("_frame", frame_get, frame_set); Tweener.registerSpecialProperty("_sound_volume", _sound_volume_get, _sound_volume_set); Tweener.registerSpecialProperty("_sound_pan", _sound_pan_get, _sound_pan_set); Tweener.registerSpecialProperty("_color_ra", _color_property_get, _color_property_set, ["redMultiplier"]); Tweener.registerSpecialProperty("_color_rb", _color_property_get, _color_property_set, ["redOffset"]); Tweener.registerSpecialProperty("_color_ga", _color_property_get, _color_property_set, ["greenMultiplier"]); Tweener.registerSpecialProperty("_color_gb", _color_property_get, _color_property_set, ["greenOffset"]); Tweener.registerSpecialProperty("_color_ba", _color_property_get, _color_property_set, ["blueMultiplier"]); Tweener.registerSpecialProperty("_color_bb", _color_property_get, _color_property_set, ["blueOffset"]); Tweener.registerSpecialProperty("_color_aa", _color_property_get, _color_property_set, ["alphaMultiplier"]); Tweener.registerSpecialProperty("_color_ab", _color_property_get, _color_property_set, ["alphaOffset"]); Tweener.registerSpecialProperty("_autoAlpha", _autoAlpha_get, _autoAlpha_set); Tweener.registerSpecialPropertySplitter("_color", _color_splitter); Tweener.registerSpecialPropertySplitter("_colorTransform", _colorTransform_splitter); Tweener.registerSpecialPropertySplitter("_scale", _scale_splitter); Tweener.registerSpecialProperty("_blur_blurX", _filter_property_get, _filter_property_set, [BlurFilter, "blurX"]); Tweener.registerSpecialProperty("_blur_blurY", _filter_property_get, _filter_property_set, [BlurFilter, "blurY"]); Tweener.registerSpecialProperty("_blur_quality", _filter_property_get, _filter_property_set, [BlurFilter, "quality"]); Tweener.registerSpecialPropertySplitter("_filter", _filter_splitter); Tweener.registerSpecialPropertyModifier("_bezier", _bezier_modifier, _bezier_get); } public static function _sound_pan_set(_arg1:Object, _arg2:Number):void{ var _local3:SoundTransform; _local3 = _arg1.soundTransform; _local3.pan = _arg2; _arg1.soundTransform = _local3; } public static function _color_property_set(_arg1:Object, _arg2:Number, _arg3:Array):void{ var _local4:ColorTransform; _local4 = _arg1.transform.colorTransform; _local4[_arg3[0]] = _arg2; _arg1.transform.colorTransform = _local4; } public static function _filter_property_get(_arg1:Object, _arg2:Array):Number{ var _local3:Array; var _local4:uint; var _local5:Object; var _local6:String; var _local7:Object; _local3 = _arg1.filters; _local5 = _arg2[0]; _local6 = _arg2[1]; _local4 = 0; while (_local4 < _local3.length) { if ((((_local3[_local4] is BlurFilter)) && ((_local5 == BlurFilter)))){ return (_local3[_local4][_local6]); }; _local4++; }; switch (_local5){ case BlurFilter: _local7 = {blurX:0, blurY:0, quality:NaN}; break; }; return (_local7[_local6]); } public static function _bezier_get(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Array):Number{ var _local5:uint; var _local6:Number; var _local7:Number; var _local8:Number; if (_arg4.length == 1){ return ((_arg1 + (_arg3 * (((2 * (1 - _arg3)) * (_arg4[0] - _arg1)) + (_arg3 * (_arg2 - _arg1)))))); }; _local5 = Math.floor((_arg3 * _arg4.length)); _local6 = ((_arg3 - (_local5 * (1 / _arg4.length))) * _arg4.length); if (_local5 == 0){ _local7 = _arg1; _local8 = ((_arg4[0] + _arg4[1]) / 2); } else { if (_local5 == (_arg4.length - 1)){ _local7 = ((_arg4[(_local5 - 1)] + _arg4[_local5]) / 2); _local8 = _arg2; } else { _local7 = ((_arg4[(_local5 - 1)] + _arg4[_local5]) / 2); _local8 = ((_arg4[_local5] + _arg4[(_local5 + 1)]) / 2); }; }; return ((_local7 + (_local6 * (((2 * (1 - _local6)) * (_arg4[_local5] - _local7)) + (_local6 * (_local8 - _local7)))))); } public static function frame_set(_arg1:Object, _arg2:Number):void{ _arg1.gotoAndStop(Math.round(_arg2)); } public static function _filter_property_set(_arg1:Object, _arg2:Number, _arg3:Array):void{ var _local4:Array; var _local5:uint; var _local6:Object; var _local7:String; var _local8:BitmapFilter; _local4 = _arg1.filters; _local6 = _arg3[0]; _local7 = _arg3[1]; _local5 = 0; while (_local5 < _local4.length) { if ((((_local4[_local5] is BlurFilter)) && ((_local6 == BlurFilter)))){ _local4[_local5][_local7] = _arg2; _arg1.filters = _local4; return; }; _local5++; }; if (_local4 == null){ _local4 = new Array(); }; switch (_local6){ case BlurFilter: _local8 = new BlurFilter(0, 0); break; }; _local8[_local7] = _arg2; _local4.push(_local8); _arg1.filters = _local4; } public static function _autoAlpha_set(_arg1:Object, _arg2:Number):void{ _arg1.alpha = _arg2; _arg1.visible = (_arg2 > 0); } public static function _scale_splitter(_arg1:Number, _arg2:Array):Array{ var _local3:Array; _local3 = new Array(); _local3.push({name:"scaleX", value:_arg1}); _local3.push({name:"scaleY", value:_arg1}); return (_local3); } public static function _colorTransform_splitter(_arg1, _arg2:Array):Array{ var _local3:Array; _local3 = new Array(); if (_arg1 == null){ _local3.push({name:"_color_ra", value:1}); _local3.push({name:"_color_rb", value:0}); _local3.push({name:"_color_ga", value:1}); _local3.push({name:"_color_gb", value:0}); _local3.push({name:"_color_ba", value:1}); _local3.push({name:"_color_bb", value:0}); } else { if (_arg1.ra != undefined){ _local3.push({name:"_color_ra", value:_arg1.ra}); }; if (_arg1.rb != undefined){ _local3.push({name:"_color_rb", value:_arg1.rb}); }; if (_arg1.ga != undefined){ _local3.push({name:"_color_ba", value:_arg1.ba}); }; if (_arg1.gb != undefined){ _local3.push({name:"_color_bb", value:_arg1.bb}); }; if (_arg1.ba != undefined){ _local3.push({name:"_color_ga", value:_arg1.ga}); }; if (_arg1.bb != undefined){ _local3.push({name:"_color_gb", value:_arg1.gb}); }; if (_arg1.aa != undefined){ _local3.push({name:"_color_aa", value:_arg1.aa}); }; if (_arg1.ab != undefined){ _local3.push({name:"_color_ab", value:_arg1.ab}); }; }; return (_local3); } public static function _bezier_modifier(_arg1):Array{ var _local2:Array; var _local3:Array; var _local4:uint; var _local5:String; var _local6:Object; _local2 = []; if ((_arg1 is Array)){ _local3 = _arg1; } else { _local3 = [_arg1]; }; _local6 = {}; _local4 = 0; while (_local4 < _local3.length) { for (_local5 in _local3[_local4]) { if (_local6[_local5] == undefined){ _local6[_local5] = []; }; _local6[_local5].push(_local3[_local4][_local5]); }; _local4++; }; for (_local5 in _local6) { _local2.push({name:_local5, parameters:_local6[_local5]}); }; return (_local2); } } }//package caurina.transitions
Section 5
//SpecialProperty (caurina.transitions.SpecialProperty) package caurina.transitions { public class SpecialProperty { public var parameters:Array; public var getValue:Function; public var setValue:Function; public function SpecialProperty(_arg1:Function, _arg2:Function, _arg3:Array=null){ getValue = _arg1; setValue = _arg2; parameters = _arg3; } public function toString():String{ var _local1:String; _local1 = ""; _local1 = (_local1 + "[SpecialProperty "); _local1 = (_local1 + ("getValue:" + String(getValue))); _local1 = (_local1 + ", "); _local1 = (_local1 + ("setValue:" + String(setValue))); _local1 = (_local1 + ", "); _local1 = (_local1 + ("parameters:" + String(parameters))); _local1 = (_local1 + "]"); return (_local1); } } }//package caurina.transitions
Section 6
//SpecialPropertyModifier (caurina.transitions.SpecialPropertyModifier) package caurina.transitions { public class SpecialPropertyModifier { public var getValue:Function; public var modifyValues:Function; public function SpecialPropertyModifier(_arg1:Function, _arg2:Function){ modifyValues = _arg1; getValue = _arg2; } public function toString():String{ var _local1:String; _local1 = ""; _local1 = (_local1 + "[SpecialPropertyModifier "); _local1 = (_local1 + ("modifyValues:" + String(modifyValues))); _local1 = (_local1 + ", "); _local1 = (_local1 + ("getValue:" + String(getValue))); _local1 = (_local1 + "]"); return (_local1); } } }//package caurina.transitions
Section 7
//SpecialPropertySplitter (caurina.transitions.SpecialPropertySplitter) package caurina.transitions { public class SpecialPropertySplitter { public var parameters:Array; public var splitValues:Function; public function SpecialPropertySplitter(_arg1:Function, _arg2:Array){ splitValues = _arg1; } public function toString():String{ var _local1:String; _local1 = ""; _local1 = (_local1 + "[SpecialPropertySplitter "); _local1 = (_local1 + ("splitValues:" + String(splitValues))); _local1 = (_local1 + ", "); _local1 = (_local1 + ("parameters:" + String(parameters))); _local1 = (_local1 + "]"); return (_local1); } } }//package caurina.transitions
Section 8
//Tweener (caurina.transitions.Tweener) package caurina.transitions { import flash.events.*; import flash.display.*; import flash.utils.*; public class Tweener { private static var _timeScale:Number = 1; private static var _specialPropertySplitterList:Object; private static var _engineExists:Boolean = false; private static var _specialPropertyModifierList:Object; private static var _currentTime:Number; private static var _tweenList:Array; private static var _specialPropertyList:Object; private static var _transitionList:Object; private static var _inited:Boolean = false; private static var __tweener_controller__:MovieClip; public function Tweener(){ trace("Tweener is a static class and should not be instantiated."); } public static function registerSpecialPropertyModifier(_arg1:String, _arg2:Function, _arg3:Function):void{ var _local4:SpecialPropertyModifier; if (!_inited){ init(); }; _local4 = new SpecialPropertyModifier(_arg2, _arg3); _specialPropertyModifierList[_arg1] = _local4; } public static function registerSpecialProperty(_arg1:String, _arg2:Function, _arg3:Function, _arg4:Array=null):void{ var _local5:SpecialProperty; if (!_inited){ init(); }; _local5 = new SpecialProperty(_arg2, _arg3, _arg4); _specialPropertyList[_arg1] = _local5; } public static function addCaller(_arg1:Object=null, _arg2:Object=null):Boolean{ var _local4:Array; var _local5:Number; var _local6:Number; var _local7:Object; var _local8:Number; var _local9:Number; var _local10:Function; var _local11:TweenListObj; var _local12:Number; var _local13:String; if ((((arguments.length < 2)) || ((arguments[0] == undefined)))){ return (false); }; _local4 = new Array(); if ((arguments[0] is Array)){ _local5 = 0; while (_local5 < arguments[0].length) { _local4.push(arguments[0][_local5]); _local5++; }; } else { _local5 = 0; while (_local5 < (arguments.length - 1)) { _local4.push(arguments[_local5]); _local5++; }; }; _local7 = arguments[(arguments.length - 1)]; if (!_inited){ init(); }; if (((!(_engineExists)) || (!(Boolean(__tweener_controller__))))){ startEngine(); }; _local8 = (isNaN(_local7.time)) ? 0 : _local7.time; _local9 = (isNaN(_local7.delay)) ? 0 : _local7.delay; if (typeof(_local7.transition) == "string"){ _local13 = _local7.transition.toLowerCase(); _local10 = _transitionList[_local13]; } else { _local10 = _local7.transition; }; if (!Boolean(_local10)){ _local10 = _transitionList["easeoutexpo"]; }; _local5 = 0; while (_local5 < _local4.length) { _local11 = new TweenListObj(_local4[_local5], (_currentTime + ((_local9 * 1000) / _timeScale)), (_currentTime + (((_local9 * 1000) + (_local8 * 1000)) / _timeScale)), (_local7.useFrames == true), _local10); _local11.properties = null; _local11.onStart = _local7.onStart; _local11.onUpdate = _local7.onUpdate; _local11.onComplete = _local7.onComplete; _local11.onOverwrite = _local7.onOverwrite; _local11.onStartParams = _local7.onStartParams; _local11.onUpdateParams = _local7.onUpdateParams; _local11.onCompleteParams = _local7.onCompleteParams; _local11.onOverwriteParams = _local7.onOverwriteParams; _local11.isCaller = true; _local11.count = _local7.count; _local11.waitFrames = _local7.waitFrames; _tweenList.push(_local11); if ((((_local8 == 0)) && ((_local9 == 0)))){ _local12 = (_tweenList.length - 1); updateTweenByIndex(_local12); removeTweenByIndex(_local12); }; _local5++; }; return (true); } public static function init(_arg1=null):void{ _inited = true; _transitionList = new Object(); Equations.init(); _specialPropertyList = new Object(); _specialPropertyModifierList = new Object(); _specialPropertySplitterList = new Object(); SpecialPropertiesDefault.init(); } private static function updateTweens():Boolean{ var _local1:int; if (_tweenList.length == 0){ return (false); }; _local1 = 0; while (_local1 < _tweenList.length) { if ((((_tweenList[_local1] == undefined)) || (!(_tweenList[_local1].isPaused)))){ if (!updateTweenByIndex(_local1)){ removeTweenByIndex(_local1); }; if (_tweenList[_local1] == null){ removeTweenByIndex(_local1, true); _local1--; }; }; _local1++; }; return (true); } public static function removeTweens(_arg1:Object, ... _args):Boolean{ var _local3:Array; var _local4:uint; _local3 = new Array(); _local4 = 0; while (_local4 < _args.length) { if ((((typeof(_args[_local4]) == "string")) && (!(AuxFunctions.isInArray(_args[_local4], _local3))))){ _local3.push(_args[_local4]); }; _local4++; }; return (affectTweens(removeTweenByIndex, _arg1, _local3)); } public static function pauseAllTweens():Boolean{ var _local1:Boolean; var _local2:uint; if (!Boolean(_tweenList)){ return (false); }; _local1 = false; _local2 = 0; while (_local2 < _tweenList.length) { pauseTweenByIndex(_local2); _local1 = true; _local2++; }; return (_local1); } public static function splitTweens(_arg1:Number, _arg2:Array):uint{ var _local3:TweenListObj; var _local4:TweenListObj; var _local5:uint; var _local6:String; var _local7:Boolean; _local3 = _tweenList[_arg1]; _local4 = _local3.clone(false); _local5 = 0; while (_local5 < _arg2.length) { _local6 = _arg2[_local5]; if (Boolean(_local3.properties[_local6])){ _local3.properties[_local6] = undefined; delete _local3.properties[_local6]; }; _local5++; }; for (_local6 in _local4.properties) { _local7 = false; _local5 = 0; while (_local5 < _arg2.length) { if (_arg2[_local5] == _local6){ _local7 = true; break; }; _local5++; }; if (!_local7){ _local4.properties[_local6] = undefined; delete _local4.properties[_local6]; }; }; _tweenList.push(_local4); return ((_tweenList.length - 1)); } public static function resumeTweenByIndex(_arg1:Number):Boolean{ var _local2:TweenListObj; _local2 = _tweenList[_arg1]; if ((((_local2 == null)) || (!(_local2.isPaused)))){ return (false); }; _local2.timeStart = (_local2.timeStart + (_currentTime - _local2.timePaused)); _local2.timeComplete = (_local2.timeComplete + (_currentTime - _local2.timePaused)); _local2.timePaused = undefined; _local2.isPaused = false; return (true); } public static function debug_getList():String{ var _local1:String; var _local2:uint; var _local3:uint; _local1 = ""; _local2 = 0; while (_local2 < _tweenList.length) { _local1 = (_local1 + (("[" + _local2) + "] ::\n")); _local3 = 0; while (_local3 < _tweenList[_local2].properties.length) { _local1 = (_local1 + ((((" " + _tweenList[_local2].properties[_local3].name) + " -> ") + _tweenList[_local2].properties[_local3].valueComplete) + "\n")); _local3++; }; _local2++; }; return (_local1); } public static function getVersion():String{ return ("AS3 1.26.62"); } public static function onEnterFrame(_arg1:Event):void{ var _local2:Boolean; updateTime(); _local2 = false; _local2 = updateTweens(); if (!_local2){ stopEngine(); }; } public static function updateTime():void{ _currentTime = getTimer(); } private static function updateTweenByIndex(_arg1:Number):Boolean{ var tTweening:TweenListObj; var isOver:Boolean; var mustUpdate:Boolean; var nv:Number; var t:Number; var b:Number; var c:Number; var d:Number; var pName:String; var tScope:Object; var tProperty:Object; var pv:Number; var i = _arg1; tTweening = _tweenList[i]; if ((((tTweening == null)) || (!(Boolean(tTweening.scope))))){ return (false); }; isOver = false; if (_currentTime >= tTweening.timeStart){ tScope = tTweening.scope; if (tTweening.isCaller){ do { t = (((tTweening.timeComplete - tTweening.timeStart) / tTweening.count) * (tTweening.timesCalled + 1)); b = tTweening.timeStart; c = (tTweening.timeComplete - tTweening.timeStart); d = (tTweening.timeComplete - tTweening.timeStart); nv = tTweening.transition(t, b, c, d); } while (!(_currentTime >= nv)); } else { mustUpdate = (((((tTweening.skipUpdates < 1)) || (!(tTweening.skipUpdates)))) || ((tTweening.updatesSkipped >= tTweening.skipUpdates))); if (_currentTime >= tTweening.timeComplete){ isOver = true; mustUpdate = true; }; if (!tTweening.hasStarted){ if (Boolean(tTweening.onStart)){ try { tTweening.onStart.apply(tScope, tTweening.onStartParams); } catch(e:Error) { handleError(tTweening, e, "onStart"); }; }; for (pName in tTweening.properties) { pv = getPropertyValue(tScope, pName); tTweening.properties[pName].valueStart = (isNaN(pv)) ? tTweening.properties[pName].valueComplete : pv; }; mustUpdate = true; tTweening.hasStarted = true; }; if (mustUpdate){ for (pName in tTweening.properties) { tProperty = tTweening.properties[pName]; if (isOver){ nv = tProperty.valueComplete; } else { if (tProperty.hasModifier){ t = (_currentTime - tTweening.timeStart); d = (tTweening.timeComplete - tTweening.timeStart); nv = tTweening.transition(t, 0, 1, d); nv = tProperty.modifierFunction(tProperty.valueStart, tProperty.valueComplete, nv, tProperty.modifierParameters); } else { t = (_currentTime - tTweening.timeStart); b = tProperty.valueStart; c = (tProperty.valueComplete - tProperty.valueStart); d = (tTweening.timeComplete - tTweening.timeStart); nv = tTweening.transition(t, b, c, d); }; }; if (tTweening.rounded){ nv = Math.round(nv); }; setPropertyValue(tScope, pName, nv); }; tTweening.updatesSkipped = 0; if (Boolean(tTweening.onUpdate)){ try { tTweening.onUpdate.apply(tScope, tTweening.onUpdateParams); } catch(e:Error) { handleError(tTweening, e, "onUpdate"); }; }; } else { tTweening.updatesSkipped++; }; }; if (((isOver) && (Boolean(tTweening.onComplete)))){ try { tTweening.onComplete.apply(tScope, tTweening.onCompleteParams); } catch(e:Error) { handleError(tTweening, e, "onComplete"); }; }; return (!(isOver)); }; return (true); } public static function setTimeScale(_arg1:Number):void{ var _local2:Number; if (isNaN(_arg1)){ _arg1 = 1; }; if (_arg1 < 1E-5){ _arg1 = 1E-5; }; if (_arg1 != _timeScale){ if (_tweenList != null){ _local2 = 0; while (_local2 < _tweenList.length) { _tweenList[_local2].timeStart = (_currentTime - (((_currentTime - _tweenList[_local2].timeStart) * _timeScale) / _arg1)); _tweenList[_local2].timeComplete = (_currentTime - (((_currentTime - _tweenList[_local2].timeComplete) * _timeScale) / _arg1)); if (_tweenList[_local2].timePaused != undefined){ _tweenList[_local2].timePaused = (_currentTime - (((_currentTime - _tweenList[_local2].timePaused) * _timeScale) / _arg1)); }; _local2++; }; }; _timeScale = _arg1; }; } public static function resumeAllTweens():Boolean{ var _local1:Boolean; var _local2:uint; if (!Boolean(_tweenList)){ return (false); }; _local1 = false; _local2 = 0; while (_local2 < _tweenList.length) { resumeTweenByIndex(_local2); _local1 = true; _local2++; }; return (_local1); } private static function handleError(_arg1:TweenListObj, _arg2:Error, _arg3:String):void{ var pTweening = _arg1; var pError = _arg2; var pCallBackName = _arg3; if (((Boolean(pTweening.onError)) && ((pTweening.onError is Function)))){ try { pTweening.onError.apply(pTweening.scope, [pTweening.scope, pError]); } catch(metaError:Error) { trace("## [Tweener] Error:", pTweening.scope, "raised an error while executing the 'onError' handler. Original error:\n", pError.getStackTrace(), "\nonError error:", metaError.getStackTrace()); }; } else { if (!Boolean(pTweening.onError)){ trace("## [Tweener] Error: :", pTweening.scope, (("raised an error while executing the'" + pCallBackName) + "'handler. \n"), pError.getStackTrace()); }; }; } private static function startEngine():void{ _engineExists = true; _tweenList = new Array(); __tweener_controller__ = new MovieClip(); __tweener_controller__.addEventListener(Event.ENTER_FRAME, Tweener.onEnterFrame); updateTime(); } public static function removeAllTweens():Boolean{ var _local1:Boolean; var _local2:uint; if (!Boolean(_tweenList)){ return (false); }; _local1 = false; _local2 = 0; while (_local2 < _tweenList.length) { removeTweenByIndex(_local2); _local1 = true; _local2++; }; return (_local1); } public static function addTween(_arg1:Object=null, _arg2:Object=null):Boolean{ var _local4:Array; var _local5:Number; var _local6:Number; var _local7:String; var _local8:String; var _local9:Object; var _local10:Number; var _local11:Number; var _local12:Array; var _local13:Object; var _local14:Object; var _local15:Function; var _local16:Object; var _local17:TweenListObj; var _local18:Number; var _local19:Array; var _local20:Array; var _local21:String; if ((((arguments.length < 2)) || ((arguments[0] == undefined)))){ return (false); }; _local4 = new Array(); if ((arguments[0] is Array)){ _local5 = 0; while (_local5 < arguments[0].length) { _local4.push(arguments[0][_local5]); _local5++; }; } else { _local5 = 0; while (_local5 < (arguments.length - 1)) { _local4.push(arguments[_local5]); _local5++; }; }; _local9 = TweenListObj.makePropertiesChain(arguments[(arguments.length - 1)]); if (!_inited){ init(); }; if (((!(_engineExists)) || (!(Boolean(__tweener_controller__))))){ startEngine(); }; _local10 = (isNaN(_local9.time)) ? 0 : _local9.time; _local11 = (isNaN(_local9.delay)) ? 0 : _local9.delay; _local12 = new Array(); _local13 = {time:true, delay:true, useFrames:true, skipUpdates:true, transition:true, onStart:true, onUpdate:true, onComplete:true, onOverwrite:true, rounded:true, onStartParams:true, onUpdateParams:true, onCompleteParams:true, onOverwriteParams:true}; _local14 = new Object(); for (_local7 in _local9) { if (!_local13[_local7]){ if (_specialPropertySplitterList[_local7]){ _local19 = _specialPropertySplitterList[_local7].splitValues(_local9[_local7], _specialPropertySplitterList[_local7].parameters); _local5 = 0; while (_local5 < _local19.length) { _local12[_local19[_local5].name] = {valueStart:undefined, valueComplete:_local19[_local5].value}; _local5++; }; } else { if (_specialPropertyModifierList[_local7] != undefined){ _local20 = _specialPropertyModifierList[_local7].modifyValues(_local9[_local7]); _local5 = 0; while (_local5 < _local20.length) { _local14[_local20[_local5].name] = {modifierParameters:_local20[_local5].parameters, modifierFunction:_specialPropertyModifierList[_local7].getValue}; _local5++; }; } else { _local12[_local7] = {valueStart:undefined, valueComplete:_local9[_local7]}; }; }; }; }; for (_local7 in _local14) { if (_local12[_local7] != undefined){ _local12[_local7].modifierParameters = _local14[_local7].modifierParameters; _local12[_local7].modifierFunction = _local14[_local7].modifierFunction; }; }; if (typeof(_local9.transition) == "string"){ _local21 = _local9.transition.toLowerCase(); _local15 = _transitionList[_local21]; } else { _local15 = _local9.transition; }; if (!Boolean(_local15)){ _local15 = _transitionList["easeoutexpo"]; }; _local5 = 0; while (_local5 < _local4.length) { _local16 = new Object(); for (_local7 in _local12) { _local16[_local7] = new PropertyInfoObj(_local12[_local7].valueStart, _local12[_local7].valueComplete, _local12[_local7].modifierFunction, _local12[_local7].modifierParameters); }; _local17 = new TweenListObj(_local4[_local5], (_currentTime + ((_local11 * 1000) / _timeScale)), (_currentTime + (((_local11 * 1000) + (_local10 * 1000)) / _timeScale)), (_local9.useFrames == true), _local15); _local17.properties = _local16; _local17.onStart = _local9.onStart; _local17.onUpdate = _local9.onUpdate; _local17.onComplete = _local9.onComplete; _local17.onOverwrite = _local9.onOverwrite; _local17.onError = _local9.onError; _local17.onStartParams = _local9.onStartParams; _local17.onUpdateParams = _local9.onUpdateParams; _local17.onCompleteParams = _local9.onCompleteParams; _local17.onOverwriteParams = _local9.onOverwriteParams; _local17.rounded = _local9.rounded; _local17.skipUpdates = _local9.skipUpdates; removeTweensByTime(_local17.scope, _local17.properties, _local17.timeStart, _local17.timeComplete); _tweenList.push(_local17); if ((((_local10 == 0)) && ((_local11 == 0)))){ _local18 = (_tweenList.length - 1); updateTweenByIndex(_local18); removeTweenByIndex(_local18); }; _local5++; }; return (true); } public static function registerTransition(_arg1:String, _arg2:Function):void{ if (!_inited){ init(); }; _transitionList[_arg1] = _arg2; } private static function affectTweens(_arg1:Function, _arg2:Object, _arg3:Array):Boolean{ var _local4:Boolean; var _local5:uint; var _local6:Array; var _local7:uint; var _local8:uint; var _local9:uint; _local4 = false; if (!Boolean(_tweenList)){ return (false); }; _local5 = 0; while (_local5 < _tweenList.length) { if (((_tweenList[_local5]) && ((_tweenList[_local5].scope == _arg2)))){ if (_arg3.length == 0){ _arg1(_local5); _local4 = true; } else { _local6 = new Array(); _local7 = 0; while (_local7 < _arg3.length) { if (Boolean(_tweenList[_local5].properties[_arg3[_local7]])){ _local6.push(_arg3[_local7]); }; _local7++; }; if (_local6.length > 0){ _local8 = AuxFunctions.getObjectLength(_tweenList[_local5].properties); if (_local8 == _local6.length){ _arg1(_local5); _local4 = true; } else { _local9 = splitTweens(_local5, _local6); _arg1(_local9); _local4 = true; }; }; }; }; _local5++; }; return (_local4); } public static function getTweens(_arg1:Object):Array{ var _local2:uint; var _local3:String; var _local4:Array; if (!Boolean(_tweenList)){ return ([]); }; _local4 = new Array(); _local2 = 0; while (_local2 < _tweenList.length) { if (_tweenList[_local2].scope == _arg1){ for (_local3 in _tweenList[_local2].properties) { _local4.push(_local3); }; }; _local2++; }; return (_local4); } private static function setPropertyValue(_arg1:Object, _arg2:String, _arg3:Number):void{ if (_specialPropertyList[_arg2] != undefined){ if (Boolean(_specialPropertyList[_arg2].parameters)){ _specialPropertyList[_arg2].setValue(_arg1, _arg3, _specialPropertyList[_arg2].parameters); } else { _specialPropertyList[_arg2].setValue(_arg1, _arg3); }; } else { _arg1[_arg2] = _arg3; }; } private static function getPropertyValue(_arg1:Object, _arg2:String):Number{ if (_specialPropertyList[_arg2] != undefined){ if (Boolean(_specialPropertyList[_arg2].parameters)){ return (_specialPropertyList[_arg2].getValue(_arg1, _specialPropertyList[_arg2].parameters)); }; return (_specialPropertyList[_arg2].getValue(_arg1)); } else { }; return (!NULL!); } public static function isTweening(_arg1:Object):Boolean{ var _local2:uint; if (!Boolean(_tweenList)){ return (false); }; _local2 = 0; while (_local2 < _tweenList.length) { if (_tweenList[_local2].scope == _arg1){ return (true); }; _local2++; }; return (false); } public static function getTweenCount(_arg1:Object):Number{ var _local2:uint; var _local3:Number; if (!Boolean(_tweenList)){ return (0); }; _local3 = 0; _local2 = 0; while (_local2 < _tweenList.length) { if (_tweenList[_local2].scope == _arg1){ _local3 = (_local3 + AuxFunctions.getObjectLength(_tweenList[_local2].properties)); }; _local2++; }; return (_local3); } private static function stopEngine():void{ _engineExists = false; _tweenList = null; _currentTime = 0; __tweener_controller__.removeEventListener(Event.ENTER_FRAME, Tweener.onEnterFrame); __tweener_controller__ = null; } public static function pauseTweenByIndex(_arg1:Number):Boolean{ var _local2:TweenListObj; _local2 = _tweenList[_arg1]; if ((((_local2 == null)) || (_local2.isPaused))){ return (false); }; _local2.timePaused = _currentTime; _local2.isPaused = true; return (true); } public static function removeTweensByTime(_arg1:Object, _arg2:Object, _arg3:Number, _arg4:Number):Boolean{ var removed:Boolean; var removedLocally:Boolean; var i:uint; var tl:uint; var pName:String; var p_scope = _arg1; var p_properties = _arg2; var p_timeStart = _arg3; var p_timeComplete = _arg4; removed = false; tl = _tweenList.length; i = 0; while (i < tl) { if (((Boolean(_tweenList[i])) && ((p_scope == _tweenList[i].scope)))){ if ((((p_timeComplete > _tweenList[i].timeStart)) && ((p_timeStart < _tweenList[i].timeComplete)))){ removedLocally = false; for (pName in _tweenList[i].properties) { if (Boolean(p_properties[pName])){ if (Boolean(_tweenList[i].onOverwrite)){ try { _tweenList[i].onOverwrite.apply(_tweenList[i].scope, _tweenList[i].onOverwriteParams); } catch(e:Error) { handleError(_tweenList[i], e, "onOverwrite"); }; }; _tweenList[i].properties[pName] = undefined; delete _tweenList[i].properties[pName]; removedLocally = true; removed = true; }; }; if (removedLocally){ if (AuxFunctions.getObjectLength(_tweenList[i].properties) == 0){ removeTweenByIndex(i); }; }; }; }; i = (i + 1); }; return (removed); } public static function registerSpecialPropertySplitter(_arg1:String, _arg2:Function, _arg3:Array=null):void{ var _local4:SpecialPropertySplitter; if (!_inited){ init(); }; _local4 = new SpecialPropertySplitter(_arg2, _arg3); _specialPropertySplitterList[_arg1] = _local4; } public static function removeTweenByIndex(_arg1:Number, _arg2:Boolean=false):Boolean{ _tweenList[_arg1] = null; if (_arg2){ _tweenList.splice(_arg1, 1); }; return (true); } public static function resumeTweens(_arg1:Object, ... _args):Boolean{ var _local3:Array; var _local4:uint; _local3 = new Array(); _local4 = 0; while (_local4 < _args.length) { if ((((typeof(_args[_local4]) == "string")) && (!(AuxFunctions.isInArray(_args[_local4], _local3))))){ _local3.push(_args[_local4]); }; _local4++; }; return (affectTweens(resumeTweenByIndex, _arg1, _local3)); } public static function pauseTweens(_arg1:Object, ... _args):Boolean{ var _local3:Array; var _local4:uint; _local3 = new Array(); _local4 = 0; while (_local4 < _args.length) { if ((((typeof(_args[_local4]) == "string")) && (!(AuxFunctions.isInArray(_args[_local4], _local3))))){ _local3.push(_args[_local4]); }; _local4++; }; return (affectTweens(pauseTweenByIndex, _arg1, _local3)); } } }//package caurina.transitions
Section 9
//TweenListObj (caurina.transitions.TweenListObj) package caurina.transitions { public class TweenListObj { public var onUpdate:Function; public var useFrames:Boolean; public var hasStarted:Boolean; public var onOverwriteParams:Array; public var timeStart:Number; public var count:Number; public var auxProperties:Object; public var timeComplete:Number; public var onStartParams:Array; public var rounded:Boolean; public var properties:Object; public var onUpdateParams:Array; public var onComplete:Function; public var updatesSkipped:Number; public var onStart:Function; public var skipUpdates:Number; public var scope:Object; public var isCaller:Boolean; public var timePaused:Number; public var transition:Function; public var onCompleteParams:Array; public var onError:Function; public var timesCalled:Number; public var onOverwrite:Function; public var isPaused:Boolean; public var waitFrames:Boolean; public function TweenListObj(_arg1:Object, _arg2:Number, _arg3:Number, _arg4:Boolean, _arg5:Function){ scope = _arg1; timeStart = _arg2; timeComplete = _arg3; useFrames = _arg4; transition = _arg5; auxProperties = new Object(); properties = new Object(); isPaused = false; timePaused = undefined; isCaller = false; updatesSkipped = 0; timesCalled = 0; skipUpdates = 0; hasStarted = false; } public function clone(_arg1:Boolean):TweenListObj{ var _local2:TweenListObj; var _local3:String; _local2 = new TweenListObj(scope, timeStart, timeComplete, useFrames, transition); _local2.properties = new Array(); for (_local3 in properties) { _local2.properties[_local3] = properties[_local3].clone(); }; _local2.skipUpdates = skipUpdates; _local2.updatesSkipped = updatesSkipped; if (!_arg1){ _local2.onStart = onStart; _local2.onUpdate = onUpdate; _local2.onComplete = onComplete; _local2.onOverwrite = onOverwrite; _local2.onError = onError; _local2.onStartParams = onStartParams; _local2.onUpdateParams = onUpdateParams; _local2.onCompleteParams = onCompleteParams; _local2.onOverwriteParams = onOverwriteParams; }; _local2.rounded = rounded; _local2.isPaused = isPaused; _local2.timePaused = timePaused; _local2.isCaller = isCaller; _local2.count = count; _local2.timesCalled = timesCalled; _local2.waitFrames = waitFrames; _local2.hasStarted = hasStarted; return (_local2); } public function toString():String{ var _local1:String; var _local2:uint; _local1 = "\n[TweenListObj "; _local1 = (_local1 + ("scope:" + String(scope))); _local1 = (_local1 + ", properties:"); _local2 = 0; while (_local2 < properties.length) { if (_local2 > 0){ _local1 = (_local1 + ","); }; _local1 = (_local1 + ("[name:" + properties[_local2].name)); _local1 = (_local1 + (",valueStart:" + properties[_local2].valueStart)); _local1 = (_local1 + (",valueComplete:" + properties[_local2].valueComplete)); _local1 = (_local1 + "]"); _local2++; }; _local1 = (_local1 + (", timeStart:" + String(timeStart))); _local1 = (_local1 + (", timeComplete:" + String(timeComplete))); _local1 = (_local1 + (", useFrames:" + String(useFrames))); _local1 = (_local1 + (", transition:" + String(transition))); if (skipUpdates){ _local1 = (_local1 + (", skipUpdates:" + String(skipUpdates))); }; if (updatesSkipped){ _local1 = (_local1 + (", updatesSkipped:" + String(updatesSkipped))); }; if (Boolean(onStart)){ _local1 = (_local1 + (", onStart:" + String(onStart))); }; if (Boolean(onUpdate)){ _local1 = (_local1 + (", onUpdate:" + String(onUpdate))); }; if (Boolean(onComplete)){ _local1 = (_local1 + (", onComplete:" + String(onComplete))); }; if (Boolean(onOverwrite)){ _local1 = (_local1 + (", onOverwrite:" + String(onOverwrite))); }; if (Boolean(onError)){ _local1 = (_local1 + (", onError:" + String(onError))); }; if (onStartParams){ _local1 = (_local1 + (", onStartParams:" + String(onStartParams))); }; if (onUpdateParams){ _local1 = (_local1 + (", onUpdateParams:" + String(onUpdateParams))); }; if (onCompleteParams){ _local1 = (_local1 + (", onCompleteParams:" + String(onCompleteParams))); }; if (onOverwriteParams){ _local1 = (_local1 + (", onOverwriteParams:" + String(onOverwriteParams))); }; if (rounded){ _local1 = (_local1 + (", rounded:" + String(rounded))); }; if (isPaused){ _local1 = (_local1 + (", isPaused:" + String(isPaused))); }; if (timePaused){ _local1 = (_local1 + (", timePaused:" + String(timePaused))); }; if (isCaller){ _local1 = (_local1 + (", isCaller:" + String(isCaller))); }; if (count){ _local1 = (_local1 + (", count:" + String(count))); }; if (timesCalled){ _local1 = (_local1 + (", timesCalled:" + String(timesCalled))); }; if (waitFrames){ _local1 = (_local1 + (", waitFrames:" + String(waitFrames))); }; if (hasStarted){ _local1 = (_local1 + (", hasStarted:" + String(hasStarted))); }; _local1 = (_local1 + "]\n"); return (_local1); } public static function makePropertiesChain(_arg1:Object):Object{ var _local2:Object; var _local3:Object; var _local4:Object; var _local5:Object; var _local6:Number; var _local7:Number; var _local8:Number; _local2 = _arg1.base; if (_local2){ _local3 = {}; if ((_local2 is Array)){ _local4 = []; _local8 = 0; while (_local8 < _local2.length) { _local4.push(_local2[_local8]); _local8++; }; } else { _local4 = [_local2]; }; _local4.push(_arg1); _local6 = _local4.length; _local7 = 0; while (_local7 < _local6) { if (_local4[_local7]["base"]){ _local5 = AuxFunctions.concatObjects(makePropertiesChain(_local4[_local7]["base"]), _local4[_local7]); } else { _local5 = _local4[_local7]; }; _local3 = AuxFunctions.concatObjects(_local3, _local5); _local7++; }; if (_local3["base"]){ delete _local3["base"]; }; return (_local3); //unresolved jump }; return (_arg1); } } }//package caurina.transitions
Section 10
//StringUtil (com.adobe.utils.StringUtil) package com.adobe.utils { public class StringUtil { public static function beginsWith(_arg1:String, _arg2:String):Boolean{ return ((_arg2 == _arg1.substring(0, _arg2.length))); } public static function trim(_arg1:String):String{ return (StringUtil.ltrim(StringUtil.rtrim(_arg1))); } public static function stringsAreEqual(_arg1:String, _arg2:String, _arg3:Boolean):Boolean{ if (_arg3){ return ((_arg1 == _arg2)); }; return ((_arg1.toUpperCase() == _arg2.toUpperCase())); } public static function replace(_arg1:String, _arg2:String, _arg3:String):String{ var _local4:String; var _local5:Boolean; var _local6:Number; var _local7:Number; var _local8:Number; var _local9:Number; _local4 = new String(); _local5 = false; _local6 = _arg1.length; _local7 = _arg2.length; _local8 = 0; while (_local8 < _local6) { if (_arg1.charAt(_local8) == _arg2.charAt(0)){ _local5 = true; _local9 = 0; while (_local9 < _local7) { if (_arg1.charAt((_local8 + _local9)) != _arg2.charAt(_local9)){ _local5 = false; break; }; _local9++; }; //unresolved if _local4 = (_local4 + _arg3); _local8 = (_local8 + (_local7 - 1)); } else { _local4 = (_local4 + _arg1.charAt(_local8)); }; _local8++; }; return (_local4); } public static function rtrim(_arg1:String):String{ var _local2:Number; var _local3:Number; _local2 = _arg1.length; _local3 = _local2; while (_local3 > 0) { if (_arg1.charCodeAt((_local3 - 1)) > 32){ return (_arg1.substring(0, _local3)); }; _local3--; }; return (""); } public static function endsWith(_arg1:String, _arg2:String):Boolean{ return ((_arg2 == _arg1.substring((_arg1.length - _arg2.length)))); } public static function stringHasValue(_arg1:String):Boolean{ return (((!((_arg1 == null))) && ((_arg1.length > 0)))); } public static function remove(_arg1:String, _arg2:String):String{ return (StringUtil.replace(_arg1, _arg2, "")); } public static function ltrim(_arg1:String):String{ var _local2:Number; var _local3:Number; _local2 = _arg1.length; _local3 = 0; while (_local3 < _local2) { if (_arg1.charCodeAt(_local3) > 32){ return (_arg1.substring(_local3)); }; _local3++; }; return (""); } } }//package com.adobe.utils
Section 11
//ImageContainer (ImageContainer) package { import flash.events.*; import flash.display.*; import flash.net.*; public class ImageContainer extends MovieClip { public var imageLink:String; public var description:String; public var imageURL:String; public var imageLoader:Loader; public var pictureID:String; public var pictureNum:Number; public var numTrys:Number;// = 0 public function ImageContainer(){ numTrys = 0; super(); imageLoader = new Loader(); addChild(imageLoader); imageLoader.contentLoaderInfo.addEventListener(Event.INIT, dispatchImageLoaded); } public function resizeImage(_arg1:Number, _arg2:Number, _arg3:Number=0, _arg4:Number=0){ var loader:Loader; var img:Bitmap; var w:Number; var h:Number; var diff:Number; var percent:Number; var sw = _arg1; var sh = _arg2; var posX = _arg3; var posY = _arg4; loader = imageLoader; img = (loader.content as Bitmap); try { img.smoothing = true; } catch(errObject:Error) { }; loader.scaleX = 1; loader.scaleY = 1; w = width; h = height; if (sw < w){ diff = (w - sw); percent = (1 - (diff / w)); w = (w * percent); h = (h * percent); }; if (sh < h){ diff = (h - sh); percent = (1 - (diff / h)); w = (w * percent); h = (h * percent); }; if (h < loader.height){ diff = (loader.height - h); percent = (1 - (diff / loader.height)); loader.scaleX = percent; loader.scaleY = percent; }; x = ((posX + (sw / 2)) - (width / 2)); y = ((posY + (sh / 2)) - (height / 2)); trace(("resize percent=" + percent)); } public function loadImage(_arg1:String, _arg2:Number, _arg3:String="", _arg4:String=""){ this.imageURL = _arg1; imageLoader.load(new URLRequest(_arg1)); this.pictureNum = _arg2; this.imageLink = _arg3; this.description = _arg4; numTrys = 0; trace(((("Load Image try " + numTrys) + ":") + _arg1)); trace(""); } private function dispatchImageLoaded(_arg1:Event):void{ dispatchEvent(new Event("imageLoaded")); } private function ioErrorHandler(_arg1:IOErrorEvent):void{ if (numTrys <= 5){ imageLoader.load(new URLRequest(imageURL)); }; numTrys++; trace("trying to load picture again"); trace(("ioErrorHandler: " + _arg1)); } public function cleanUp(){ imageLoader.contentLoaderInfo.removeEventListener(IOErrorEvent.IO_ERROR, ioErrorHandler); imageLoader.contentLoaderInfo.removeEventListener(Event.INIT, dispatchImageLoaded); } } }//package
Section 12
//Picasa (Picasa) package { import flash.events.*; import caurina.transitions.*; import flash.display.*; import com.adobe.utils.*; import flash.text.*; import flash.utils.*; import flash.net.*; import flash.geom.*; import flash.system.*; import flash.external.*; import flash.ui.*; public class Picasa extends MovieClip { private var slideShowPlaying:Boolean; private var currentPictureNum:Number;// = 0 private var mcThumbContainers:MovieClip; private var leftArrowButton:MovieClip; private var fullScreenMode:Boolean; private var thumbCPSmallWidth:Number; private var userID:String;// = "" private var activeContainer:ImageContainer; private var thumbFSButton:MovieClip; private var thumbCPSmallHeight:Number; private var fsButton:MovieClip; private var numLoaders:Number;// = 3 private var cpSmallHeight:Number; private var txt:TextField; private var lastPictureNumLoaded:Number; private var cpFullWidth:Number; private var mcThumbPage:MovieClip; private var thumbCPBigWidth:Number; private var controlPanelActive:Boolean; private var mcFullSizePage:MovieClip; private var thumbHeight:Number;// = 72 private var controlPanel:MovieClip; private var thumbButton:MovieClip; private var txtTags:TextField; private var mouseIn:Boolean; private var showThumbs:Boolean;// = true private var osImageLoaded:Boolean; private var thumbCPBigHeight:Number; private var thumbCP:MovieClip; private var isRSS:Boolean; private var backgroundColor:Number;// = 0xFFFFFF private var numPictures:Number;// = 0 private var lastPictureNum:Number;// = 0 private var rightArrowButton:MovieClip; private var cpFullHeight:Number; private var imageLoaders:Array; private var reverse:Boolean; private var thumbXMLIndex:Number;// = 0 private var myTimer:Timer; private var feedURL:String;// = "" private var searchButton:MovieClip; private var xmlResult:XML; private var thumbMargin:Number; private var background:Sprite; private var thumbsPerPage:Number; private var searchPanel:MovieClip; private var savedImageLink:String; private var thumbsPerRow:Number; private var cpSmallWidth:Number; private var ppButton:MovieClip; private var slideShowTimerEnded:Boolean; private var txtUsername:TextField; private var activeContainerNum:Number;// = 0 private var firstThumbIndex:Number;// = 0 private var delay:uint;// = 2000 private var slideShowTimer:Timer; private var thumbWidth:Number;// = 72 private var buttonInactiveAlpha:Number;// = 0.85 private var startIndex:Number;// = 0 private var thumbCPActive:Boolean; private var tag:String; private var rssURL:String;// = "" private var txtRSS:TextField; private var firstLoad:Boolean;// = true private var imageContainers:Array; private var reqLink:URLRequest; private var slideShowDelay:Number;// = 5000 private var maxResults:Number;// = 30 private namespace atom = "http://www.w3.org/2005/Atom"; private namespace media = "http://search.yahoo.com/mrss/"; private namespace openSearch = "http://a9.com/-/spec/opensearchrss/1.0/"; private namespace gphoto = "http://schemas.google.com/photos/2007"; public function Picasa(){ delay = 2000; numPictures = 0; currentPictureNum = 0; userID = ""; backgroundColor = 0xFFFFFF; rssURL = ""; numLoaders = 3; slideShowDelay = 5000; buttonInactiveAlpha = 0.85; thumbWidth = 72; thumbHeight = 72; thumbXMLIndex = 0; firstThumbIndex = 0; feedURL = ""; startIndex = 0; maxResults = 30; showThumbs = true; activeContainerNum = 0; firstLoad = true; lastPictureNum = 0; super(); Security.loadPolicyFile("http://lh3.ggpht.com/crossdomain.xml"); Security.loadPolicyFile("http://lh4.ggpht.com/crossdomain.xml"); Security.loadPolicyFile("http://lh5.ggpht.com/crossdomain.xml"); Security.loadPolicyFile("http://lh6.ggpht.com/crossdomain.xml"); Security.loadPolicyFile("http://photos.googleapis.com/data/crossdomain.xml"); addEventListener(Event.ENTER_FRAME, getStageDimensions); } function fadeInControlPanel(_arg1:Event){ var _local2:MovieClip; _local2 = MovieClip(_arg1.target); _local2.alpha = (_local2.alpha + 0.1); if (_local2.alpha >= 1){ _local2.removeEventListener(Event.ENTER_FRAME, fadeInControlPanel); }; } function startFadeInControlPanel(_arg1:Event){ myTimer.reset(); myTimer.start(); if (!controlPanelActive){ controlPanel.addEventListener(Event.ENTER_FRAME, fadeInControlPanel); controlPanel.removeEventListener(Event.ENTER_FRAME, fadeOutControlPanel); controlPanelActive = true; }; if (!thumbCPActive){ thumbCP.addEventListener(Event.ENTER_FRAME, fadeInControlPanel); thumbCP.removeEventListener(Event.ENTER_FRAME, fadeOutControlPanel); thumbCPActive = true; }; } function createThumbButton(_arg1:Number, _arg2:Number):MovieClip{ var _local3:Number; var _local4:Number; var _local5:Number; var _local6:Graphics; var _local7:MovieClip; var _local8:Sprite; var _local9:Number; var _local10:Number; var _local11:Number; var _local12:Number; var _local13:Number; _local3 = 8; _local4 = 30; _local5 = 30; _local7 = new MovieClip(); _local7.buttonMode = true; _local6 = _local7.graphics; _local6.lineStyle(2, _arg1, 1, true); _local6.beginFill(_arg2); _local6.drawRoundRect(0, 0, _local4, _local5, _local3, _local3); _local6.endFill(); _local8 = new Sprite(); _local6 = _local8.graphics; _local9 = 3; _local10 = 3; _local11 = ((_local4 - (_local10 * (_local9 + 1))) / _local9); _local12 = 0; while (_local12 < 3) { _local13 = 0; while (_local13 < _local9) { _local6.lineStyle(1, 0xFFFFFF); _local6.drawRect((_local10 + (_local12 * (_local11 + _local10))), (_local10 + (_local13 * (_local11 + _local10))), _local11, _local11); _local13++; }; _local12++; }; _local7.addChild(_local8); return (_local7); } private function doSearch(_arg1:Object){ var _local2:String; var _local3:String; _local2 = ""; _local3 = ""; userID = ""; rssURL = ""; tag = ""; isRSS = false; if (_arg1.startIndex != undefined){ startIndex = _arg1.startIndex; if (startIndex == 0){ firstThumbIndex = 0; currentPictureNum = 0; }; }; if (_arg1.userID != undefined){ userID = StringUtil.trim(_arg1.userID); if (_arg1 != ""){ userID = _arg1.userID; }; trace(("userID=" + userID)); }; if (_arg1.rssURL != undefined){ rssURL = StringUtil.trim(_arg1.rssURL); if (rssURL != ""){ rssURL = StringUtil.replace(rssURL, "picasaweb.google.com", "photos.googleapis.com"); isRSS = true; }; trace(("rssURL=" + rssURL)); }; if (rssURL != ""){ _local3 = rssURL; } else { if (userID != ""){ _local3 = (("http://photos.googleapis.com/data/feed/api/user/" + userID) + "?kind=photo"); }; }; if (_arg1.tag != undefined){ tag = StringUtil.trim(_arg1.tag); if (tag != ""){ if (_local3 != ""){ _local3 = (_local3 + ("&tag=" + tag)); } else { _local3 = ("http://photos.googleapis.com/data/feed/api/all?kind=photo&tag=" + tag); }; }; }; feedURL = _local3; _local2 = getPrefJS("lastFeedURL"); if (((!((_local2 == _local3))) || ((_local2 == "")))){ startIndex = 0; firstThumbIndex = 0; currentPictureNum = 0; setPrefJS("lastFeedURL", _local3); }; if (feedURL != ""){ loadXML(feedURL, displayResult); hideSearchForm(null); } else { showSearchForm(null); }; txtUsername.text = userID; txtRSS.text = rssURL; txtTags.text = tag; setPrefJS("userID", userID); setPrefJS("rssURL", rssURL); setPrefJS("tag", tag); } function createSearchButton(_arg1:Number, _arg2:Number):MovieClip{ var _local3:Number; var _local4:Number; var _local5:Number; var _local6:Graphics; var _local7:MovieClip; var _local8:Sprite; _local3 = 8; _local4 = 30; _local5 = 30; _local7 = new MovieClip(); _local7.buttonMode = true; _local6 = _local7.graphics; _local6.lineStyle(2, _arg1, 1, true); _local6.beginFill(_arg2); _local6.drawRoundRect(0, 0, _local4, _local5, _local3, _local3); _local6.endFill(); _local8 = new Sprite(); _local6 = _local8.graphics; _local6.lineStyle(3, 0xFFFFFF, 1); _local6.drawCircle((_local4 * 0.6), (_local5 * 0.38), (_local4 * 0.2)); _local6.lineStyle(4, 0xFFFFFF, 1); _local6.moveTo((_local4 * 0.42), (_local5 * 0.57)); _local6.lineTo((_local4 * 0.2), (_local5 * 0.8)); _local7.addChild(_local8); return (_local7); } private function loadThumbPagePrev(_arg1:Event=null){ var _local2:Number; _local2 = (firstThumbIndex - thumbsPerPage); _local2 = (int((_local2 / thumbsPerPage)) * thumbsPerPage); if (_local2 >= 0){ setPrefJS("pictureNum", ("" + currentPictureNum)); currentPictureNum = _local2; if (firstThumbIndex < startIndex){ loadXMLPrev(); } else { loadThumbPage(); }; }; } function toggleFullscreen(_arg1:Event){ if (fullScreenMode){ stage.displayState = StageDisplayState.NORMAL; } else { if (!mcThumbPage.visible){ activeContainer.visible = false; }; stage.displayState = StageDisplayState.FULL_SCREEN; }; } private function centerOnStage(_arg1:MovieClip){ _arg1.x = ((stage.stageWidth / 2) - (_arg1.width / 2)); _arg1.y = ((stage.stageHeight / 2) - (_arg1.height / 2)); } function createPlayPauseButton(_arg1:Number, _arg2:Number):MovieClip{ var curve:Number; var w:Number; var h:Number; var arrowH:Number; var arrowW:Number; var arrowColor:Number; var g:Graphics; var ppButton:MovieClip; var playSp:Sprite; var pauseW:Number; var pauseH:Number; var pauseSp:Sprite; var buttonLineColor = _arg1; var buttonFillColor = _arg2; curve = 8; w = 30; h = 30; arrowH = (h * 0.55); arrowW = (w * 0.35); arrowColor = 0xFFFFFF; ppButton = new MovieClip(); ppButton.buttonMode = true; g = ppButton.graphics; g.lineStyle(2, buttonLineColor, 1, true); g.beginFill(buttonFillColor); g.drawRoundRect(0, 0, w, h, curve, curve); g.endFill(); playSp = new Sprite(); g = playSp.graphics; g.lineStyle(2, arrowColor); g.beginFill(arrowColor); g.lineTo(arrowW, (arrowH / 2)); g.lineTo(0, arrowH); g.lineTo(0, 0); g.endFill(); playSp.y = ((h / 2) - (arrowH / 2)); playSp.x = ((ppButton.width / 2) - (playSp.width * 0.3)); ppButton.addChild(playSp); pauseW = 8; pauseH = 12; pauseSp = new Sprite(); g = pauseSp.graphics; g.lineStyle(4, arrowColor, 1, false, "normal", "square"); g.lineTo(0, pauseH); g.moveTo(pauseW, 0); g.lineTo(pauseW, pauseH); pauseSp.y = ((h / 2) - (pauseH * 0.5)); pauseSp.x = ((ppButton.width / 2) - (pauseW * 0.5)); ppButton.addChild(pauseSp); ppButton.showPause = function (){ pauseSp.visible = true; playSp.visible = false; }; ppButton.showPlay = function (){ pauseSp.visible = false; playSp.visible = true; }; ppButton.showPlay(); return (ppButton); } private function progressHandler(_arg1:ProgressEvent):void{ } function stopSlideShow(){ slideShowPlaying = false; ppButton.showPlay(); slideShowTimer.stop(); } private function showImage(){ var _local1:Number; _local1 = activeContainerNum; activeContainerNum = (activeContainerNum + 1); if (activeContainerNum >= numLoaders){ activeContainerNum = 0; }; activeContainer = imageContainers[activeContainerNum]; doFadeTrans(imageContainers[_local1], activeContainer); } function incrementPictureNum(){ currentPictureNum++; if (currentPictureNum >= numPictures){ currentPictureNum = 0; }; } private function centerOnStagePositive(_arg1:MovieClip){ _arg1.x = Math.max(((stage.stageWidth / 2) - (_arg1.width / 2)), 0); _arg1.y = Math.max(((stage.stageHeight / 2) - (_arg1.height / 2)), 0); } function initContextMenu(){ var _local1:ContextMenu; var _local2:ContextMenuItem; var _local3:ContextMenuItem; _local1 = new ContextMenu(); _local1.addEventListener(ContextMenuEvent.MENU_SELECT, menuHandler); _local2 = new ContextMenuItem("Go Full Screen"); _local2.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, goFullScreen); _local1.customItems.push(_local2); _local3 = new ContextMenuItem("Exit Full Screen"); _local3.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, exitFullScreen); _local1.customItems.push(_local3); contextMenu = _local1; } function loadPrevPicture(_arg1:Event){ var _local2:Number; reverse = true; _local2 = currentPictureNum; currentPictureNum--; if (slideShowPlaying){ togglePausePlay(null); }; if (currentPictureNum < 0){ currentPictureNum = lastPictureNum; }; if (_local2 != currentPictureNum){ setPrefJS("pictureNum", ("" + currentPictureNum)); loadOffScreenContainer(currentPictureNum); }; } public function displayResult2(_arg1:Event){ var _local2:URLLoader; var _local3:XML; var _local4:Number; _local2 = URLLoader(_arg1.target); _local3 = new XML(_local2.data); _local4 = numPictures; if (isRSS){ numPictures = _local3.channel.item.length(); } else { numPictures = _local3.entry.length(); }; if (numPictures > 0){ xmlResult = _local3; numPictures = (numPictures + startIndex); if (_local4 < numPictures){ if (showThumbs){ createThumbs(); } else { if (slideShowPlaying){ loadOffScreenContainer((currentPictureNum + 1)); } else { loadOffScreenContainer(currentPictureNum); }; setPrefJS("pictureNum", ("" + currentPictureNum)); }; } else { if (showThumbs){ if ((firstThumbIndex % thumbsPerPage) == 0){ firstThumbIndex = (firstThumbIndex - thumbsPerPage); }; firstThumbIndex = (int((firstThumbIndex / thumbsPerPage)) * thumbsPerPage); } else { lastPictureNum = (currentPictureNum - 1); if (slideShowPlaying){ currentPictureNum = -1; } else { currentPictureNum = 0; }; firstThumbIndex = 0; startIndex = 0; numPictures = 0; loadXML(feedURL, displayResult); }; startIndex = firstThumbIndex; }; } else { numPictures = _local4; if (showThumbs){ if ((firstThumbIndex % thumbsPerPage) == 0){ firstThumbIndex = (firstThumbIndex - thumbsPerPage); }; firstThumbIndex = (int((firstThumbIndex / thumbsPerPage)) * thumbsPerPage); } else { currentPictureNum--; firstThumbIndex = (int((currentPictureNum / thumbsPerPage)) * thumbsPerPage); }; startIndex = firstThumbIndex; }; setPrefJS("startIndex", ("" + startIndex)); } function decrementPictureNum(){ currentPictureNum--; if (currentPictureNum < 0){ currentPictureNum = (numPictures - 1); }; } private function resizeIfBiggerThanStage(_arg1:MovieClip){ var _local2:Number; var _local3:Number; var _local4:Number; var _local5:Number; _arg1.scaleX = 1; _arg1.scaleY = 1; _local2 = _arg1.width; _local3 = _arg1.height; if (stage.stageWidth < _local2){ _local4 = (_local2 - stage.stageWidth); _local5 = (1 - (_local4 / _local2)); _local2 = (_local2 * _local5); _local3 = (_local3 * _local5); }; if (stage.stageHeight < _local3){ _local4 = (_local3 - stage.stageHeight); _local5 = (1 - (_local4 / _local3)); _local2 = (_local2 * _local5); _local3 = (_local3 * _local5); }; if (_local3 < _arg1.height){ _local4 = (_arg1.height - _local3); _local5 = (1 - (_local4 / _arg1.height)); _arg1.scaleX = _local5; _arg1.scaleY = _local5; }; _arg1.x = ((stage.stageWidth / 2) - (_arg1.width / 2)); _arg1.y = ((stage.stageHeight / 2) - (_arg1.height / 2)); } private function cancelSearch(_arg1:Event){ hideSearchForm(_arg1); txtUsername.text = userID; txtRSS.text = rssURL; txtTags.text = tag; } private function loadThumbPageNext(_arg1:Event){ var _local2:Number; _local2 = (firstThumbIndex + thumbsPerPage); if (firstThumbIndex < numPictures){ _local2 = (int((_local2 / thumbsPerPage)) * thumbsPerPage); currentPictureNum = _local2; setPrefJS("pictureNum", ("" + currentPictureNum)); loadThumbPage(); }; } function goScaledFullScreen(){ var _local1:Rectangle; _local1 = new Rectangle(0, 0, (stage.stageWidth / 2), (stage.stageHeight / 2)); stage.fullScreenSourceRect = _local1; stage.displayState = StageDisplayState.FULL_SCREEN; } function goFullScreen(_arg1:ContextMenuEvent):void{ stage.displayState = StageDisplayState.FULL_SCREEN; } function startFadeInButton(_arg1:MouseEvent){ _arg1.currentTarget.addEventListener(Event.ENTER_FRAME, fadeInButton); _arg1.currentTarget.removeEventListener(Event.ENTER_FRAME, fadeOutButton); } function fadeOutButton(_arg1:Event){ if (_arg1.currentTarget.alpha > buttonInactiveAlpha){ _arg1.currentTarget.alpha = (_arg1.currentTarget.alpha - 0.1); } else { _arg1.currentTarget.removeEventListener(Event.ENTER_FRAME, fadeOutButton); }; } private function showThumbPage(_arg1:Event=null){ mcThumbPage.visible = true; mcFullSizePage.visible = false; } public function init(){ var showUserID:Boolean; var showRSS:Boolean; var strNum:String; var paramObj:Object; var arrowButtonW:Number; var arrowButtonH:Number; var arrowH:Number; var arrowW:Number; var arrowColor:Number; var buttonLineColor:Number; var buttonFillColor:Number; var spaceBetweenArrows:Number; var i:Number; var txtFormat2:TextFormat; var searchLabels:MovieClip; var searchTextBoxes:MovieClip; var searchBG:Shape; var txtY:Number; var txtTagsLabel:TextField; var mcSearchButton:MovieClip; var g:Graphics; var txtFormat:TextFormat; var txtSearchLabel:TextField; var mcCancelButton:MovieClip; var txtCancelLabel:TextField; var margin:Number; var txtUsernameLabel:TextField; var txtRSSLabel:TextField; stage.scaleMode = StageScaleMode.NO_SCALE; stage.align = StageAlign.TOP_LEFT; strNum = getPrefJS("pictureNum"); if (strNum != ""){ currentPictureNum = int(strNum); }; paramObj = root.loaderInfo.parameters; if (paramObj.up_showThumbs == "false"){ showThumbs = false; }; if (paramObj.up_slideShowDelay != undefined){ slideShowDelay = (parseInt(paramObj.up_slideShowDelay) * 1000); }; if (paramObj.up_startIndex != undefined){ startIndex = parseInt(paramObj.up_startIndex); if (startIndex < 0){ startIndex = 0; }; }; if (paramObj.up_imageLink != undefined){ savedImageLink = paramObj.up_imageLink; }; if (paramObj.up_backgroundColor != undefined){ backgroundColor = parseInt(("0x" + paramObj.up_backgroundColor)); }; userID = userID.toLocaleLowerCase(); background = new Sprite(); addChild(background); mcThumbPage = new MovieClip(); mcThumbContainers = new MovieClip(); mcThumbPage.addChild(mcThumbContainers); addChild(mcThumbPage); myTimer = new Timer(delay, 1); myTimer.addEventListener(TimerEvent.TIMER_COMPLETE, startFadeOutControlPanel); slideShowTimer = new Timer(slideShowDelay, 1); slideShowTimer.addEventListener(TimerEvent.TIMER_COMPLETE, slideShowNextPicture); slideShowTimer.stop(); arrowButtonW = 30; arrowButtonH = 30; arrowH = (arrowButtonH * 0.6); arrowW = (arrowButtonW * 0.3); arrowColor = 0xFFFFFF; buttonLineColor = 0xCCCCCC; buttonFillColor = 2577272; spaceBetweenArrows = 3; thumbCP = new MovieClip(); leftArrowButton = createArrowButton(buttonLineColor, buttonFillColor); rightArrowButton = createArrowButton(buttonLineColor, buttonFillColor); rightArrowButton.flip(); thumbFSButton = createFsButton(buttonLineColor, buttonFillColor); searchButton = createSearchButton(buttonLineColor, buttonFillColor); thumbButton = createThumbButton(buttonLineColor, buttonFillColor); rightArrowButton.x = ((leftArrowButton.x + leftArrowButton.width) + spaceBetweenArrows); thumbFSButton.x = ((rightArrowButton.x + rightArrowButton.width) + spaceBetweenArrows); searchButton.x = ((thumbFSButton.x + thumbFSButton.width) + spaceBetweenArrows); thumbCP.addChild(leftArrowButton); thumbCP.addChild(rightArrowButton); thumbCP.addChild(thumbFSButton); thumbCP.addChild(searchButton); thumbCP.alpha = 0; leftArrowButton.addEventListener(MouseEvent.MOUSE_UP, loadThumbPagePrev); rightArrowButton.addEventListener(MouseEvent.MOUSE_UP, loadThumbPageNext); searchButton.addEventListener(MouseEvent.MOUSE_UP, showSearchForm); thumbFSButton.addEventListener(MouseEvent.MOUSE_UP, toggleFullscreen); mcThumbPage.addChild(thumbCP); controlPanel = new MovieClip(); leftArrowButton = createArrowButton(buttonLineColor, buttonFillColor); rightArrowButton = createArrowButton(buttonLineColor, buttonFillColor); rightArrowButton.flip(); fsButton = createFsButton(buttonLineColor, buttonFillColor); ppButton = createPlayPauseButton(buttonLineColor, buttonFillColor); searchButton = createSearchButton(buttonLineColor, buttonFillColor); rightArrowButton.x = ((leftArrowButton.x + leftArrowButton.width) + spaceBetweenArrows); fsButton.x = ((rightArrowButton.x + rightArrowButton.width) + spaceBetweenArrows); searchButton.x = ((fsButton.x + fsButton.width) + spaceBetweenArrows); ppButton.x = ((searchButton.x + searchButton.width) + spaceBetweenArrows); thumbButton.x = ((ppButton.x + ppButton.width) + spaceBetweenArrows); imageContainers = new Array(); mcFullSizePage = new MovieClip(); addChild(mcFullSizePage); i = 0; while (i < numLoaders) { imageContainers[i] = new ImageContainer(); mcFullSizePage.addChild(imageContainers[i]); imageContainers[i].addEventListener("imageLoaded", imageLoaded); imageContainers[i].addEventListener(MouseEvent.MOUSE_UP, function (_arg1:MouseEvent){ navigateToURL(new URLRequest(ImageContainer(_arg1.currentTarget).imageLink), "_top"); }); imageContainers[i].buttonMode = true; imageContainers[i].visible = false; i = (i + 1); }; activeContainer = imageContainers[1]; mcFullSizePage.addChild(controlPanel); controlPanel.addChild(leftArrowButton); controlPanel.addChild(ppButton); controlPanel.addChild(rightArrowButton); controlPanel.addChild(fsButton); controlPanel.addChild(searchButton); controlPanel.addChild(thumbButton); controlPanel.x = ((stage.stageWidth / 2) - (controlPanel.width / 2)); controlPanel.y = (stage.stageHeight - controlPanel.height); addEventListener(MouseEvent.MOUSE_MOVE, startFadeInControlPanel); rightArrowButton.addEventListener(MouseEvent.MOUSE_UP, loadNextPicture); leftArrowButton.addEventListener(MouseEvent.MOUSE_UP, loadPrevPicture); fsButton.addEventListener(MouseEvent.MOUSE_UP, toggleFullscreen); ppButton.addEventListener(MouseEvent.MOUSE_UP, togglePausePlay); searchButton.addEventListener(MouseEvent.MOUSE_UP, showSearchForm); thumbButton.addEventListener(MouseEvent.MOUSE_UP, loadThumbPage); controlPanel.alpha = 0; drawBackground(); stage.addEventListener(FullScreenEvent.FULL_SCREEN, fullScreenRedraw); stage.addEventListener(MouseEvent.MOUSE_OUT, onMouseOut); stage.addEventListener(MouseEvent.MOUSE_OVER, onMouseOver); cpFullWidth = controlPanel.width; cpFullHeight = controlPanel.height; cpSmallWidth = (controlPanel.width * 0.8); cpSmallHeight = (controlPanel.height * 0.8); thumbCPBigWidth = thumbCP.width; thumbCPBigHeight = thumbCP.height; thumbCPSmallWidth = (thumbCP.width * 0.8); thumbCPSmallHeight = (thumbCP.height * 0.8); controlPanel.width = cpSmallWidth; controlPanel.height = cpSmallHeight; thumbCP.width = thumbCPSmallWidth; thumbCP.height = thumbCPSmallHeight; searchPanel = new MovieClip(); addChild(searchPanel); txtFormat2 = new TextFormat(); txtFormat2.color = 0; txtFormat2.font = "Arial"; searchLabels = new MovieClip(); searchTextBoxes = new MovieClip(); searchBG = new Shape(); txtUsername = new TextField(); txtY = 0; if (showUserID){ txtUsernameLabel = new TextField(); txtUsernameLabel.autoSize = TextFieldAutoSize.LEFT; txtUsernameLabel.text = "Username "; txtUsernameLabel.setTextFormat(txtFormat2); txtUsernameLabel.x = -(txtUsernameLabel.width); txtUsernameLabel.y = 0; txtUsername.width = 100; txtUsername.height = 20; txtUsername.type = TextFieldType.INPUT; txtUsername.border = true; searchLabels.addChild(txtUsernameLabel); searchLabels.setTextFormat = txtFormat2; searchTextBoxes.addChild(txtUsername); txtY = (txtY + 25); }; txtRSS = new TextField(); if (showRSS){ txtRSSLabel = new TextField(); txtRSSLabel.text = "RSS URL "; txtRSSLabel.setTextFormat(txtFormat2); txtRSSLabel.autoSize = TextFieldAutoSize.LEFT; txtRSSLabel.x = -(txtRSSLabel.width); txtRSSLabel.y = txtY; txtRSS.width = 100; txtRSS.height = 20; txtRSS.type = TextFieldType.INPUT; txtRSS.defaultTextFormat = txtFormat2; txtRSS.border = true; txtRSS.y = txtY; searchLabels.addChild(txtRSSLabel); searchTextBoxes.addChild(txtRSS); txtY = (txtY + 25); }; txtTagsLabel = new TextField(); txtTagsLabel.autoSize = TextFieldAutoSize.LEFT; txtTagsLabel.text = "Keywords "; txtTagsLabel.setTextFormat(txtFormat2); txtTagsLabel.x = -(txtTagsLabel.width); txtTagsLabel.y = txtY; txtTags = new TextField(); txtTags.width = 100; txtTags.height = 20; txtTags.type = TextFieldType.INPUT; txtTags.defaultTextFormat = txtFormat2; txtTags.border = true; txtTags.y = txtY; txtY = (txtY + 25); searchLabels.addChild(txtTagsLabel); searchTextBoxes.addChild(txtTags); mcSearchButton = new MovieClip(); g = mcSearchButton.graphics; g.beginFill(buttonFillColor); g.drawRect(0, 0, 45, 20); g.endFill(); txtFormat = new TextFormat(); txtFormat.color = 0xFFFFFF; txtFormat.font = "Arial"; txtSearchLabel = new TextField(); txtSearchLabel.selectable = false; txtSearchLabel.width = 45; txtSearchLabel.autoSize = TextFieldAutoSize.CENTER; txtSearchLabel.text = "search"; txtSearchLabel.setTextFormat(txtFormat); mcSearchButton.addChild(txtSearchLabel); searchTextBoxes.addChild(mcSearchButton); mcSearchButton.x = 2; mcSearchButton.y = txtY; mcCancelButton = new MovieClip(); g = mcCancelButton.graphics; g.beginFill(buttonFillColor); g.drawRect(0, 0, 45, 20); g.endFill(); txtCancelLabel = new TextField(); txtCancelLabel.selectable = false; txtCancelLabel.width = 45; txtCancelLabel.autoSize = TextFieldAutoSize.CENTER; txtCancelLabel.text = "cancel"; txtCancelLabel.setTextFormat(txtFormat); mcCancelButton.addChild(txtCancelLabel); searchTextBoxes.addChild(mcCancelButton); mcCancelButton.y = mcSearchButton.y; mcCancelButton.x = ((mcSearchButton.x + mcSearchButton.width) + 6); margin = 8; searchLabels.x = (searchLabels.width + margin); searchTextBoxes.x = (searchLabels.width + margin); searchLabels.y = margin; searchTextBoxes.y = margin; searchPanel.addChild(searchBG); searchPanel.addChild(searchLabels); searchPanel.addChild(searchTextBoxes); searchPanel.visible = false; g = searchBG.graphics; g.lineStyle(1, 0xFFFFFF); g.beginFill(0xFFFFFF, 0.9); g.drawRoundRect(0, 0, (searchPanel.width + (margin * 2)), (searchPanel.height + (margin * 2)), 5, 5); g.endFill(); centerOnStagePositive(searchPanel); resizeIfBiggerThanStage(searchPanel); mcSearchButton.buttonMode = true; mcSearchButton.mouseChildren = false; mcCancelButton.buttonMode = true; mcCancelButton.mouseChildren = false; mcSearchButton.addEventListener(MouseEvent.MOUSE_UP, function (){ doSearch({userID:txtUsername.text, rssURL:txtRSS.text, tag:txtTags.text, startIndex:0}); }); mcCancelButton.addEventListener(MouseEvent.MOUSE_UP, cancelSearch); stage.addEventListener(Event.RESIZE, resizeHandler); resizeHandler(null); mcFullSizePage.visible = false; doSearch({userID:paramObj.up_userID, rssURL:paramObj.up_rssURL, tag:paramObj.up_tag}); } private function removeThumbs(){ var _local1:Number; if (mcThumbContainers.numChildren > 0){ _local1 = 0; while (_local1 < mcThumbContainers.numChildren) { mcThumbContainers.getChildAt(_local1).removeEventListener(MouseEvent.MOUSE_UP, loadImageContainerSelf); ImageContainer(mcThumbContainers.getChildAt(_local1)).cleanUp(); _local1++; }; while (mcThumbContainers.numChildren > 0) { mcThumbContainers.removeChildAt(0); }; }; } function fadeOutControlPanel(_arg1:Event){ var _local2:MovieClip; _local2 = MovieClip(_arg1.target); _local2.alpha = (_local2.alpha - 0.1); if (_local2.alpha <= 0){ _local2.removeEventListener(Event.ENTER_FRAME, fadeOutControlPanel); }; } function menuHandler(_arg1:ContextMenuEvent):void{ if (!fullScreenMode){ _arg1.target.customItems[0].enabled = true; _arg1.target.customItems[1].enabled = false; } else { _arg1.target.customItems[0].enabled = false; _arg1.target.customItems[1].enabled = true; }; } private function loadNextImageOffScreen(){ var _local1:Number; _local1 = (currentPictureNum + 1); loadOffScreenContainer(_local1); } function createTriangle(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Sprite{ var _local5:Sprite; var _local6:Graphics; _local5 = new Sprite(); _local6 = _local5.graphics; _local6.lineStyle(3, _arg3); _local6.moveTo((_arg2 * 0.1), 0); _local6.lineTo(_arg2, 0); _local6.moveTo(0, 0); _local6.lineStyle(2, _arg3); _local6.beginFill(_arg4); _local6.lineTo(_arg1, -(_arg1)); _local6.lineTo(_arg1, 0); _local6.lineTo(_arg1, _arg1); _local6.lineTo(0, 0); _local6.endFill(); return (_local5); } function startFadeOutControlPanel(_arg1:TimerEvent){ if (((controlPanelActive) && (((!(mouseIn)) || (!((((mouseY > (stage.stageHeight - controlPanel.height))) && ((mouseY < stage.stageHeight))))))))){ controlPanel.addEventListener(Event.ENTER_FRAME, fadeOutControlPanel); controlPanel.removeEventListener(Event.ENTER_FRAME, fadeInControlPanel); controlPanelActive = false; }; if (((thumbCPActive) && (((!(mouseIn)) || (!((((mouseY > (stage.stageHeight - thumbCP.height))) && ((mouseY < stage.stageHeight))))))))){ thumbCP.addEventListener(Event.ENTER_FRAME, fadeOutControlPanel); thumbCP.removeEventListener(Event.ENTER_FRAME, fadeInControlPanel); thumbCPActive = false; }; } private function loadThumbPage(_arg1:Event=null){ stopSlideShow(); showThumbPage(); firstThumbIndex = (int((currentPictureNum / thumbsPerPage)) * thumbsPerPage); if (firstThumbIndex < startIndex){ loadXMLPrev(); } else { createThumbs(); }; if (!showThumbs){ showThumbs = true; setPrefJS("showThumbs", "true"); }; } public function getStageDimensions(_arg1:Event){ if (stage.stageWidth > 0){ removeEventListener(Event.ENTER_FRAME, getStageDimensions); init(); }; } private function imageLoaded(_arg1:Event){ var _local2:ImageContainer; showFullSizePage(); _local2 = ImageContainer(_arg1.target); if (!_local2.visible){ lastPictureNumLoaded = _local2.pictureNum; }; if (slideShowPlaying){ if (slideShowTimerEnded){ showImage(); _local2.resizeImage(stage.stageWidth, stage.stageHeight); loadNextImageOffScreen(); slideShowTimer.reset(); slideShowTimer.start(); slideShowTimerEnded = false; } else { _local2.resizeImage(stage.stageWidth, stage.stageHeight); }; } else { showImage(); _local2.resizeImage(stage.stageWidth, stage.stageHeight); }; } private function doFadeTrans(_arg1:MovieClip, _arg2:MovieClip){ var mc1 = _arg1; var mc2 = _arg2; Tweener.addTween(mc1, {alpha:0, time:2, onComplete:function (){ this.visible = false; }}); mc2.visible = true; mc2.alpha = 0; Tweener.addTween(mc2, {alpha:1, time:2}); } function fadeInButton(_arg1:Event){ if (_arg1.currentTarget.alpha < 1){ _arg1.currentTarget.alpha = (_arg1.currentTarget.alpha + 0.1); } else { _arg1.currentTarget.removeEventListener(Event.ENTER_FRAME, fadeInButton); }; } function togglePausePlay(_arg1:Event=null){ reverse = false; if (slideShowPlaying){ stopSlideShow(); setPrefJS("pictureNum", ("" + currentPictureNum)); } else { slideShowPlaying = true; ppButton.showPause(); slideShowTimer.reset(); slideShowTimer.start(); loadNextImageOffScreen(); }; } private function loadOnScreenContainer(_arg1:Number){ var _local2:ImageContainer; _local2 = getContainer(true); loadImageContainer(_local2, _arg1); } private function loadImageContainerSelf(_arg1:MouseEvent){ var _local2:ImageContainer; _local2 = ImageContainer(_arg1.currentTarget); currentPictureNum = _local2.pictureNum; activeContainer.visible = false; loadOffScreenContainer(currentPictureNum); setPrefJS("pictureNum", ("" + currentPictureNum)); if (showThumbs){ showThumbs = false; setPrefJS("showThumbs", "false"); }; } function slideShowNextPicture(_arg1:Event){ var _local2:ImageContainer; currentPictureNum++; firstThumbIndex = (int((currentPictureNum / thumbsPerPage)) * thumbsPerPage); if (lastPictureNumLoaded == currentPictureNum){ showImage(); _local2 = getContainer(true); _local2.resizeImage(stage.stageWidth, stage.stageHeight); loadNextImageOffScreen(); slideShowTimer.reset(); slideShowTimer.start(); slideShowTimerEnded = false; } else { slideShowTimerEnded = true; }; } function loadImageContainerThumb(_arg1:ImageContainer, _arg2:Number){ var _local3:String; var _local4:String; if (numPictures > 0){ _local3 = ""; _local4 = ""; if (isRSS){ _local3 = xmlResult.channel.item[(_arg2 - startIndex)].group.thumbnail[thumbXMLIndex].@url; } else { if (((((_arg2 - startIndex) >= 0)) && (((_arg2 - startIndex) < xmlResult.entry.length())))){ _local3 = xmlResult.entry[(_arg2 - startIndex)].group.thumbnail[thumbXMLIndex].@url; }; }; if (_local3 != ""){ _arg1.loadImage(_local3, _arg2, _local4); }; trace(("thumb imageURL=" + _local3)); }; } private function showSearchForm(_arg1:Event){ searchPanel.visible = true; controlPanel.visible = false; thumbCP.visible = false; if (slideShowPlaying){ togglePausePlay(null); }; exitFullscreen(); } private function hideSearchForm(_arg1:Event){ searchPanel.visible = false; controlPanel.visible = true; thumbCP.visible = true; } private function onMouseOut(_arg1:Event){ mouseIn = false; } private function createThumbs(_arg1:Event=null){ var _local2:ImageContainer; var _local3:Number; var _local4:Number; var _local5:Number; var _local6:Number; _local3 = (thumbsPerPage / thumbsPerRow); _local4 = (int((firstThumbIndex / thumbsPerRow)) % _local3); _local5 = ((int((firstThumbIndex / thumbsPerPage)) + 1) * thumbsPerPage); if ((firstThumbIndex % thumbsPerRow) == 0){ _local4--; }; _local6 = firstThumbIndex; while (_local6 < _local5) { if (_local6 >= numPictures){ firstThumbIndex = _local6; loadXMLNext(); break; } else { if ((_local6 % thumbsPerPage) == 0){ removeThumbs(); }; }; if ((_local6 % thumbsPerRow) == 0){ _local4++; }; _local2 = new ImageContainer(); mcThumbContainers.addChild(_local2); loadImageContainerThumb(_local2, _local6); _local2.x = (((_local6 % thumbsPerRow) * (thumbWidth + thumbMargin)) + thumbMargin); _local2.y = ((_local4 * (thumbHeight + thumbMargin)) + thumbMargin); _local2.addEventListener("imageLoaded", thumbLoaded); _local2.addEventListener(MouseEvent.MOUSE_UP, loadImageContainerSelf); _local2.buttonMode = true; _local6++; }; } private function showFullSizePage(){ mcThumbPage.visible = false; mcFullSizePage.visible = true; } private function thumbLoaded(_arg1:Event){ var _local2:ImageContainer; _local2 = ImageContainer(_arg1.target); _local2.resizeImage(thumbWidth, thumbHeight, _local2.x, _local2.y); _local2.removeEventListener("imageLoaded", thumbLoaded); } public function loadXMLPrev(){ if (!mcThumbPage.visible){ firstThumbIndex = (currentPictureNum - thumbsPerPage); }; startIndex = (int((firstThumbIndex / thumbsPerPage)) * thumbsPerPage); if (startIndex < 0){ startIndex = 0; }; loadXML(feedURL, displayResult); } function createFsButton(_arg1:Number, _arg2:Number):MovieClip{ var curve:Number; var w:Number; var h:Number; var scW:Number; var scH:Number; var arrowColor:Number; var g:Graphics; var fsButton:MovieClip; var screenSp:Sprite; var tipL:Number; var arrL:Number; var expandArrows:Sprite; var arrow1:Sprite; var arrow2:Sprite; var arrow3:Sprite; var arrow4:Sprite; var shrinkArrows:Sprite; var buttonLineColor = _arg1; var buttonFillColor = _arg2; curve = 8; w = 30; h = 30; scW = (w * 0.25); scH = (h * 0.25); arrowColor = 0xFFFFFF; fsButton = new MovieClip(); fsButton.buttonMode = true; g = fsButton.graphics; g.lineStyle(2, buttonLineColor, 1, true); g.beginFill(buttonFillColor); g.drawRoundRect(0, 0, w, h, curve, curve); g.endFill(); screenSp = new Sprite(); g = screenSp.graphics; g.lineStyle(2, arrowColor); tipL = (w * 0.15); arrL = (w * 0.35); expandArrows = new Sprite(); arrow1 = createTriangle(tipL, arrL, arrowColor, arrowColor); arrow1.x = (w * 0.13); arrow1.y = (h * 0.13); arrow1.rotation = 45; expandArrows.addChild(arrow1); arrow2 = createTriangle(tipL, arrL, arrowColor, arrowColor); arrow2.x = (w * 0.87); arrow2.y = (h * 0.13); arrow2.rotation = 135; expandArrows.addChild(arrow2); arrow3 = createTriangle(tipL, arrL, arrowColor, arrowColor); arrow3.x = (w * 0.87); arrow3.y = (h * 0.87); arrow3.rotation = 225; expandArrows.addChild(arrow3); arrow4 = createTriangle(tipL, arrL, arrowColor, arrowColor); arrow4.x = (w * 0.13); arrow4.y = (h * 0.87); arrow4.rotation = 315; expandArrows.addChild(arrow4); shrinkArrows = new Sprite(); arrow1 = createTriangle(tipL, arrL, arrowColor, arrowColor); arrow1.x = (w * 0.4); arrow1.y = (h * 0.4); arrow1.rotation = 225; shrinkArrows.addChild(arrow1); arrow2 = createTriangle(tipL, arrL, arrowColor, arrowColor); arrow2.x = (w * 0.6); arrow2.y = (h * 0.4); arrow2.rotation = 315; shrinkArrows.addChild(arrow2); arrow3 = createTriangle(tipL, arrL, arrowColor, arrowColor); arrow3.x = (w * 0.6); arrow3.y = (h * 0.6); arrow3.rotation = 45; shrinkArrows.addChild(arrow3); arrow4 = createTriangle(tipL, arrL, arrowColor, arrowColor); arrow4.x = (w * 0.4); arrow4.y = (h * 0.6); arrow4.rotation = 135; shrinkArrows.addChild(arrow4); fsButton.addChild(shrinkArrows); fsButton.addChild(expandArrows); fsButton.addChild(screenSp); fsButton.showEnterFullScreen = function (){ expandArrows.visible = true; shrinkArrows.visible = false; }; fsButton.showExitFullScreen = function (){ expandArrows.visible = false; shrinkArrows.visible = true; }; fsButton.showEnterFullScreen(); return (fsButton); } function exitFullscreen(){ if (fullScreenMode){ stage.displayState = StageDisplayState.NORMAL; }; } private function drawBackground(){ background.graphics.clear(); background.graphics.beginFill(backgroundColor); background.graphics.drawRect(0, 0, stage.stageWidth, stage.stageHeight); background.graphics.endFill(); } function exitFullScreen(_arg1:ContextMenuEvent):void{ stage.displayState = StageDisplayState.NORMAL; } private function loadOffScreenContainer(_arg1:Number){ var _local2:ImageContainer; _local2 = getContainer(false); if (_arg1 >= numPictures){ loadXMLNext(); } else { if ((_arg1 - startIndex) < 0){ loadXMLPrev(); } else { loadImageContainer(_local2, _arg1); }; }; } private function determineThumbsPerPage(){ var _local1:*; var _local2:Number; var _local3:Number; var _local4:Number; var _local5:Number; _local2 = 0; _local4 = stage.stageWidth; _local5 = stage.stageHeight; if ((((_local4 > 600)) && ((_local5 > 500)))){ thumbWidth = 144; thumbHeight = 144; thumbXMLIndex = 1; thumbMargin = 10; } else { thumbWidth = 72; thumbHeight = 72; thumbXMLIndex = 0; thumbMargin = 5; }; thumbsPerRow = int((stage.stageWidth / (thumbWidth + thumbMargin))); _local1 = int(((stage.stageHeight + _local2) / (thumbHeight + thumbMargin))); thumbsPerPage = (_local1 * thumbsPerRow); mcThumbContainers.x = ((_local4 / 2) - (((thumbWidth + thumbMargin) * thumbsPerRow) / 2)); mcThumbContainers.y = ((_local5 / 2) - (((thumbHeight + thumbMargin) * _local1) / 2)); } private function getPrefJS(_arg1:String):String{ var _local2:Object; _local2 = ExternalInterface.call("getPrefForFlash", _arg1); trace(((("getPref: " + _arg1) + "=") + _local2)); return (("" + _local2)); } public function displayResult(_arg1:Event){ var loader:URLLoader; var tempXML:XML; var i:Number; var e = _arg1; loader = URLLoader(e.target); tempXML = new XML(loader.data); if (isRSS){ numPictures = tempXML.channel.item.length(); } else { numPictures = tempXML.entry.length(); }; numPictures = (numPictures + startIndex); if (currentPictureNum > numPictures){ currentPictureNum = 0; }; if (numPictures > 0){ if (numPictures < maxResults){ lastPictureNum = (numPictures - 1); }; xmlResult = tempXML; if (firstLoad){ if (isRSS){ i = 0; while (i < xmlResult.channel.item.length()) { if (savedImageLink == xmlResult.channel.item[i].link){ currentPictureNum = (i + startIndex); break; }; i = (i + 1); }; } else { i = 0; while (i < xmlResult.entry.length()) { if (savedImageLink == xmlResult.entry[i].link.(@rel == "alternate").@href){ currentPictureNum = (i + startIndex); break; }; i = (i + 1); }; }; firstThumbIndex = (int((currentPictureNum / thumbsPerPage)) * thumbsPerPage); }; if (showThumbs){ loadThumbPage(); } else { loadOffScreenContainer(currentPictureNum); setPrefJS("pictureNum", ("" + currentPictureNum)); }; } else { removeThumbs(); if (firstLoad){ firstLoad = false; startIndex = 0; currentPictureNum = 0; firstThumbIndex = 0; loadXML(feedURL, displayResult); trace("had to reload due to no pictures"); }; }; firstLoad = false; setPrefJS("startIndex", ("" + startIndex)); } public function loadXML(_arg1:String, _arg2:Function){ var _local3:Number; var _local4:LocalConnection; var _local5:String; var _local6:URLRequest; var _local7:URLLoader; _local3 = Math.max(this.maxResults, thumbsPerPage); _arg1 = (_arg1 + ((("&start-index=" + (startIndex + 1)) + "&max-results=") + _local3)); _local4 = new LocalConnection(); _local5 = _local4.domain; trace(("url=" + _arg1)); _local6 = new URLRequest(_arg1); _local7 = new URLLoader(); _local7.addEventListener(Event.COMPLETE, _arg2); _local7.load(_local6); } private function setPrefJS(_arg1:String, _arg2:String):void{ var _local3:Object; _local3 = ExternalInterface.call("setPrefForFlash", _arg1, _arg2); } function fullScreenRedraw(_arg1:FullScreenEvent):void{ if (_arg1.fullScreen){ fullScreenMode = true; controlPanel.width = cpFullWidth; controlPanel.height = cpFullHeight; thumbCP.width = thumbCPBigWidth; thumbCP.height = thumbCPBigHeight; fsButton.showExitFullScreen(); thumbFSButton.showExitFullScreen(); } else { controlPanel.width = cpSmallWidth; controlPanel.height = cpSmallHeight; thumbCP.width = thumbCPSmallWidth; thumbCP.height = thumbCPSmallHeight; fullScreenMode = false; fsButton.showEnterFullScreen(); thumbFSButton.showEnterFullScreen(); }; resizeHandler(null); if (mcThumbPage.visible){ loadThumbPage(); } else { activeContainer.visible = false; loadOnScreenContainer(currentPictureNum); }; if (slideShowPlaying){ loadNextImageOffScreen(); }; } function startFadeOutButton(_arg1:MouseEvent){ _arg1.currentTarget.addEventListener(Event.ENTER_FRAME, fadeOutButton); _arg1.currentTarget.removeEventListener(Event.ENTER_FRAME, fadeInButton); } function loadNextPicture(_arg1:Event){ reverse = false; currentPictureNum++; if (slideShowPlaying){ togglePausePlay(null); }; firstThumbIndex = (int((currentPictureNum / thumbsPerPage)) * thumbsPerPage); loadOffScreenContainer(currentPictureNum); setPrefJS("pictureNum", ("" + currentPictureNum)); } private function getContainer(_arg1:Boolean):ImageContainer{ var _local2:Number; _local2 = (activeContainerNum + 1); if (_local2 >= numLoaders){ _local2 = 0; }; return (imageContainers[_local2]); } private function toggleThumbFullSizePage(){ if (mcThumbPage.visible == true){ mcThumbPage.visible = false; mcFullSizePage.visible = true; } else { mcThumbPage.visible = true; mcFullSizePage.visible = false; }; } function loadImageContainer(_arg1:ImageContainer, _arg2:Number){ var description:String; var imageURL:String; var imageLink:String; var container = _arg1; var i = _arg2; i = (i - startIndex); if (numPictures > 0){ if (isRSS){ if (stage.stageHeight < 400){ imageURL = xmlResult.channel.item[i].group.thumbnail[2].@url; } else { imageURL = xmlResult.channel.item[i].group.content.@url; }; description = xmlResult.channel.item[i].group.description; imageLink = xmlResult.channel.item[i].link; } else { if (stage.stageHeight < 400){ imageURL = xmlResult.entry[i].group.thumbnail[2].@url; } else { imageURL = xmlResult.entry[i].group.content.@url; }; description = xmlResult.entry[i].group.description; imageLink = xmlResult.entry[i].link.(@rel == "alternate").@href; }; if (!slideShowPlaying){ setPrefJS("imageLink", imageLink); }; imageLink = StringUtil.replace(imageLink, "photos.googleapis.com", "picasaweb.google.com"); trace(("imageURL=" + imageURL)); container.loadImage(imageURL, (i + startIndex), imageLink, description); }; } private function onMouseOver(_arg1:Event){ mouseIn = true; } public function loadXMLNext(){ startIndex = (int((currentPictureNum / thumbsPerPage)) * thumbsPerPage); loadXML(feedURL, displayResult2); } function resizeHandler(_arg1:Event):void{ determineThumbsPerPage(); controlPanel.x = ((stage.stageWidth / 2) - (controlPanel.width / 2)); controlPanel.y = (stage.stageHeight - controlPanel.height); thumbCP.x = ((stage.stageWidth / 2) - (thumbCP.width / 2)); thumbCP.y = (stage.stageHeight - thumbCP.height); centerOnStagePositive(searchPanel); resizeIfBiggerThanStage(searchPanel); if (!mcThumbPage.visible){ centerOnStage(activeContainer); activeContainer.resizeImage(stage.stageWidth, stage.stageHeight); }; drawBackground(); } function createArrowButton(_arg1:Number, _arg2:Number):MovieClip{ var curve:Number; var arrowButtonW:Number; var arrowButtonH:Number; var arrowH:Number; var arrowW:Number; var arrowColor:Number; var g:Graphics; var arrowButton:MovieClip; var arrowSp:Sprite; var buttonLineColor = _arg1; var buttonFillColor = _arg2; curve = 8; arrowButtonW = 30; arrowButtonH = 30; arrowH = (arrowButtonH * 0.65); arrowW = (arrowButtonW * 0.3); arrowColor = 0xFFFFFF; arrowButton = new MovieClip(); arrowButton.buttonMode = true; g = arrowButton.graphics; g.lineStyle(2, buttonLineColor, 1, true); g.beginFill(buttonFillColor); g.drawRoundRect(0, 0, arrowButtonW, arrowButtonH, curve, curve); g.endFill(); arrowSp = new Sprite(); g = arrowSp.graphics; g.lineStyle(2, arrowColor); g.beginFill(arrowColor); g.moveTo(arrowW, 0); g.lineTo(arrowW, (arrowH * 0.26)); g.lineTo((arrowW + (arrowW * 0.75)), (arrowH * 0.26)); g.lineTo((arrowW + (arrowW * 0.75)), (arrowH * 0.74)); g.lineTo(arrowW, (arrowH * 0.74)); g.lineTo(arrowW, arrowH); g.lineTo(0, (arrowH / 2)); g.lineTo(arrowW, 0); g.endFill(); arrowSp.y = ((arrowButtonH / 2) - (arrowH / 2)); arrowSp.x = ((arrowButton.width / 2) - (arrowSp.width * 0.55)); arrowButton.addChild(arrowSp); arrowButton.flip = function (){ arrowSp.scaleX = -1; arrowSp.x = (arrowSp.x + arrowSp.width); }; return (arrowButton); } } }//package

Special Tags

FileAttributes (69)Timeline Frame 1Access local files only, Metadata not present, AS3.




http://swfchan.com/16/78763/info.shtml
Created: 3/4 -2019 11:57:44 Last modified: 3/4 -2019 11:57:44 Server time: 22/12 -2024 05:33:41