0 Replies Latest reply on Jul 25, 2009 6:10 AM by HLProductions

    First post:  In total desperation...Simple resizing issue and keeping images centered on stage.  Giving a demonoid account for solution :)

    HLProductions Level 1

      Ok long story short I purchased a fullscreen xml gallery from FlashDen that is supposed to resize.  Here is the link to the demo...

       

      http://flashden.net/item/xml-resizeable-fullscreen-dark-gallery/full_screen_preview/19966

       

      Well problem is it only resizes the images based on their width and not their height.  (Panorama would show fine but a tall portrait would just go off the page)  You will notice in that demo how the resizing is fixed to the side of the painting and not the bottom.

       

      Well, to me this seams useless because I really need every user to be able to see the full pictures no matter what screen resolution they are at and no matter how they adjust their browser window.

       

      Believe me when I come posting on threads it means I have spend many many hours trying to figure it out myself...In this case I have spent 30 hours trying to solve this in the last two days....Now I am over the deadline I gave to my client/family member and am still at square one basically.

       

      Thank you so much for any tips/advice/input you can offer.

       

      Also note I have figured out how to make it so that it fixes to the bottom and thus shows the tall images in full but when I do this it is no longer centered in the page.

       

      I am really tired and worn out but would love to work with someone's advice to make this a reality.

       

      Attached is everything you would need.  Please note that by downloading this attachment you are agreeing to only using these files to help out your new friend Sean and would never think about using this for your own project.

       

      Thanks so much for helping out the new guy.  I will owe you big time!

       

       

      Also, Here is the version I am working on...

      http://nasso.us/new/

       

      It's going to be pretty cool huh?

       

       

      Also, in my version on nasso.us..You will notice I got it to almost work for the tall images..Still not there yet...and it all goes off center with that code...To get those resualts though I switched this....

      //determine image size
      resizeImage = function(getResizeClip){
           //eval(getResizeClip);
           stageWidth = Stage.width;
           stageHeight = Stage.height;
           bgWidth = eval(getResizeClip)._width;
           bgHeight = eval(getResizeClip)._height;
           heightRatio = stageWidth/bgWidth;
           widthRatio = stageHeight/bgHeight;
           if(heightRatio<widthRatio){
                eval(getResizeClip)._width = widthRatio*bgWidth;
                eval(getResizeClip)._height = widthRatio*bgHeight;
           }else{
                eval(getResizeClip)._width = heightRatio*bgWidth;
                eval(getResizeClip)._height = heightRatio*bgHeight;
           }
      };
      

      with this

       

      //determine image size
      resizeImage = function(getResizeClip){
           //eval(getResizeClip);
           stageWidth = Stage.width;
           stageHeight = Stage.height;
           bgWidth = eval(getResizeClip)._width;
           bgHeight = eval(getResizeClip)._height;
           heightRatio = stageWidth/bgWidth;
           widthRatio = stageHeight/bgHeight;
           if(heightRatio<widthRatio){
                eval(getResizeClip)._width = widthRatio*bgWidth;
                eval(getResizeClip)._height = widthRatio*bgHeight;
           }else{
                eval(getResizeClip)._width = heightRatio*bgWidth;
                eval(getResizeClip)._height = heightRatio*bgHeight;
           }
      };
      

       

       

      THANK YOU THANK YOU THANK YOU