X-Git-Url: http://git.osdn.jp/view?a=blobdiff_plain;f=0.6.x%2Fjs%2F06_net%2F05_XXHRGadget.js;h=9b89fdc04ab2ff78e8e9402ee5e9fc8a47db9ce5;hb=1ed2190f012cf923f7e48d3c0d122aa56c56c5f3;hp=16d83be6332245adf1bbc35e47232bc111199fb1;hpb=a3d03e96ad8c0392ef683eb6c64421e094b96958;p=pettanr%2FclientJs.git diff --git a/0.6.x/js/06_net/05_XXHRGadget.js b/0.6.x/js/06_net/05_XXHRGadget.js index 16d83be..9b89fdc 100644 --- a/0.6.x/js/06_net/05_XXHRGadget.js +++ b/0.6.x/js/06_net/05_XXHRGadget.js @@ -31,8 +31,6 @@ var X_NET_GIMR_canUse = 5.5 <= X_UA[ 'IE' ] || !X_UA[ 'IE' ], // https://code.google.com/p/xssinterface/source/browse/trunk/js/xssinterface.js X_NET_GIMR_maxQueryLength = X_UA[ 'IE' ] ? 2000 : 6000, - X_NET_GIMR_detection = new Function( 'f,j,i', 'for(j=f.length;j;)try{i=f[--j];return i.location.hash}catch(e){}' ), - X_NET_GIMR_requestBatches, X_NET_GIMR_requestOriginal, @@ -48,13 +46,15 @@ var X_NET_GIMR_canUse = 5.5 <= X_UA[ 'IE' ] || !X_UA[ 'IE' ], function X_NET_GIMR_detectImageOverIframe(){ var raw = this[ '_rawObject' ], - iwin, ret, n; + iwin, ret, i, n; if( raw ){ iwin = raw.contentWindow || ( raw.contentDocument && raw.contentDocument.parentWindow ) || window.frames[ X_NET_GIMR_iframeName ]; - if( iwin && iwin.frames && iwin.frames.length ){ - ret = X_NET_GIMR_detection( iwin.frames ); + if( iwin && iwin.frames && ( i = iwin.frames.length ) ){ + for( ; i; ){ + if( ret = X_Script_try( X_Object_find, [ iwin.frames[ --i ], 'location.hash' ] ) ) break; + }; if( ret && ret !== X_NET_GIMR_lastHashString ){ X_NET_GIMR_lastHashString = ret; //console.log( ret.length );