1 Reply Latest reply on May 11, 2007 11:53 AM by Newsgroup_User

    Dynamic Layout

    jak9942
      I am creating an AS3 application with a dynamic layout. i am having trouble with making an mc stay in the center of the flash document even when the stage is resized. does anybody know how to do this?

      thanks
        • 1. Re: Dynamic Layout
          Level 7
          You would use the resize event of the stage.
          http://livedocs.adobe.com/flex/201/langref/flash/display/Stage.html#event:resize

          Make sure the scaleMode has been set to StageScaleMode.NO_SCALE. Then in the
          resize handler you would move your mc based on stage.stageWidth and
          stage.stageHeight. (probably setting the mc's position to those values
          halfed for x and y respectively)

          "jak9942" <webforumsuser@macromedia.com> wrote in message
          news:f2281e$66j$1@forums.macromedia.com...
          >I am creating an AS3 application with a dynamic layout. i am having trouble
          > with making an mc stay in the center of the flash document even when the
          > stage
          > is resized. does anybody know how to do this?
          >
          > thanks
          >