-
Resizing Movie Clip
This should be simple enough but for some reason it's not.
I've created a movieClip using illustrator, which is a radial gradient in a rectangle. Original size is 1024 x 125. However I want the width to be whatever size the NativeWindow is. Not the stage but the nativeWindow. No matter what I try the width always comes out to 1024 (unless I specifically give it a size, like headerBg.width = 300. I'd like it to constantly stay the same size as the nativeWindow whenever that window is resized as well, but right now I can't even get the initial instance to display correctly. Any hints?
-
What code are you using to resize the movieClip currently?
-
I figured out a work around in that I made the initial window not visible and added a new window so I could refer to that instance.
Now I'm using:
headerBg.width = mainWin.width;
headerBg is the movieClip and mainWin is the new Window.
before I was trying to set a variable also called mainWin and trying
mainWin = this.stage.nativeWindow;
headerBg.width = mainWin.width;
but that wasn't working. If I would have just left the initial window visible how do I refer to that instance?
-
I really don't know anything about nativeWindow to be honest...
Sorry!
-
The only thing I can think of is that you aren't exporting to AIR... Have you made sure of this?