dcsimg
A Flash Developer Resource Site

Page 2 of 3 FirstFirst 123 LastLast
Results 21 to 40 of 41

Thread: [F8] Whisper's...fullScreen...external files

  1. #21
    Moderator whispers's Avatar
    Join Date
    Mar 2001
    Location
    CFA2h (respect the HEX)
    Posts
    12,755
    Well there has been tons of code posted, doesnt look like you have tried much...outside of whats been done for you....


    positioning is still a problem? ok.. do you want it to center or not?..yes or no?

    these loaded 'sections'?

  2. #22
    Senior Member
    Join Date
    Aug 2004
    Posts
    289
    PLEASE don't tell me that. I have been fiddling exclusively with code...yours and other code...for about 4 days, in the same file. Problem is, I'm not well versed AT ALL with dynamically driven code. It is also the first time I am attempting the fullScreen thing, which I think is where its at, so to speak.

    Therefore, the questions. I'm not twiddling my thumbs!

    I have no idea where to place the new containers, or how to code the buttons. I have managed to unload that one clip from a button, but then, what about loading the new clip/content?

  3. #23
    Moderator whispers's Avatar
    Join Date
    Mar 2001
    Location
    CFA2h (respect the HEX)
    Posts
    12,755
    here:

    http://www.dmstudios.net/bluej2_reSize.zip

    this:
    PHP Code:
    //-------------------// do not touch the code below (for now) //-------------------//
    //start Stage re-size code
    Stage.align "TL";
    Stage.scaleMode "noScale";
    // ---> Create a new listener object
    var stageListener:Object = new Object();
    // ---> Define the resize function...
    stageListener.onResize = function() {
        
    // ---> first, get the new dimensions of the stage....
        
    var stageWidth:Number Math.round(Stage.width);
        var 
    stageHeight:Number Math.round(Stage.height);
        
    trace("Stage size is now " Stage.width " by " Stage.height);
        
    // ---> now, set the footer BG w & h to the stage dimensions...
        
    footerBG_mc._width stageWidth;
        
    footerBG_mc._x 2;
        
    footerBG_mc._y stageHeight 25;
        
    // ---> now, set the footer links to the stage dimensions...
        
    footerLinks_mc._x = (stageWidth 2) - (footerLinks_mc._width 2);
        
    footerLinks_mc._y stageHeight 18;
        
    // ---> now, set the background clip/image alignment to match stage...(always centered)
        
    wallPaper_mc._x = (stageWidth 2) - (wallPaper_mc._width 2);
        
    wallPaper_mc._y = (stageHeight 2) - (wallPaper_mc._height 2);
        
    //external Holder positiong
        
    externalContainer._x = (stageWidth 2) - (externalContainer._width 2);
        
    externalContainer._y = (stageHeight 2) - (externalContainer._height 2);
    };
    // --->  Apply the listener...
    Stage.addListener(stageListener);

    //-------------------// do not touch the code above (for now) //-------------------//

    //load my external content
    this.createEmptyMovieClip("externalContainer"5);
    footerLinks_mc.swapDepths(6);
    var 
    xListener:Object = new Object();
    xListener.onLoadInit = function(target_mc:MovieClip) {
        
    //position itself correctly
        
    trace("INIT FIRED");
        
    target_mc._x = (Stage.width 2) - (target_mc._width 2);
        
    target_mc._y = (Stage.height 2) - (target_mc._height 2);
        
    target_mc.onPress = function() {
            
    trace("NAME: " this._name);
            
    //externalContainer.unloadMovie();
        
    };
    };
    var 
    xLoader:MovieClipLoader = new MovieClipLoader();
    xLoader.addListener(xListener);


    //create function to  load external .swf into containerClip.
    function loadExternal(contentToLoad) {
        
    xLoader.loadClip(contentToLoadexternalContainer);
    }
    footerLinks_mc.home_btn.onPress = function() {
        
    loadExternal("home.swf");
    };
    footerLinks_mc.port_btn.onPress = function() {
        
    loadExternal("events.swf");
    };
    // ---> Run the function...
    loadExternal("initial.swf");
    stageListener.onResize(); 
    will do what yo have asked:

    1.) make a FULLSCREEN .swf.. keeping certain things constrained to certain positions.. (i.e.: the footer/links will always be at the bottom, the BG images will always be centered no matter the screen res....)

    2.) this will load an external.swf into a 'containerClip' and always keep it centered.. on stage...

    3.) the links at the bottom will load a NEW .swf into the SAME container.. again..always keeping it centered on the stage..




    Is there anything missing?

  4. #24
    Senior Member
    Join Date
    Aug 2004
    Posts
    289
    Whispers...that's it. That is all I needed. You did it...I almost had a nervous breakdown...you saved the day...and, you made my day!

    thankyouthankyouthankyou.



    bluej2 signing off.

  5. #25
    Junior Member
    Join Date
    Apr 2010
    Location
    DfW Texas
    Posts
    13
    Quote Originally Posted by whispers View Post
    here:

    http://www.dmstudios.net/bluej2_reSize.zip

    this:
    PHP Code:
    //-------------------// do not touch the code below (for now) //-------------------//
    //start Stage re-size code
    Stage.align "TL";
    Stage.scaleMode "noScale";
    // ---> Create a new listener object
    var stageListener:Object = new Object();
    // ---> Define the resize function...
    stageListener.onResize = function() {
        
    // ---> first, get the new dimensions of the stage....
        
    var stageWidth:Number Math.round(Stage.width);
        var 
    stageHeight:Number Math.round(Stage.height);
        
    trace("Stage size is now " Stage.width " by " Stage.height);
        
    // ---> now, set the footer BG w & h to the stage dimensions...
        
    footerBG_mc._width stageWidth;
        
    footerBG_mc._x 2;
        
    footerBG_mc._y stageHeight 25;
        
    // ---> now, set the footer links to the stage dimensions...
        
    footerLinks_mc._x = (stageWidth 2) - (footerLinks_mc._width 2);
        
    footerLinks_mc._y stageHeight 18;
        
    // ---> now, set the background clip/image alignment to match stage...(always centered)
        
    wallPaper_mc._x = (stageWidth 2) - (wallPaper_mc._width 2);
        
    wallPaper_mc._y = (stageHeight 2) - (wallPaper_mc._height 2);
        
    //external Holder positiong
        
    externalContainer._x = (stageWidth 2) - (externalContainer._width 2);
        
    externalContainer._y = (stageHeight 2) - (externalContainer._height 2);
    };
    // --->  Apply the listener...
    Stage.addListener(stageListener);

    //-------------------// do not touch the code above (for now) //-------------------//

    //load my external content
    this.createEmptyMovieClip("externalContainer"5);
    footerLinks_mc.swapDepths(6);
    var 
    xListener:Object = new Object();
    xListener.onLoadInit = function(target_mc:MovieClip) {
        
    //position itself correctly
        
    trace("INIT FIRED");
        
    target_mc._x = (Stage.width 2) - (target_mc._width 2);
        
    target_mc._y = (Stage.height 2) - (target_mc._height 2);
        
    target_mc.onPress = function() {
            
    trace("NAME: " this._name);
            
    //externalContainer.unloadMovie();
        
    };
    };
    var 
    xLoader:MovieClipLoader = new MovieClipLoader();
    xLoader.addListener(xListener);


    //create function to  load external .swf into containerClip.
    function loadExternal(contentToLoad) {
        
    xLoader.loadClip(contentToLoadexternalContainer);
    }
    footerLinks_mc.home_btn.onPress = function() {
        
    loadExternal("home.swf");
    };
    footerLinks_mc.port_btn.onPress = function() {
        
    loadExternal("events.swf");
    };
    // ---> Run the function...
    loadExternal("initial.swf");
    stageListener.onResize(); 
    will do what yo have asked:

    1.) make a FULLSCREEN .swf.. keeping certain things constrained to certain positions.. (i.e.: the footer/links will always be at the bottom, the BG images will always be centered no matter the screen res....)

    2.) this will load an external.swf into a 'containerClip' and always keep it centered.. on stage...

    3.) the links at the bottom will load a NEW .swf into the SAME container.. again..always keeping it centered on the stage..




    Is there anything missing?
    I know this is forever ago but can you send me the fla? I am trying to have a fullscreen flash piece with the navigation sticking to the left at all times. daniel @ relevantmade.com

    Thanks!

  6. #26

  7. #27
    Junior Member
    Join Date
    Apr 2010
    Location
    DfW Texas
    Posts
    13
    Thanks whispers, sorry it took me so long to answer back but I had issues trying to log in.

    After searching and searching I found the link you provider and put it to use. The only problem is that it won't go to fullscreen. I just have basic images in there just to do some testing before I start developing the whole thing.

    Here is the .fla file I got everything working but the fullscreen. Any thoughts?

    http://www.redpalmonline.com/TPGPR/TPGPR_Main.zip

    Here is the link to the movie. Give it a sec I have not put a preloader in there yet.

    http://www.redpalmonline.com/TPGPR/TPGPR_Main.html

    Thanks for the help!!!!

  8. #28
    Moderator whispers's Avatar
    Join Date
    Mar 2001
    Location
    CFA2h (respect the HEX)
    Posts
    12,755
    hmm.. I guess there could be some confusion.

    fullscreen is meant in the terms of it will scale and adjust to the screen size/browser window.

    this does NOT go fullscreen (like [F11] or something)..

    you would have to add that.

    also I use Flash 8..AS2

    cant open your file.. what version is it? CS3?

  9. #29
    Junior Member
    Join Date
    Apr 2010
    Location
    DfW Texas
    Posts
    13
    Sorry, yes, I don't mean a true fullscreen. More like it takes on the whole size of the browser.

    I did this site a while back that is fullbrowser but I can't get the nav to stick left. So I wont searching for another fullbrowser solution.

    www.redpalmonline.com (again this is my old stuff )

    So yes, I need it to go fullbrowser and not fullscreen. Any thoughts?

    Thanks!!

  10. #30
    Moderator whispers's Avatar
    Join Date
    Mar 2001
    Location
    CFA2h (respect the HEX)
    Posts
    12,755
    are you editing the HTML file as well? 100% for height & width.. along with editing the body tags for 0 borders?

    ie:

    <body bgcolor="#ffffff" bottommargin="0" leftmargin="0" marginheight="0" marginwidth="0" rightmargin="0" topmargin="0">

  11. #31
    Junior Member
    Join Date
    Apr 2010
    Location
    DfW Texas
    Posts
    13
    Just added it and no change: http://www.redpalmonline.com/TPGPR/TPGPR_Main.html

    hmmm...

  12. #32
    Moderator whispers's Avatar
    Join Date
    Mar 2001
    Location
    CFA2h (respect the HEX)
    Posts
    12,755
    dont forget the first step I said..

    make all height & width values 100% not numbers..

    I checked your source code..you didnt change it..

  13. #33
    Junior Member
    Join Date
    Apr 2010
    Location
    DfW Texas
    Posts
    13
    100% did the trick! THANKS BRUTHA!!!! Now off to developing!

    Thanks again.

  14. #34
    Moderator whispers's Avatar
    Join Date
    Mar 2001
    Location
    CFA2h (respect the HEX)
    Posts
    12,755
    no problem.. just gotta read carefully it was mentioned in the other thread too i believe..

    the little things can trip you up..

    take care & good luck

  15. #35
    Junior Member
    Join Date
    Apr 2010
    Location
    DfW Texas
    Posts
    13
    My bad I was up till 1am and my brain was not all there when I was looking. Next time i'll get some rest before I research. LOL!

    Thanks, have a great week!

  16. #36
    Junior Member
    Join Date
    Apr 2010
    Location
    DfW Texas
    Posts
    13

    mc not loading center

    Ok everything is coming along great but my mc is not loading in the center of the page.

    When I have a mc that has no animation in it it seems to center nicely but when I add animation it makes it float.

    So here is what I am trying to do:
    1. Once the user clicks skip or enter go to frame label "start" (its working)
    2. Then "mcStart" will then come in and handle all the page content. (it comes in)
    3. "mcStart" will be center on the page (not working)
    4. "mcNav" will handle the navigation in "mcStart" (not working)

    Here is what it is doing now: http://www.thepresstigegrouppr.com/N...PGPR_Main.html

    Here is the fla: http://www.thepresstigegrouppr.com/N...in_042710B.zip

    Here is the live site which is what I have for now till I build the rest: http://www.thepresstigegrouppr.com

    Hope this makes sense. Thank you so much for any help you can provide!

  17. #37
    Moderator whispers's Avatar
    Join Date
    Mar 2001
    Location
    CFA2h (respect the HEX)
    Posts
    12,755
    2. Then "mcStart" will then come in and handle all the page content. (it comes in)
    3. "mcStart" will be center on the page (not working)


    explain/define 'then it comes in'?


    How? Is this an external .swf that you load in?

    Is this a movie clip 'off stage' or something..that slides in?

    How are you loading this movie?


    we'll start there..

  18. #38
    Junior Member
    Join Date
    Apr 2010
    Location
    DfW Texas
    Posts
    13
    explain/define 'then it comes in'?
    I want it to animate in and then animate out when the user clicks a btn

    How? Is this an external .swf that you load in?
    No its a internal mc from library.

    Is this a movie clip 'off stage' or something..that slides in?
    Its a mc that starts on stage but inside the mc there is an animation that brings the objects into view, center statge.

    How are you loading this movie?
    I am just dropping it from the library for now. Not calling in external swf's yet. Its a mc I created with in.

    I would love to load into a target and load it externally but not sure how to make the navigation talk to the external swf. I want the external swf to animate in then animate out each time they select a nav item. I am sure there is a simple way but I am a bit rusty in flash I mostly work on CSS now LOL.


    Thanks!!!!!!
    Last edited by RelevantMade; 05-02-2010 at 04:35 PM.

  19. #39
    Junior Member
    Join Date
    Apr 2010
    Location
    DfW Texas
    Posts
    13
    Any thoughts, thanks for any help you can provide bro!

  20. #40
    Junior Member
    Join Date
    Apr 2010
    Location
    DfW Texas
    Posts
    13
    Whispers? Hope you have not given up on me. I am sure its a simple fix. I just need the internal movie clip to center and I am golden!

    Thanks!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center