hello!
i jumped here from general help - forum, as i was adviced that i could get more advice here. and all help will be very much appreciated!

i have created a background mc (instange name bg) that i want to scale to fill all screens. then i have a content mc (content) that should always stay centered, not scaling, even when screen size changes.

the problem is that all works just ok to begin with. but if i, for some reason, decide to resize screen while viewing, the content mc soon gets stuck to the top of screen. not cool, eh! i'm using flash 8 and mozilla + ie for testing.

questions: what should i change/add in the code below? i found the code in a thread in fk. or, is there possibly another, smarter way to reach the desired effect? a simple, uniform coloured bg will not fit the design of the page.

thank you, you kind souls, for sharing your wisdom

Code:
// noScale prevents content in the movie resizing (unless we tell it to!)
Stage.scaleMode = "noScale";

// TL means all positions measured from the top left hand corner
Stage.align = "TL";

// a function to be called when the movie resizes
// this will resize the background clip to fill the stage
bg.onResize = function() {
    this._width = Stage.width;
    this._height = Stage.height;
};
// get the bg clip to listen for events (onResize) 
// broadcast by the stage object
Stage.addListener(bg);

bg._x = bg._y = 0;
bg.onResize();

// this function will position the content clip in the centre
// when the movie resizes
content.onResize = function() {
    this._x = (Stage.width - this._width) / 2;
    this._y = (Stage.height - this._height) / 2;
};
Stage.addListener(content);
content.onResize();