2 Replies Latest reply on Jun 18, 2013 11:00 PM by Emraan.Khan

    I want to start gallrey left to right.

    Emraan.Khan Level 1

      I want to start gallrey left to right. my flash stage size is 1300px 700px.... please help

      <?xml version="1.0" encoding="utf-8"?>

      <gallery thumb_width="350" thumb_height="290">

       

      <image thumb_url="shop.png"  full_url="front.jpg" title="Mango Juice"/>
      <image thumb_url="banner1.png"  full_url="front.jpg" title="Mango Juice" />
      <image thumb_url="shop2.png"  full_url="front.jpg" title="Mango Juice"/>

       

      </gallery>

        • 1. Re: I want to start gallrey left to right.
          Ned Murphy Adobe Community Professional & MVP

          You are only showing data for a gallery.  You'll need to show the code that you are having trouble getting working. 

           

          If you do not have any code, you should start searching Google using terms like "AS2 gallery tutorial".

          • 2. Re: I want to start gallrey left to right.
            Emraan.Khan Level 1

            yes,,, i have a code which is-----

             

            import mx.transitions.Tween;

            import mx.transitions.Zoom.*;

            import caurina.transitions.*;

             

            var myGalleryXML = new XML();

            myGalleryXML.ignoreWhite = true;

            myGalleryXML.load("gallery.xml");

             

            myGalleryXML.onLoad = function() {

                _root.gallery_x = myGalleryXML.firstChild.attributes.gallery_x=100;

                _root.gallery_y = myGalleryXML.firstChild.attributes.gallery_y;

                _root.gallery_width = myGalleryXML.firstChild.attributes.gallery_width;

                _root.gallery_height = myGalleryXML.firstChild.attributes.gallery_height;

             

                _root.myImages = myGalleryXML.firstChild.childNodes;

                _root.myImagesTotal = myImages.length;

             

                _root.thumb_height = myGalleryXML.firstChild.attributes.thumb_height;

                _root.thumb_width = myGalleryXML.firstChild.attributes.thumb_width;

             

                _root.full_x = myGalleryXML.firstChild.attributes.full_x;

                _root.full_y = myGalleryXML.firstChild.attributes.full_y;

             

                callThumbs();

               

            };

             

             

            function callThumbs() {           

             

                _root.createEmptyMovieClip("wall",_root.getNextHighestDepth());

                wall._x = _root.gallery_x= 0;

                wall._y = _root.gallery_y= 340;

               

             

               

            wall.addEventListener(MouseEvent.CLICK);

             

             

             

                var clipLoader = new MovieClipLoader();

                var preloader = new Object();

                clipLoader.addListener(preloader);

               

               

                /**/

               

                for (i=0; i<15; i++) {

                    thumbURL = myImages[i].attributes.thumb_url;

                   

                    myThumb_mc = wall.createEmptyMovieClip(i, wall.getNextHighestDepth());

                    myThumb_mc._x = _root.thumb_height*i;

                    myThumb_mc._x = _root.thumb_position=-2000;

                       

                    clipLoader.loadClip("thumbs/"+thumbURL,myThumb_mc);

                   

             

                    preloader.onLoadStart = function(target) {

                        target.createTextField("my_txt",target.getNextHighestDepth(),0,0,10,10);

                        target.my_txt.selectable = false;

                    };

             

                   

                    preloader.onLoadProgress = function(target, loadedBytes, totalBytes) {

                        target.my_txt.text = Math.floor((loadedBytes/totalBytes)*100);

                    };

             

                    preloader.onLoadComplete = function(target) {

                        new Tween(target, "_alpha", Strong.easeOut, 0, 100, .5, true);

                        target.my_txt.removeTextField();

                        target.onRelease = function() {

                            callFullImage(this._name);

                           

                        };

             

             

             

                        target.onRollOver = function() {

                            this._alpha = 100;

                        };

             

                        target.onRollOut = function() {

                            this._alpha = 100;

                        };

                       

                    };

                }

            }

             

            and i also want to space between thumbs..