Chromium Code Reviews| Index: android_webview/renderer/aw_message_port_client.h |
| diff --git a/android_webview/renderer/aw_message_port_client.h b/android_webview/renderer/aw_message_port_client.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..78c64f0a87adb21be3af45f77fcb0183a8363a91 |
| --- /dev/null |
| +++ b/android_webview/renderer/aw_message_port_client.h |
| @@ -0,0 +1,35 @@ |
| +// Copyright 2014 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef ANDROID_WEBVIEW_RENDERER_AW_MESSAGE_PORT_CLIENT_H_ |
| +#define ANDROID_WEBVIEW_RENDERER_AW_MESSAGE_PORT_CLIENT_H_ |
| + |
| +#include <vector> |
| + |
| +#include "base/strings/string16.h" |
| +#include "content/public/renderer/render_frame_observer.h" |
| + |
| +namespace android_webview { |
| + |
| +// Renderer side of Android webview specific message port service. This service |
| +// is used to convert messages from WebSerializedScriptValue to a base value. |
| +class AwMessagePortClient : public content::RenderFrameObserver { |
| + public: |
| + explicit AwMessagePortClient(content::RenderFrame* render_frame); |
| + |
| + private: |
| + virtual ~AwMessagePortClient(); |
| + |
| + // RenderFrame::Observer |
|
mnaganov (inactive)
2015/01/07 11:43:54
RenderFrameObserver
sgurun-gerrit only
2015/01/10 02:36:29
Done.
|
| + bool OnMessageReceived(const IPC::Message& message) override; |
| + |
| + void OnPostMessage(int message_port_id, |
| + const base::string16& message, |
| + const std::vector<int>& sent_message_port_ids); |
| + DISALLOW_COPY_AND_ASSIGN(AwMessagePortClient); |
| +}; |
| + |
| +} |
| + |
| +#endif // ANDROID_WEBVIEW_RENDERER_AW_MESSAGE_PORT_CLIENT_H_ |