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

Side by Side Diff: content/public/browser/android/app_web_message_port_service.h

Issue 2375133002: Move MessagePort implementation from android_webview to content (Closed)
Patch Set: rsesek nits and git cl format Created 4 years, 2 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
« no previous file with comments | « content/public/browser/BUILD.gn ('k') | content/public/browser/message_port_provider.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_BROWSER_AW_MESSAGE_PORT_SERVICE_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_ANDROID_APP_WEB_MESSAGE_PORT_SERVICE_H_
6 #define ANDROID_WEBVIEW_BROWSER_AW_MESSAGE_PORT_SERVICE_H_ 6 #define CONTENT_PUBLIC_BROWSER_ANDROID_APP_WEB_MESSAGE_PORT_SERVICE_H_
7 7
8 #include <jni.h>
8 #include <vector> 9 #include <vector>
9 10
10 #include "base/values.h" 11 #include "base/values.h"
11 12
12 namespace android_webview { 13 namespace content {
14 class WebContents;
13 15
14 class AwMessagePortMessageFilter; 16 // The interface for AppWebMessagePortService
17 class AppWebMessagePortService {
18 public:
19 virtual ~AppWebMessagePortService() {}
15 20
16 // The interface for AwMessagePortService 21 virtual void CreateMessageChannel(JNIEnv* env,
17 class AwMessagePortService { 22 jobjectArray ports,
18 public: 23 WebContents* web_contents) = 0;
19 virtual ~AwMessagePortService() { }
20
21 virtual void OnConvertedWebToAppMessage(
22 int message_port_id,
23 const base::ListValue& message,
24 const std::vector<int>& sent_message_port_ids) = 0;
25
26 virtual void OnMessagePortMessageFilterClosing(
27 AwMessagePortMessageFilter* filter) = 0;
28 24
29 virtual void CleanupPort(int message_port_id) = 0; 25 virtual void CleanupPort(int message_port_id) = 0;
30 }; 26 };
31 27
32 } // namespace android_webview 28 } // namespace content
33 29
34 #endif // ANDROID_WEBVIEW_BROWSER_AW_MESSAGE_PORT_SERVICE_H_ 30 #endif // CONTENT_PUBLIC_BROWSER_ANDROID_APP_WEB_MESSAGE_PORT_SERVICE_H_
OLDNEW
« no previous file with comments | « content/public/browser/BUILD.gn ('k') | content/public/browser/message_port_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698