I've created a small component in Flash CS4, and I have associated my MyComp symbol with it's respective MyComp class. The code in MyComp.as looks as follows:
package {
import flash.display.MovieClip;
public class MyComp extends MovieClip
{
public function MyComp()
{
trace(this.test);
}
private var _test:String;
[Inspectable(defaultValue="blah")]
public function get test():String
{
return this._test;
}
public function set test(v:String):void
{
this._test = v;
}
}
}
When I drag the component to a test FLA, the component's properties are all showing up as per the Inspectable[] meta tag. But when I set the properties in the Component Inspector, the value is always null, despite what the Component Inspector says.
When tracing for example test, it always outputs null?
How do I get the Component Inspector's values to reflect in the component at runtime?