Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1495)

Unified Diff: android_webview/native/aw_contents_io_thread_client_impl.h

Issue 1350553005: [Android WebView] Call shouldInterceptRequest on a background thread (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Moved code a bit Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: android_webview/native/aw_contents_io_thread_client_impl.h
diff --git a/android_webview/native/aw_contents_io_thread_client_impl.h b/android_webview/native/aw_contents_io_thread_client_impl.h
index 97ba3146091604596ff47d6a80fdd61ac7726384..01d8747b1405c3f69deea97ddd1414c9da0c7bac 100644
--- a/android_webview/native/aw_contents_io_thread_client_impl.h
+++ b/android_webview/native/aw_contents_io_thread_client_impl.h
@@ -47,8 +47,9 @@ class AwContentsIoThreadClientImpl : public AwContentsIoThreadClient {
// Implementation of AwContentsIoThreadClient.
bool PendingAssociation() const override;
CacheMode GetCacheMode() const override;
- scoped_ptr<AwWebResourceResponse> ShouldInterceptRequest(
- const net::URLRequest* request) override;
+ void ShouldInterceptRequestAsync(
+ const net::URLRequest* request,
+ const ShouldInterceptRequestResultCallback callback) override;
bool ShouldBlockContentUrls() const override;
bool ShouldBlockFileUrls() const override;
bool ShouldAcceptThirdPartyCookies() const override;
@@ -69,6 +70,7 @@ class AwContentsIoThreadClientImpl : public AwContentsIoThreadClient {
private:
bool pending_association_;
base::android::ScopedJavaGlobalRef<jobject> java_object_;
+ base::android::ScopedJavaGlobalRef<jobject> bg_thread_client_object_;
boliu 2015/10/01 19:13:56 Sorry.. just noticed this will prevent AwContents
mnaganov (inactive) 2015/10/01 19:51:04 The lifetime and properties of BackgroundThreadCli
DISALLOW_COPY_AND_ASSIGN(AwContentsIoThreadClientImpl);
};

Powered by Google App Engine
This is Rietveld 408576698