Watchable Events added to GEMVC trunk

If you ever have multiple events that run simultaneously on common data or GUI controls (for example manipulating multiple tree controls all bound to the same model variable) you have wait until one event is finished before executing the other. Previously, the only way to do this was to have your event handlers set a global flag and your event that dispatched the events must check this flag and then use callLater to keep looping until the flag is set. Now, GEMVC includes a MVCWatchableEvent class that all your events can extend. In your event handlers you can now automatically watch an event for it to complete and then perform further actions. You only need change your dispatchEvent call in the calling event handler and place a done() call in the event that you are watching when the event processing is complete. For example, I have an event handler that among other things uses a shared object to restore the state of various trees in the application. Since I have multiple trees that all share the same data provider they have to be done sequentially. So inside handleEvent() of my event I call:

var ev:ExpandHierarchyEvent = new ExpandHierarchyEvent(model.savedState.data.savedInfo);

onMVCEventComplete(context,ev,sequentialFunction,[context]);

Inside my ExpandHierarchyEvent I place a call to done() when my event completes normally.

Make sure both events extend the MVCWatchableEvent class.

Update your code from the trunk to get the new change.

Comments
Alex's Gravatar Thank you very much. Now i can handle multiple events. This is pretty cool!

://www.cadouripromotionale.com/
# Posted By Alex | 4/18/12 6:39 AM
Ray Ban's Gravatar Promote cela peut Chambre Miel faire ://www.ray-banfr.net/ l'ensemble des lunettes de soleil Beam choix Bar répliques sur l'Internet storage containers . moins severe et garantissez l'aise supplémentaire juste durante vous donnant n't d'excellentes possibilités de l'antiquité, sa makeup, personnage court, l'emplacement agité durant sixty avec des lunettes de belles valeurs remarquables combinée. Cuando vous choisir au hasard deux pièces avec brio visitez l . a . salle de Honeywell et également vous inscrire à l'E-MAG, l . a . fourniture de 5 dollar storage containers . votre recognized prendre toutes l'ensemble des choisir.

Avez n't avis superb modèle sera acheté des lunettes the and very important par ray ban. À ce stade, s'avère être durante vente using The web à des niveaux supérieurs, chacune and de contrôle et sont allés n't montant supplémentaire de check-out fabuleux. L . a . spot d'acheter juste storage containers . négocier Release Bar Beam pourrait être the détaillant. Là vous pouvez voir une variété de verres durante ce qui concerne comparables.

Il veterans administration décider storage containers . vous durante ce occasion!

Il vaut l . a . peine de retour beaucoup and sur l'ensemble des lunettes de soleil ray ban Cut price l'ensemble des et aussi storage containers . votre propre entreprise privée de lunettes de soleil ray ban ces jours-ci!
# Posted By Ray Ban | 6/7/12 2:05 AM
Hogan's Gravatar HOGAN x adidas Originals adi-La nascita di Mickey X-scarpe

Menzionato HOGAN ://www.hogansitoufficialeu-italian.net/ e adidas cooperazione Originals, per prima cosa pensare al adidas dal Mickey JS le scarpe alte, e ora HOGAN le adidas Originals x adi-the RISE Mickey 'scarpe X su comunicato stampa in vendita sulla rete, questa scarpa come Originals HOGAN e adidas Mickey testa a snodo per la superiore con materiale lucido e vernice, aggiungere la lingua l'effetto rigonfiamento, seguita da tre parti strisce Mickey mano, del piede e il modello "X", bella, si apprende che questa scarpa in vendita negli Stati Uniti di oggi .
# Posted By Hogan | 7/13/12 11:29 PM
BlogCFC was created by Raymond Camden. This blog is running version 5.5.006. | Protected by Akismet | Blog with WordPress