Search the Community

Showing results for tags 'load'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • HTML5 / JS
    • GSAP
    • Banner Animation
    • Jobs & Freelance
  • Flash / ActionScript Archive
    • GSAP (Flash)
    • Loading (Flash)
    • TransformManager (Flash)

Product Groups

  • Club GreenSock
  • TransformManager


There are no results to display.

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start





Website URL







Found 18 results

  1. Hi all... Is there anyone here??? I've found a simple but useful code developed a few years ago... it loads 2 swf files in sequence ... But I have just one question... How can I Loop them? How can you change the code to load swf1 after swf2 is finished? I've tried almost the whole day but no result yet... Please help... thank you a lot... import com.greensock.*; import com.greensock.loading.*; import; import; //create SWFLoaders var swf1:SWFLoader = new SWFLoader("child1.swf",{container:this,y:100,onProgress:progressHandler,onComplete:completeHandler,autoPlay:false}); var swf2:SWFLoader = new SWFLoader("child2.swf",{container:this,y:100,onProgress:progressHandler,onComplete:completeHandler,autoPlay:false}); var currentSWFLoader:SWFLoader = swf1; //adjust the progress bar; function progressHandler(e:LoaderEvent):void { bar.scaleX =; trace(; } //tell the loaded swf to play and start tracking frames function completeHandler(e:LoaderEvent):void { //the target of the LoaderEvent is the SWFLoader that fired the event //the rawContent is the loaded swf; addEventListener(Event.ENTER_FRAME, checkFrame); } function checkFrame(e:Event):void { //check to see if loaded swf is done playing if (currentSWFLoader.rawContent.currentFrame == currentSWFLoader.rawContent.totalFrames) { trace("swf done playing"); removeEventListener(Event.ENTER_FRAME, checkFrame); //if the first swf is done playing load the second swf if (currentSWFLoader == swf1) { currentSWFLoader.dispose(true) // dispose and unload content currentSWFLoader = swf2; currentSWFLoader.load(); } } } bar.scaleX = 0; currentSWFLoader.load();
  2. SalvoDee

    I'm looking for opinions

    Hi guys, this is my first attempt with GSAP, i would like to have any opinion for improve performance or the animation.
  3. Hi, I created a project using GSAP TimelineMax Plugin where the text on the left side slides in the original position from the left (kind of like fade in). var timeline = new TimelineMax(); timeline.from(".main-text-home-cta h2", 1, {x:-100, opacity:0},0) .from(".main-text-home-cta h4", 1, {x:-100, opacity:0},0) .from(".buttons-under-nested-rows", 1, {x:-100, opacity:0},0) .from(".devices-chat-picture", 1, {x:100, opacity:0}); The code above the code i used and added near the </body> tag and the TimelineMax and TweenMax JS files above the code. The problem i am facing is that when the page loads the text appears on the screen in its original position (the position it will after the animation completes) for few seconds (or till the time the page is loading) without animation and as soon as the page load is completed the animation starts. So I want to know whether this a problem with GSAP Plugin or I am doing something wrong. And also I want to know how to fix this so that while the page load nothinng will be shown in the view and after the page loads the animation will start. One more problem that I faced is that when the animation starts after the page load it is very slow and laggy (again I don't kow whose problem is this). Thanks.
  4. Hello people! I am struggling with this, what i want to do in my website is to click a link, take you to another page and also execute an animation. Basically im working a page with kind of tabs done with GreenSock, so for example, in my index i have two buttons to visit, Apple and Pear. If i click Pear, it will take me to a page that displays me Pear tab instead of Apple. That's it. Forgive my english! Its not my native language. Anyways this is the website im working on (spanish website) for example, i want to click in Hospedaje button, and then load the page in the Hospedaje tab instead of Unidades de Servicio. Thanks!
  5. Hi! I would like to call animation functions only after the external GSAP file is loaded. I could place the animation functions after the link to GSAP file like this: <script src=""></script> <script> //my animations </script> ...but I want to load TweenMax.min.js asynchronously and that's the problem: <script async src=""></script> I've googled it and found some kind of solution. The idea is to have a global variable created by the the external script and check whether it exists or not. If it exists, then the external JS is loaded. I found the solution here. So my question is: does TweenMax.min.js create any global variables or objects or whatever I can check the existence of? Thanks in advance!
  6. Hello Carl and eveybody ... I found this project you uploaded named loadSWFsPlaySequence dot zip ... but unfortunately I faced a big problem : problem 1 : as I want to load huge and multiple swfs one after another I should be aware of memory that loaded swfs take ,so I tried to unload last swf when new swf is loading but each time I failed ... problem 2 : how can I fade in each swf that is loading using loadeMax ? please somebody tell me am I such stupid or it's hard to ... can you help ? thanks a lot ... link to that file :
  7. Hi everyone and good morning... it's morning in my country! Pretty sure that everyone of you guys had played Angry Birds before... This game has a menu consisted of some boxes... You can't have access to next box whether you completed the previous one...Actually next boxes are locked; till you have completed previous one... (attached image) Now consider these boxes as buttons that load SWF files. When loaded SWF file reach its last frame it shows an "unlocked next box" and then save this situation. I want to create such a complex menu, but as I'm new to as3 and LoaderMax I NEED SOME HELP PLEASE >>> Problem 1: SWF files that should be load are not created with adobe flash Problem 2: How To Detect Last Frame of Loaded SWF File in LoaderMax? Maybe if I Can Trace That it is reached the last frame I can solve this ... Any Any Any Suggestions are EXTREMELY appreciated...Thanks a lot
  8. I need to make this event happen a few seconds after page loads. Can someone help? Also, the type weight is normal during transition but is bold as it should be after transition. Why? Thank you!
  9. fl.Ash

    Loading multiple images

    Hello guys, This is my first time using LoaderMax to load assets as I usually use the Starling asset manager however I am working on a standard flash application now and have had good experiences with TweenMax and TweenLite so thank you for providing these awesome tools! I am trying to load multiple images (pngs + jpegs) using the ImageLoader. It is working fine but I am looking for a way to be able to not add the images to the screen as soon as they are loaded and make them accessible to child sprites that I can't specify in the container parameter (These sprites are different screens which are created and destroyed as needed and do not exist at the time of loading). So basically, what is the best way to make these images accessible throught my application and not just in the class they are loaded in (this class is still a parent of all the sprites I will need to use these images in). Regards, Ash.
  10. Hey there everyone in the community, I am new here and firstly I gotta say to the GSAP Dev's...GREAT JOB, amazing plugin. But, even with its ease of use, I found it hard to aquire my desired effect. What I iam to accomplish, is to initiate a text animation I have used from your examples in the ZIP file, upon scrolling over the desired DIV. As it sits, GSAP uses: $(window).load(function() { to initiate the animations declared in the JS. Since I do not ant the animation to instantly start on page load, and I want it to start once scrolled over, this does not work for me. Now, I have tried the simple and powerful: $(window).on('scroll', function() { to try to reach my results. Hoever, even though it works upon scrolling over. It also works upon page load. Meaning, that lets say Im at the point of origin where the animations take place on the page. I refresh my page in that spot and the GSAP takes place right away. I move out of that space to another point on the page and scroll back to the animation area, and the letters in the animation are there as if the animation has finished (which it has because it still initiated on page load somehow) BUT then... the animation occurs upon scrolling over, but, get this...the animations from the scroll, take place underneath the completed animation that occured on page load. It is very hard to explain but you can evaulate my code below, and maybe help me to get the animation to only take effect when it is scrolled over. Here is my code: $(window).load(function() { var logo = $("#logo"), progressValue = $("#progressValue"), totalProgressValue = $("#totalProgressValue"), timeValue = $("#timeValue"), totalTimeValue = $("#totalTimeValue"), restartBtn = $("#restartBtn"), txtContainer = $("#txtContainer"), tl, progressSlider, totalProgressSlider, txt; /* Build DOM Elements*/ function splitText(phrase) { var prevLetter, sentence, sentence = phrase.split(""); $.each(sentence, function(index, val) { if(val === " "){ val = " "; } var letter = $("<div/>", { id : "txt" + index }).addClass('txt').html(val).appendTo(txtContainer); if(prevLetter) { $(letter).css("left", ($(prevLetter).position().left + $(letter).width()) + "px"); }; prevLetter = letter; }); txt = $(".txt"); } /* Build Timeline */ function buildTimeline() { //note this timeline uses 3D transforms which will only work in recent versions of Safari, Chrome, and FireFox. IE10 will support 3D transforms as well. All other browsers simply will not show those properties being tweened. TweenLite.set(txtContainer, {css:{perspective:500}}); tl = new TimelineMax({onUpdate:updateUI, repeat:2, repeatDelay:1, yoyo:true}); tl.from(logo, 0.5, {left:'-=60px', ease:Back.easeOut}); tl.staggerTo(txt, 0.6, {rotationX:"360deg", color:"858585", transformOrigin:"50% 50% 10"}, 0.02); } /* callbacks */ function updateUI() { //change slider value progressSlider.slider("value", tl.progress() *100); totalProgressSlider.slider("value", tl.totalProgress() *100); //update display of values progressValue.html(tl.progress().toFixed(2)); totalProgressValue.html(tl.totalProgress().toFixed(2)); timeValue.html(tl.time().toFixed(2)); totalTimeValue.html(tl.totalTime().toFixed(2)); } function init() { splitText("CONTACT US"); buildTimeline(); //show the demoBackground div after DOM is ready and all images loaded TweenLite.set($("#demoBackground"), {visibility:"visible"}); } init(); }); If anyone sees what I am doing wrong here, or can help...please do. I am not very new to JS or jQuery but am very new to GSAP. So any help is appreciated. Thanks in advance! EDIT: Here is my HTML: <div id="demo"> <h1 id="txtContainer"></h1> </div> </div> Thanks again! ~Jason of AJADMIN Websites
  11. Hello all, Was wondering if any one can see what the problem with this class is. What I'm trying to achieve is to load content into an empty container (_main.container in that is instantiated from my main class ( where I can keep its position fluid. I'm just transitioning to Greensock but have a tight deadline to get this working so I'm kind of hoping someone can help spot what I'm doing wrong. After I get this resolved I should be smooth sailing. Main Class - I want to load my external .swfs into a library object that is dynamically added here (var container) DockMenu Class - Where my navigation takes places, I want to call LoadSWF from here. LoadSWF Class - Reusable Loading class for swfs, my debugger is pointing to line 40 Any other areas that catch any of your eyes that could be improved or are incorrectly done let me know, the only way I can learn this stuff is by being shown I've found recently. Thanks in advance everyone, btw I don't think I'll ever use AS3 and Flash without Greensock again!
  12. Hello, I have an AIR application where I have to load a SWF from a server. At some point the user will click on a button and that button will create a new nativeWindow. Inside that nativeWindow we have a stage reference. I just want to load a SWF, addChild it to the stage and be happy! But I'm getting this error: SecurityError: Error #2070: Security sandbox violation: caller cannot access Stage owned by app:/Teste.swf. at flash.display::Stage/get stageWidth() at com.swfapp::MainClass/initApp() at flash.display::DisplayObjectContainer/addChild() at flash.display::Stage/addChild() at NativeWindowSWFLoader/loadSWFURLComplete()[C:\Users\hats\Desktop\teste\] I'm using a normal SWFLoader: private function loadSWF(url:String):void { holder = new MovieClip(); applicationDomain = new ApplicationDomain(); loaderContext = new LoaderContext(false, applicationDomain); loader = new SWFLoader(url, { context:loaderContext, container:holder, onProgress:progressHandler, onComplete:onCompleteSWFLoader } ); loader.load(); } private function onCompleteSWFLoader(e:Event):void { this.stage.addChild(holder); } Can someone hep me on this? Thank you.
  13. Vincentccw

    Staggering webpage on page load?

    I want to create an effect that it will load my web page gradually from 1 div to another once the page load. I have applied staggerFrom() method so that it can create the desired effect that will load from the header follow by content and extend till footer. But my problem is that when I put it on live server, the webpage will load the animation even though the content isn't fully loaded, resulting in freezing the animation for few seconds.... Is there any solution for this?
  14. Is there a way I can call a function whenever a SWF has finished unloading? I've searched in the docs, but I can't find what I need.
  15. fernandocomet

    Load js library from an absolut url

    Hi friends, In my document I am doing this: <script type="text/javascript" src="js/greensock/plugins/CSSPlugin.min.js"></script> <script type="text/javascript" src="js/greensock/TweenLite.min.js"></script> I would like to know if is it possible to load GSAP library from an absolut url. somethin as: <script type="text/javascript" src=""></script> Thanks
  16. Before I dig too deep, I'm hoping someone can direct me on how to modify LoaderMax to allow it to load PNG files that happen to not have the file extension .png. The files are under our control and are of the known type PNG, however, for various reasons, the file names do not contain a file extension in their names. Thanks!
  17. Can´t seem to make this play each time the "my_lc_as2" connect executes - it just plays plays one time. Can someone please help me out here import com.greensock.*; import com.greensock.easing.*; import com.greensock.plugins.*; TweenPlugin.activate([MotionBlurPlugin]); receiving_lc = new LocalConnection(); receiving_lc.execute_this = function(FT2) { var myTimeline:TimelineLite = new TimelineLite({onComplete:myFunction}); myTimeline.append(new TweenLite(FT, 0.3, { _x:50, _xscale:10, motionBlur:true, ease:yoyo.easeInOut})); myTimeline.append(new TweenLite(FT, 0.2, { _x:50, _xscale:10, _rotation:90, motionBlur:true, ease:cubic.easeInOut})); myTimeline.append(new TweenLite(FT, 0.5, { _x:50, _y:1200, _xscale:100, motionBlur:true, ease:Cubic.easeInOut})); } receiving_lc.connect("my_lc_as2"); function myFunction(){ myTimeline.invalidate(); }
  18. kuba sanitrak

    SWFLoader - play/stop loaded swf

    Hello, I have a question about accessing loaded swf files by SWFLoader class. I am loading swf file and want to play/stop its content on certain event managed by certain function, not autoplay. I have managed to access child clip of loaded swf (see sample code below). But is there a way to "play" directly the loaded swf file, so I do not have to put all my animations into child clips of loaded swf? Thanks up front for any suggestions kuba import com.greensock.*; import com.greensock.loading.*; import; import com.greensock.loading.display.*; import*; import flash.display.MovieClip; var clip_var:MovieClip; var myLoader:SWFLoader = new SWFLoader("data/swf/test2.swf", {name:"nameSwf", container:container_mc, autoPlay:false, onComplete:completeHandler} ); //start loading myLoader.load(); function progressHandler(event:LoaderEvent):void { //trace("progress: " +; } function completeHandler(event:LoaderEvent):void { trace( + " is complete!"); clip_var = myLoader.getSWFChild("clip_test") as MovieClip;//GET CHILD CLIP OF LOADED SWF (NAMED "clip_test") } function errorHandler(event:LoaderEvent):void { trace("error occured with " + + ": " + event.text); } function swfPlay(e:MouseEvent):void {; } stage.addEventListener(MouseEvent.CLICK, swfPlay);