Hey Mike,
If I've understood the previous mails correctly you wish to implement
IEventDispatcher in a class that already derives from another? (i.e. your
ModelLocator).
If this is the case, then in your class that implement IEventDispatcher you
want to create an instance of EventDispatcher, for example:
package com.dts_workshop.flexcoders.eventDispatcher
{
import flash.events.Event;
import flash.events.IEventDispatcher;
import flash.events.EventDispatcher;
public class CustomEventDispatcher extends SomeOtherClass implements
IEventDispatcher
{
private var _dispatcher : EventDispatcher;
public function CustomEventDispatcher() {
_dispatcher = new EventDispatcher(this);
}
public function dispatchEvent(event:Event):Boolean
{
return _dispatcher.dispatchEvent(event);
}
// Rest of implementation ....
}
EventDispatcher allows you to create an instance of it, passing in the class
that implements IEventDispatcher but cannot derive from EventDispatcher. Any
events raised will have the correct target.
For more information, take a look at the info for EventDispatcher in the
Flex 2 help.
Regards,
Oliver Tupman.
I hope that's what you're after.