Jaime Rodriguez On Windows Phone, Windows Presentation Foundation, Silverlight and Windows 7
I posted before on the "firefox unresponsive script warning" but enough people have asked off-line to warrant this attempt to explain the issue (since it is not what people expect, and can be tricky to track).
The explanation: The warning is prompted by Mozilla's heuristics to check on long running scripts (details on these heuristics way below). The problem is that for silverlight or any plug-in that makes Javascript calls, Firefox some times does not reset the timer for the scripts called from plug-ins: If you fire multiple events from a plug-in the events are obviously handled sequentially, if a new event happens while an event handler is executing, then Firefox does not reset its counter for the script time out; it measures the time from these two events as a single script.
What does this mean (by example)? :
How to get around it? So far window.setTimeout () seems to work best (though I can't say it works 100% of the time). Your mileage may vary, but here is what I do:
Overall, setTimeout is not a perfect workaround, but best I come up with so far.
---
Does the explanation above make sense??? If not, here is a practical repro of the problem, it might make it easier for people to understand.. Requirements:
Steps to repro:
To reproduce the problem using a short MouseMove handler ,
A few more details or references on Firefox and their timeout heuristics .
Firefox controls its time out based on the dom.max_script_run_time setting, which you can tweak via the about://config moniker; the default timeout in most recent versions is 10 seconds.
PingBack from http://msdnrss.thecoderblogs.com/2008/01/01/explaining-the-firefox-warning-unresponsive-script-for-silverlight-10-apps/
I guess I need to commit to posting non-submitted stuff more regular. I stopped doing that a while back
After the first few thousand times you get this warning it starts to get old. Real Old. I always thought