Is there a way to make a task regular? According to the
documentation, you just have to set the immediate property of the
function to 1 so the Task will be executed in the high priority
thread, but with the example bellow, it reports 1 instead of 0.
If I call the Task from a high priority message, it doesn't change
anything. Am I forgetting something?
PS: this is on a mac, with latest versions of everything...
--------- save as highpriority.js ---------
var myTask = new Task(click, this);
myTask.interval = 100;
post("start is in the thread", max.mainthread, "n");
start.immediate = 1;
post("task is in the thread", max.mainthread, "n");
click.immediate = 1;