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

Side by Side Diff: android_webview/browser/aw_contents_io_thread_client_impl.h

Issue 2863233002: [WebView] Move files from native to browser (Closed)
Patch Set: Created 3 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_IO_THREAD_CLIENT_IMPL_H_ 5 #ifndef ANDROID_WEBVIEW_BROWSER_AW_CONTENTS_IO_THREAD_CLIENT_IMPL_H_
6 #define ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_IO_THREAD_CLIENT_IMPL_H_ 6 #define ANDROID_WEBVIEW_BROWSER_AW_CONTENTS_IO_THREAD_CLIENT_IMPL_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "android_webview/browser/aw_contents_io_thread_client.h" 10 #include "android_webview/browser/aw_contents_io_thread_client.h"
11 #include "base/android/scoped_java_ref.h" 11 #include "base/android/scoped_java_ref.h"
12 #include "base/compiler_specific.h" 12 #include "base/compiler_specific.h"
13 #include "base/macros.h" 13 #include "base/macros.h"
14 14
15 namespace content { 15 namespace content {
16 class WebContents; 16 class WebContents;
17 } 17 }
18 18
19 namespace net { 19 namespace net {
20 class URLRequest; 20 class URLRequest;
21 } 21 }
22 22
23 namespace android_webview { 23 namespace android_webview {
24 24
25 class AwContentsIoThreadClientImpl : public AwContentsIoThreadClient { 25 class AwContentsIoThreadClientImpl : public AwContentsIoThreadClient {
26 public: 26 public:
27 // Called when AwContents is created before there is a Java client. 27 // Called when AwContents is created before there is a Java client.
28 static void RegisterPendingContents(content::WebContents* web_contents); 28 static void RegisterPendingContents(content::WebContents* web_contents);
29 29
30 // Associates the |jclient| instance (which must implement the 30 // Associates the |jclient| instance (which must implement the
31 // AwContentsIoThreadClient Java interface) with the |web_contents|. 31 // AwContentsIoThreadClient Java interface) with the |web_contents|.
32 // This should be called at most once per |web_contents|. 32 // This should be called at most once per |web_contents|.
33 static void Associate(content::WebContents* web_contents, 33 static void Associate(content::WebContents* web_contents,
34 const base::android::JavaRef<jobject>& jclient); 34 const base::android::JavaRef<jobject>& jclient);
35 35
36 // Sets the |jclient| java instance to which service worker related 36 // Sets the |jclient| java instance to which service worker related
37 // callbacks should be delegated. 37 // callbacks should be delegated.
(...skipping 20 matching lines...) Expand all
58 bool ShouldBlockNetworkLoads() const override; 58 bool ShouldBlockNetworkLoads() const override;
59 59
60 private: 60 private:
61 bool pending_association_; 61 bool pending_association_;
62 base::android::ScopedJavaGlobalRef<jobject> java_object_; 62 base::android::ScopedJavaGlobalRef<jobject> java_object_;
63 base::android::ScopedJavaGlobalRef<jobject> bg_thread_client_object_; 63 base::android::ScopedJavaGlobalRef<jobject> bg_thread_client_object_;
64 64
65 DISALLOW_COPY_AND_ASSIGN(AwContentsIoThreadClientImpl); 65 DISALLOW_COPY_AND_ASSIGN(AwContentsIoThreadClientImpl);
66 }; 66 };
67 67
68 } // namespace android_webview 68 } // namespace android_webview
69 69
70 #endif // ANDROID_WEBVIEW_NATIVE_AW_CONTENTS_IO_THREAD_CLIENT_IMPL_H_ 70 #endif // ANDROID_WEBVIEW_BROWSER_AW_CONTENTS_IO_THREAD_CLIENT_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698