I have a overriden function in my class, that adds an event handler like so:
override public function hide():void {
...
tween.addEventListener(TweenEvent.MOTION_FINISH, function(evt:Event):void {
...
super.hide();
}, false, 0, true);
}
This does not work, Flash tells me: "1006: A super expression can be used only inside class instance methods." (it works if moved to a proper instance method).
So I would like to understand why can't I use call to super.hide();
from my in-place handler function?
I can refer to any instance variables and methods from there without problems, so I thought that that handler had access to proper context. Please help me understand this.