|
From: <ma...@us...> - 2011-12-12 17:23:21
|
Revision: 569
http://openautomation.svn.sourceforge.net/openautomation/?rev=569&view=rev
Author: mayerch
Date: 2011-12-12 17:23:11 +0000 (Mon, 12 Dec 2011)
Log Message:
-----------
Fix error message that is caused by the fact that the AJAX connection will be on unload canceled before(!) the .unload() event will be triggered!?!
I'm using the check suggested at http://stackoverflow.com/questions/1370322/jquery-ajax-fires-error-callback-on-window-unload
Modified Paths:
--------------
CometVisu/trunk/visu/lib/cometvisu-client.js
Modified: CometVisu/trunk/visu/lib/cometvisu-client.js
===================================================================
--- CometVisu/trunk/visu/lib/cometvisu-client.js 2011-12-12 14:05:51 UTC (rev 568)
+++ CometVisu/trunk/visu/lib/cometvisu-client.js 2011-12-12 17:23:11 UTC (rev 569)
@@ -81,7 +81,7 @@
*/
this.handleError=function(xhr,str,excptObj)
{
- if( this.running && xhr.readyState != 4 && !this.doRestart) // ignore error when connection is irrelevant
+ if( this.running && xhr.readyState != 4 && !this.doRestart && xhr.status!==0 ) // ignore error when connection is irrelevant
{
var readyState = 'UNKNOWN';
switch( xhr.readyState )
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|