Futurescale, Inc. PureMVC Home

The PureMVC Framework Code at the Speed of Thought


Over 10 years of community discussion and knowledge are maintained here as a read-only archive.

New discussions should be taken up in issues on the appropriate projects at https://github.com/PureMVC

Show Posts

| * |

  Show Posts
Pages: [1]
1  PureMVC Manifold / Standard Version / handleNotification and order on: March 31, 2009, 11:10:02
I've been attempting to tackle pureMVC for a while and would get discouraged rather easily, but Today I finally sat down and started making an application. I find it is much easier to do that with a goal in mind, rather than just learning how it works.

well here's something I came up against that has me quite confused.
I have two mediators that handle notifications: mA and mB;

the mediator mA is the main mediator that runs the big picture, but they both handle the same two notifications E1 and E2.

I have mB sending a notification E2 upon receiving E1.

for some reason I can see that the trace is showing that the notifications within the models are firing in this order

mB - E1
mB - E2
mA - E2
mA - E1

Though I'm not ruling out the possibility of a mistake on my part...

I'm wondering why the events don't fire in this sequence
mA - E1
mB - E1
mA - E2
mB - E2

if I remove sending a notification E2 after mB processing E1 I get
mB - E1
mA - E1

Is this at all normal? I don't have much experience with pureMVC so I'm asking if somebody either knows why this happens and/or can suggest some better practices to avoid this odd behaviour.
Pages: [1]