Kod
Kod AS wygląda tak:
var slideShowXML:XML = new XML();
var slideShow:Array;
function showThumbs() {
var thumbLevel:Number = 200;
for( var thumbLoopIndex:Number = 0; thumbLoopIndex < slideShow.length; thumbLoopIndex++ ) {
var kbPictureNode:XMLNode = slideShow[thumbLoopIndex];
var kbPicture:String = kbPictureNode.attributes.file;
var thumbPic:MovieClip = _root.createEmptyMovieClip( "thumb" + thumbLoopIndex, thumbLevel + thumbLoopIndex );
thumbPic._y = (Math.floor(thumbLoopIndex % 8) * 45) + 10; // 8 pictures are in a row 40 pixels high
thumbPic._x = 10; // each picture is 60 pixels wide
thumbPic._alpha = 100;
thumbPic.loadMovie( "thumbs/" + kbPicture );
}
}
slideShowXML.onLoad = function( success:Boolean ):Void {
var slideShowRoot:XMLNode = slideShowXML.firstChild;
slideShow = slideShowRoot.childNodes;
showThumbs();
}
slideShowXML.ignoreWhite = true;
slideShowXML.load( "ogien.xml" );
thumbLoopIndex.onRelease=function(){
pokaz.contentPath="thumbs/" + kbPicture;
}
var slideShowXML:XML = new XML();
var slideShow:Array;
function showThumbs() {
var thumbLevel:Number = 200;
for( var thumbLoopIndex:Number = 0; thumbLoopIndex < slideShow.length; thumbLoopIndex++ ) {
var kbPictureNode:XMLNode = slideShow[thumbLoopIndex];
var kbPicture:String = kbPictureNode.attributes.file;
var thumbPic:MovieClip = _root.createEmptyMovieClip( "thumb" + thumbLoopIndex, thumbLevel + thumbLoopIndex );
thumbPic._y = (Math.floor(thumbLoopIndex % 8) * 45) + 10; // 8 pictures are in a row 40 pixels high
thumbPic._x = 10; // each picture is 60 pixels wide
thumbPic._alpha = 100;
thumbPic.loadMovie( "thumbs/" + kbPicture );
}
}
slideShowXML.onLoad = function( success:Boolean ):Void {
var slideShowRoot:XMLNode = slideShowXML.firstChild;
slideShow = slideShowRoot.childNodes;
showThumbs();
}
slideShowXML.ignoreWhite = true;
slideShowXML.load( "ogien.xml" );
thumbLoopIndex.onRelease=function(){
pokaz.contentPath="thumbs/" + kbPicture;
}