Combined Code
frame 1 {
function ShowButtons() {
btprev._visible = false;
pages._visible = false;
actualframe = bd._currentframe;
pages.text = actualframe - 1 + '/' + (maxframe - 1);
if (actualframe == 1) {
btprev._visible = false;
} else {
btprev._visible = true;
}
if (actualframe == maxframe) {
btnext._visible = false;
} else {
btnext._visible = true;
}
if (actualframe == 1) {
pages._visible = false;
} else {
pages._visible = true;
}
}
bd.stop();
var maxframe = bd._totalframes;
var actualframe;
var marge = 20;
var input = new Object();
AutoPosition();
ShowButtons();
btnext.onRollOver = function () {
this.gotoAndStop(2);
};
btnext.onRollOut = function () {
this.gotoAndStop(1);
};
btnext.onPress = function () {
this.gotoAndStop(3);
};
btnext.onRelease = function () {
this.gotoAndStop(1);
bd.nextFrame();
ShowButtons();
};
btprev.onRollOver = function () {
this.gotoAndStop(2);
};
btprev.onRollOut = function () {
this.gotoAndStop(1);
};
btprev.onPress = function () {
this.gotoAndStop(3);
btprev.onRelease = function () {
this.gotoAndStop(1);
};
bd.prevFrame();
ShowButtons();
};
input.onKeyDown = function () {
if (Key.isDown(37)) {
bd.prevFrame();
}
if (Key.isDown(39)) {
bd.nextFrame();
}
if (Key.isDown(40)) {
bd.gotoAndStop(1);
}
if (Key.isDown(38)) {
bd.gotoAndStop(maxframe);
}
ShowButtons();
};
Key.addListener(input);
}
movieClip 13 {
}
movieClip 17 {
frame 1 {
stop();
}
frame 2 {
stop();
}
frame 3 {
stop();
}
}