mirror of
https://github.com/apache/cordova-android.git
synced 2026-05-11 00:00:05 +08:00
Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 909e6645e7 | |||
| a308100288 | |||
| fea8c5d204 | |||
| a890c8156e | |||
| 665c1bd8bb |
@@ -1,8 +1,8 @@
|
||||
// Platform: android
|
||||
|
||||
// commit 360bd3e65c33ce4f01e2efb82d641a565ef3c333
|
||||
// commit cd29cf0f224ccf25e9d422a33fd02ef67d3a78f4
|
||||
|
||||
// File generated at :: Fri Apr 19 2013 17:55:18 GMT-0700 (PDT)
|
||||
// File generated at :: Thu Apr 25 2013 14:53:10 GMT-0700 (PDT)
|
||||
|
||||
/*
|
||||
Licensed to the Apache Software Foundation (ASF) under one
|
||||
@@ -6813,7 +6813,7 @@ require('cordova/channel').onNativeReady.fire();
|
||||
xhr.onload = function() {
|
||||
// If the response is a JSON string which composes an array, call handlePluginsObject.
|
||||
// If the request fails, or the response is not a JSON array, just call finishPluginLoading.
|
||||
var obj = JSON.parse(this.responseText);
|
||||
var obj = this.responseText && JSON.parse(this.responseText);
|
||||
if (obj && obj instanceof Array && obj.length > 0) {
|
||||
handlePluginsObject(obj);
|
||||
} else {
|
||||
|
||||
@@ -43,13 +43,12 @@ public class IceCreamCordovaWebViewClient extends CordovaWebViewClient {
|
||||
|
||||
@Override
|
||||
public WebResourceResponse shouldInterceptRequest(WebView view, String url) {
|
||||
if(url.contains("?") || url.contains("#") || needsIceCreamSpaceInAssetUrlFix(url)){
|
||||
WebResourceResponse ret = generateWebResourceResponse(url);
|
||||
if (ret != null) {
|
||||
return ret;
|
||||
}
|
||||
//Check if plugins intercept the request
|
||||
WebResourceResponse ret = super.shouldInterceptRequest(view, url);
|
||||
if(ret == null && (url.contains("?") || url.contains("#") || needsIceCreamSpaceInAssetUrlFix(url))){
|
||||
ret = generateWebResourceResponse(url);
|
||||
}
|
||||
return super.shouldInterceptRequest(view, url);
|
||||
return ret;
|
||||
}
|
||||
|
||||
private WebResourceResponse generateWebResourceResponse(String url) {
|
||||
|
||||
Reference in New Issue
Block a user