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

Unified Diff: content/renderer/web_intents_host.cc

Issue 8934011: Rename IntentsHost -> WebIntentsDispatcher and IntentsDispatcher -> WebIntentsHost. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge to head Created 9 years 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
« no previous file with comments | « content/renderer/web_intents_host.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/web_intents_host.cc
diff --git a/content/renderer/intents_dispatcher.cc b/content/renderer/web_intents_host.cc
similarity index 88%
rename from content/renderer/intents_dispatcher.cc
rename to content/renderer/web_intents_host.cc
index aeda9c77a37e7c4f8ca7deefcad1c659c7eeae8d..7d96f3d93f81e216c5a585af1757404ca9a8e345 100644
--- a/content/renderer/intents_dispatcher.cc
+++ b/content/renderer/web_intents_host.cc
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "content/renderer/intents_dispatcher.h"
+#include "content/renderer/web_intents_host.h"
#include "base/bind.h"
#include "base/bind_helpers.h"
@@ -24,12 +24,12 @@ using WebKit::WebString;
// It is made available to the Javascript runtime in the service page using
// NPAPI methods as with plugin/Javascript interaction objects and other
// browser-provided Javascript API objects on |window|.
-class IntentsDispatcher::BoundDeliveredIntent : public CppBoundClass {
+class WebIntentsHost::BoundDeliveredIntent : public CppBoundClass {
public:
BoundDeliveredIntent(const string16& action,
const string16& type,
const string16& data,
- IntentsDispatcher* parent,
+ WebIntentsHost* parent,
WebKit::WebFrame* frame) {
action_ = WebString(action).utf8();
type_ = WebString(type).utf8();
@@ -124,18 +124,18 @@ class IntentsDispatcher::BoundDeliveredIntent : public CppBoundClass {
scoped_ptr<CppVariant> data_val_;
// The dispatcher object, for forwarding postResult/postFailure calls.
- IntentsDispatcher* parent_;
+ WebIntentsHost* parent_;
};
-IntentsDispatcher::IntentsDispatcher(RenderViewImpl* render_view)
+WebIntentsHost::WebIntentsHost(RenderViewImpl* render_view)
: content::RenderViewObserver(render_view) {
}
-IntentsDispatcher::~IntentsDispatcher() {}
+WebIntentsHost::~WebIntentsHost() {}
-bool IntentsDispatcher::OnMessageReceived(const IPC::Message& message) {
+bool WebIntentsHost::OnMessageReceived(const IPC::Message& message) {
bool handled = true;
- IPC_BEGIN_MESSAGE_MAP(IntentsDispatcher, message)
+ IPC_BEGIN_MESSAGE_MAP(WebIntentsHost, message)
IPC_MESSAGE_HANDLER(IntentsMsg_SetWebIntentData, OnSetIntent)
IPC_MESSAGE_HANDLER(IntentsMsg_WebIntentReply, OnWebIntentReply);
IPC_MESSAGE_UNHANDLED(handled = false)
@@ -143,11 +143,11 @@ bool IntentsDispatcher::OnMessageReceived(const IPC::Message& message) {
return handled;
}
-void IntentsDispatcher::OnSetIntent(const webkit_glue::WebIntentData& intent) {
+void WebIntentsHost::OnSetIntent(const webkit_glue::WebIntentData& intent) {
intent_.reset(new webkit_glue::WebIntentData(intent));
}
-void IntentsDispatcher::OnWebIntentReply(
+void WebIntentsHost::OnWebIntentReply(
webkit_glue::WebIntentReplyType reply_type,
const WebKit::WebString& data,
int intent_id) {
@@ -161,12 +161,12 @@ void IntentsDispatcher::OnWebIntentReply(
}
}
-void IntentsDispatcher::OnResult(const WebKit::WebString& data) {
+void WebIntentsHost::OnResult(const WebKit::WebString& data) {
Send(new IntentsHostMsg_WebIntentReply(
routing_id(), webkit_glue::WEB_INTENT_REPLY_SUCCESS, data));
}
-void IntentsDispatcher::OnFailure(const WebKit::WebString& data) {
+void WebIntentsHost::OnFailure(const WebKit::WebString& data) {
Send(new IntentsHostMsg_WebIntentReply(
routing_id(), webkit_glue::WEB_INTENT_REPLY_FAILURE, data));
}
@@ -175,7 +175,7 @@ void IntentsDispatcher::OnFailure(const WebKit::WebString& data) {
// should persist the data through redirects, and not deliver it to any
// sub-frames. TODO(gbillock): This policy needs to be fine-tuned and
// documented.
-void IntentsDispatcher::DidClearWindowObject(WebKit::WebFrame* frame) {
+void WebIntentsHost::DidClearWindowObject(WebKit::WebFrame* frame) {
if (intent_.get() == NULL || frame->top() != frame)
return;
« no previous file with comments | « content/renderer/web_intents_host.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698