PDA

View Full Version : [Q] ScrollPane content not visible???


CyanBlue
02-04-2005, 03:29 PM
Howdy... :)

It's been a while since I did not use scrollPane... and I think I am missing something here... :(

I have a movieClip, t_mc, on the stage, and I have a scrollPane in the library...

this.attachMovie("FScrollPaneSymbol", "a_sp", 100);
this.a_sp.setSize(200, 200);
this.t_mc.onPress = function () {trace("hello -- alpha : " + this._alpha + " visible : " + this._visible);}
this.a_sp.setScrollContent(this.t_mc);
this.a_sp.refreshPane();

That code makes the t_mc sitting inside of the a_sp... I can click on the t_mc to see the "hello -- alpha : 100 visible : true" on the output panel... YET, I don't see the t_mc as if it's visible property is turned to off...

What am I missing here??? :(

CyanBlue
02-05-2005, 06:33 PM
Ah... Finally figured it out... I totally forgot the fact that scrollPane can only contain the movieClip that's above it's depth level... Dang... I had no idea what Mortimer Jazz meant by swapDepths on that day... Some good rest makes my brain freshened... :D

This is the working script just in case anybody want to know...

this.attachMovie("FScrollPaneSymbol", "a_sp", 100);
this.a_sp.setSize(200, 200);
this.t_mc.onPress = function () {trace("hello -- alpha : " + this._alpha + " visible : " + this._visible);}
this.t_mc.swapDepths(111);
this.a_sp.setScrollContent(this.t_mc);
this.a_sp.refreshPane();