Javascript / Flash : When exactly are flash external callback methods triggered ?
Posted
by felace
on Stack Overflow
See other posts from Stack Overflow
or by felace
Published on 2010-06-06T16:38:40Z
Indexed on
2010/06/06
16:42 UTC
Read the original article
Hit count: 317
JavaScript
|flash
I have a flash application using callbacks to javascript functions (eg. when it receives some data over a socket, it'll call a js script which would change the content of a div according to that given data).
Afaik, there is no actual mutual exclusion in javascript so I'm not sure if I can/need to simulate something like :
callbackFunc() {
lock(mutex1)
foo
unlock(mutex1)
}
...
someOtherFunc() {
lock(mutex1)
bar
unlock(mutex1)
}
So, the question is, when are those callbacks called ? Are they simply queued to be executed right after the browser finishes its task or are they triggered randomly ?
© Stack Overflow or respective owner