cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From purplecabb...@apache.org
Subject [19/50] [abbrv] git commit: merge issue
Date Fri, 01 Nov 2013 01:27:14 GMT
merge issue


Project: http://git-wip-us.apache.org/repos/asf/cordova-wp8/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-wp8/commit/9976c025
Tree: http://git-wip-us.apache.org/repos/asf/cordova-wp8/tree/9976c025
Diff: http://git-wip-us.apache.org/repos/asf/cordova-wp8/diff/9976c025

Branch: refs/heads/2.9.x
Commit: 9976c0258e1f8996660f748219d95cbefb4cb781
Parents: d62ca3a 84c1395
Author: purplecabbage <purplecabbage@gmail.com>
Authored: Thu Sep 12 18:18:17 2013 -0700
Committer: purplecabbage <purplecabbage@gmail.com>
Committed: Thu Sep 12 18:18:17 2013 -0700

----------------------------------------------------------------------
 wp8/template/cordovalib/XHRHelper.cs | 17 ++++++++++-------
 1 file changed, 10 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-wp8/blob/9976c025/wp8/template/cordovalib/XHRHelper.cs
----------------------------------------------------------------------
diff --cc wp8/template/cordovalib/XHRHelper.cs
index 027cab3,35b8bd3..45c31ea
--- a/wp8/template/cordovalib/XHRHelper.cs
+++ b/wp8/template/cordovalib/XHRHelper.cs
@@@ -30,7 -30,7 +30,7 @@@ namespace WPCordovaClassLib.CordovaLi
      if (!docDomain || docDomain.length === 0) {
  
          var aliasXHR = win.XMLHttpRequest;
--        
++
          var XHRShim = function() {};
          win.XMLHttpRequest = XHRShim;
          XHRShim.noConflict = aliasXHR;
@@@ -48,7 -48,7 +48,7 @@@
              withCredentials: false,
              _requestHeaders: null,
              open: function (reqType, uri, isAsync, user, password) {
--                
++
                  if (uri && uri.indexOf('http') === 0) {
                      if (!this.wrappedXHR) {
                          this.wrappedXHR = new aliasXHR();
@@@ -158,14 -158,15 +158,15 @@@
              send: function(data) {
                  if (this.wrappedXHR) {
                      return this.wrappedXHR.send(data);
--                } 
++                }
                  else {
                      this.changeReadyState(XHRShim.OPENED);
                      var alias = this;
 -                    var root = window.location.href; 
++
 +                    var root = window.location.href.split('#')[0];   // remove hash
                      var basePath = root.substr(0,root.lastIndexOf('/')) + '/';
--                    
+ 
 -                    var resolvedUrl = this._url.split('//').join('/');
 +                    var resolvedUrl = this._url.split('//').join('/').split('#')[0]; //
remove hash
  
                      var wwwFolderPath = navigator.userAgent.indexOf('MSIE 9.0') > -1
? 'app/www/' : 'www/';
  
@@@ -175,6 -178,7 +176,7 @@@
                      }
  
                      if( resolvedUrl.indexOf('app/www') == 0 ) {
 -                        
++
                          resolvedUrl = window.location.protocol  + wwwFolderPath + resolvedUrl.substr(7);
                      }
                      else if( resolvedUrl.indexOf('www') == 0) {
@@@ -197,10 -205,10 +200,10 @@@
  
                              alias.changeReadyState(XHRShim.DONE);
                              alias.onload && alias.onload();
--                            
++
                          }
                          alias.changeReadyState(XHRShim.LOADING);
--                        window.external.Notify('XHRLOCAL/' + resolvedUrl); 
++                        window.external.Notify('XHRLOCAL/' + resolvedUrl);
                      }
                      if (this.isAsync) {
                          setTimeout(funk, 0);
@@@ -246,7 -254,7 +249,7 @@@
  
                  if (resource == null)
                  {
--                    // 404 ? 
++                    // 404 ?
                      Browser.InvokeScript("__onXHRLocalCallback", new string[] { "404" });
                      return true;
                  }


Mime
View raw message