It looks like adobe.js is using the constructor method as a kind of marker function, and compiling the actual constructor into the 'init' method (which is weird IMHO, since you can inherit from the parent constructor, and protect the prototype chain without calling the constructor via other means - and many AS3 classes may already legitimately be using an init method for other purposes, creating a collision).

So, the adobe.extend( 'name', SuperRef ) - the SuperRef is the marker function, and when you call extend it should be invoking the super constructor (line 88 in adobe.js).

For methods, if a method name exists on parent, and also exists on child, the extend method is adding a closure, which will preserve, and then invoke the parent's method in _super() (line 75 in adobe.js).

I didn't notice any place in the example code where super was invoked directly, so I'm not sure how Falcon handles that.

From a quick look anyway.

Kevin N.


On 11/28/12 2:54 PM, Daniel Wasilewski wrote:
Can any JS savvy person here tell me how according to adobe.js module pattern call super? I just lost my head..., got 3 classes extending each other and the only top one call init(); I am preparing those performance tests for comparison.

Dan

Reply via email to