lib/kissy/5.0.0-alpha.3/build/io-debug.js
function () {
            var self = this, c = self.io.config, uri = c.uri, hostname = uri.hostname, iframe, iframeUri, iframeDesc = iframeMap[hostname];
            var proxy = PROXY_PAGE;
            if (c.xdr && c.xdr.subDomain && c.xdr.subDomain.proxy) {
                proxy = c.xdr.subDomain.proxy;
            }
            if (iframeDesc && iframeDesc.ready) {
                self.nativeXhr = XhrTransportBase.nativeXhr(0, iframeDesc.iframe.contentWindow);
                if (self.nativeXhr) {
                    self.sendInternal();
                } else {
                    LoggerManager.error('document.domain not set correctly!');
                }
                return;
            }
            if (!iframeDesc) {
                iframeDesc = iframeMap[hostname] = {};
                iframe = iframeDesc.iframe = doc.createElement('iframe');
                Dom.css(iframe, {
                    position: 'absolute',
                    left: '-9999px',
                    top: '-9999px'
                });
                Dom.prepend(iframe, doc.body || doc.documentElement);
                iframeUri = {};
                iframeUri.protocol = uri.protocol;
                iframeUri.host = uri.host;
                iframeUri.pathname = proxy;
                iframe.src = url.stringify(iframeUri);
            } else {
                iframe = iframeDesc.iframe;
            }
            Event.on(iframe, 'load', _onLoad, self);
        }
function () {
            var self = this, c = self.io.config, uri = c.uri, hostname = uri.hostname, iframe, iframeUri, iframeDesc = iframeMap[hostname];
            var proxy = PROXY_PAGE;
            if (c.xdr && c.xdr.subDomain && c.xdr.subDomain.proxy) {
                proxy = c.xdr.subDomain.proxy;
            }
            if (iframeDesc && iframeDesc.ready) {
                self.nativeXhr = XhrTransportBase.nativeXhr(0, iframeDesc.iframe.contentWindow);
                if (self.nativeXhr) {
                    self.sendInternal();
                } else {
                    LoggerManager.error('document.domain not set correctly!');
                }
                return;
            }
            if (!iframeDesc) {
                iframeDesc = iframeMap[hostname] = {};
                iframe = iframeDesc.iframe = doc.createElement('iframe');
                Dom.css(iframe, {
                    position: 'absolute',
                    left: '-9999px',
                    top: '-9999px'
                });
                Dom.prepend(iframe, doc.body || doc.documentElement);
                iframeUri = {};
                iframeUri.protocol = uri.protocol;
                iframeUri.host = uri.host;
                iframeUri.pathname = proxy;
                iframe.src = url.stringify(iframeUri);
            } else {
                iframe = iframeDesc.iframe;
            }
            Event.on(iframe, 'load', _onLoad, self);
        }
function ( ) { var self = this , c = self . io . config , uri = c . uri , hostname = uri . hostname , iframe , iframeUri , iframeDesc = iframeMap [ hostname ] ; var proxy = PROXY_PAGE ; if ( c . xdr && c . xdr . subDomain && c . xdr . subDomain . proxy ) { proxy = c . xdr . subDomain . proxy ; } if ( iframeDesc && iframeDesc . ready ) { self . nativeXhr = XhrTransportBase . nativeXhr ( 0 , iframeDesc . iframe . contentWindow ) ; if ( self . nativeXhr ) { self . sendInternal ( ) ; } else { LoggerManager . error ( 'document.domain not set correctly!' ) ; } return ; } if ( ! iframeDesc ) { iframeDesc = iframeMap [ hostname ] = { } ; iframe = iframeDesc . iframe = doc . createElement ( 'iframe' ) ; Dom . css ( iframe , { position : 'absolute' , left : '-9999px' , top : '-9999px' } ) ; Dom . prepend ( iframe , doc . body || doc . documentElement ) ; iframeUri = { } ; iframeUri . protocol = uri . protocol ; iframeUri . host = uri . host ; iframeUri . pathname = proxy ; iframe . src = url . stringify ( iframeUri ) ; } else { iframe = iframeDesc . iframe ; } Event . on ( iframe , 'load' , _onLoad , self ) ; }
get nativeXhr from iframe document not from current document directly like XhrTransport
get nativeXhr from iframe document not from current document directly like XhrTransport