Frame 1
stop();
var myclip = _root.img;
var myeasing = 0.5;
var myX = 0;
var myY = 0;
var myviewW = 1280;
var myviewH = 720;
var mystartX = ((myclip._width - myviewW) / 2);
var mystartY = ((myclip._height - myviewH) / 2);
var nMC = (new com.McSlider(myclip, myeasing, myX, myY, myviewW, myviewH, mystartX, mystartY));
Symbol 3 MovieClip Frame 1
play();
Symbol 4 MovieClip [__Packages.com.McSlider] Frame 0
class com.McSlider
{
var __mc, __ease, __mcp, __imgW, __imgH, __control, __rect, __yDiff, __yScale, __yPos, __xDiff, __xScale, __xPos;
function McSlider (_mc, _ease, _clipX, _clipY, _apertureW, _apertureH, _xoff, _yoff) {
__mc = _mc;
__ease = _ease;
__mcp = __mc._parent;
__imgW = __mc._width;
__imgH = __mc._height;
__mc._x = _clipX;
__mc._y = _clipY;
__mc.cacheAsBitmap = true;
__control = __mc.createEmptyMovieClip("controller", __mc.getNextHighestDepth());
__rect = new flash.geom.Rectangle(_xoff, _yoff, _apertureW, _apertureH);
__mc.scrollRect = __rect;
__mc.onRollOver = mx.utils.Delegate.create(this, initiateMovement);
__mc.onRollOut = (__mc.onDragOut = mx.utils.Delegate.create(this, killMovement));
__mc.useHandCursor = false;
}
function killMovement() {
delete __control.onEnterFrame;
}
function initiateMovement() {
__control.onEnterFrame = mx.utils.Delegate.create(this, calcXY);
}
function calcXY() {
__yDiff = __mcp._ymouse - __mc._y;
__yScale = __yDiff / __rect.height;
__yPos = __yScale * (__imgH - __rect.height);
__xDiff = __mcp._xmouse - __mc._x;
__xScale = __xDiff / __rect.width;
__xPos = __xScale * (__imgW - __rect.width);
__rect.x = __xPos - ((__xPos - __rect.x) * __ease);
__rect.y = __yPos - ((__yPos - __rect.y) * __ease);
__mc.scrollRect = __rect;
}
}
Symbol 5 MovieClip [__Packages.mx.utils.Delegate] Frame 0
class mx.utils.Delegate extends Object
{
var func;
function Delegate (f) {
super();
func = f;
}
static function create(obj, func) {
var _local2 = function () {
var _local2 = arguments.callee.target;
var _local3 = arguments.callee.func;
return(_local3.apply(_local2, arguments));
};
_local2.target = obj;
_local2.func = func;
return(_local2);
}
function createDelegate(obj) {
return(create(obj, func));
}
}