Thanks sebastian with helping me with my last problem

This time, i've searched for helped but only found examples involving
components.

My question is regarding MVC design pattern event handling

in my "View" i attach a movieClip from the library that acts as a next
button;
I am trying to recieve the event in my "Controller" which should call a
method in my "Model" which in turn updates the "Observers";

the problem i have is how do i set up this event handling without using
static methods?

So far my code looks something like this;

"View"
mcNext.onPress = function():Void {
        Controller.onPress(this._name);
}

"Controller"
public static function onPress(broadcaster:String):Void {
        Model(getModel()).changeData(broadcaster);
}

"Model"
public function changeData(broadcaster:String):Void {
        var infoObj:Update = new Update(broadcaster);
        setChanged();
        notifyObservers(infoObj);
}

"Error"
Line 274: Instance variables cannot be accessed in static functions.
                Model(getModel()).changeData(broadcaster);


Help please?????









---
You are currently subscribed to fugli as: [email protected]
To unsubscribe send a blank email to [EMAIL PROTECTED]
Aussie Macromedia Developers: http://lists.daemon.com.au/

Reply via email to