Shape (instance?) question

hello,

can you guys tell me how this code works, im having trouble understanding what’s going on…


//class import, declaration, constructor etc.

var myRect:Shape = new Shape();
/* fill shape, drawRect.... */

var a:Sprite = new Sprite();
stage.addChild(a);
a.addChild(myRect);

var b:Sprite = new Sprite();
stage.addChild(b);
b.addChild(myRect);

ok, say I have some code like that- what happens is that only sprite b has fill, I can’t see fill in sprite a… Why? Shouldn’t myRect shape behave like instance and appear in both sprites? or I’m moving it from one to another?

Sasxa