A Flash Developer Resource Site

Results 1 to 5 of 5

Thread: fluid full screen swf with swffit

  1. #1
    Member
    Join Date
    Feb 2002
    Location
    Canada
    Posts
    78

    fluid full screen swf with swffit

    I've been looking around for a bit and have found lots of examples but can't figure it out.

    I want to display some images, 100% W 100% H of the browser. This is easy.

    The problem is i don't want things like the navigation to scale too.

    For example:
    http://www.tanyashields.com/index2.php
    http://www.artwolfe.com/

    Does anyone know how this is done?

  2. #2
    AS2 intolerant person
    Join Date
    Jan 2009
    Location
    Swansea
    Posts
    352
    its about when you publish it. set percentage 100%, and no scale

    flos

  3. #3
    Member
    Join Date
    Feb 2002
    Location
    Canada
    Posts
    78
    I can scale the movie though the HTML tags which is what i think you're saying. But what i'm wondering is how do i set some pieces (movie clips) to scale and others to not scale.

    See the examples above. The photos scale with the browser but the logos and nav. doesn't... err... don't.
    Last edited by kayec; 10-21-2009 at 04:39 PM.

  4. #4
    Member
    Join Date
    Feb 2002
    Location
    Canada
    Posts
    78

  5. #5
    Member
    Join Date
    Feb 2002
    Location
    Canada
    Posts
    78

    Thumbs up

    Yup, that worked great. Hope this helps someone searching...

    Code:
    Stage.scaleMode = "noScale";
    Stage.align = "T";
    var catchStage:Object = new Object();
    Stage.addListener(catchStage);
    catchStage.onResize = function() {
    	if (Stage.height/Stage.width > bg_mc._height/bg_mc._width) {
    		img_prop = bg_mc._width/bg_mc._height;
    		bg_mc._height = Stage.height;
    		bg_mc._width = Stage.height*img_prop;
    		bg_mc._y = 0;
    		bg_mc._x = 0;
    	} else {
    		img_prop = bg_mc._height/bg_mc._width;
    		bg_mc._width = Stage.width;
    		bg_mc._height = Stage.width*img_prop;
    		bg_mc._y = 0;
    		bg_mc._x = 0;
    	}
    }

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