RE: [flexcoders] Re: Simple Event Listener Examples between 2 classes

2006-07-11 Thread Danny Patterson
You're not adding the TestHandler object as a listener of the TestDispatcherClass object. Your code is actually registering to itself. Also, you probably shouldn't dispatch an event from the constructor, since that runs before anything else you won't be able to add a listener before your

Re: [flexcoders] Re: Simple Event Listener Examples between 2 classes

2006-07-10 Thread Jeremy Lu
well, you should not dispatch the event right in the constructor, nobody would be able to catch it (it's too fast). moderations as following: package com.test { import flash.display.Sprite; import flash.events.Event; import com.test.EventManager;