summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--chrome/common/plugin_messages_internal.h2
-rw-r--r--chrome/plugin/webplugin_proxy.cc4
-rw-r--r--chrome/plugin/webplugin_proxy.h2
-rw-r--r--chrome/renderer/webplugin_delegate_proxy.cc5
-rw-r--r--chrome/renderer/webplugin_delegate_proxy.h1
5 files changed, 14 insertions, 0 deletions
diff --git a/chrome/common/plugin_messages_internal.h b/chrome/common/plugin_messages_internal.h
index 0e59ef8..0c009a5 100644
--- a/chrome/common/plugin_messages_internal.h
+++ b/chrome/common/plugin_messages_internal.h
@@ -249,6 +249,8 @@ IPC_BEGIN_MESSAGES(PluginHost, 6)
IPC_SYNC_MESSAGE_ROUTED0_1(PluginHostMsg_GetCPBrowsingContext,
uint32 /* context */)
+ IPC_MESSAGE_ROUTED0(PluginHostMsg_CancelDocumentLoad)
+
IPC_MESSAGE_ROUTED5(PluginHostMsg_InitiateHTTPRangeRequest,
std::string /* url */,
std::string /* range_info */,
diff --git a/chrome/plugin/webplugin_proxy.cc b/chrome/plugin/webplugin_proxy.cc
index 5a94445..7ab78629 100644
--- a/chrome/plugin/webplugin_proxy.cc
+++ b/chrome/plugin/webplugin_proxy.cc
@@ -373,6 +373,10 @@ void WebPluginProxy::UpdateTransform() {
SetWorldTransform(windowless_hdc_, &xf);
}
+void WebPluginProxy::CancelDocumentLoad() {
+ Send(new PluginHostMsg_CancelDocumentLoad(route_id_));
+}
+
void WebPluginProxy::InitiateHTTPRangeRequest(const char* url,
const char* range_info,
void* existing_stream,
diff --git a/chrome/plugin/webplugin_proxy.h b/chrome/plugin/webplugin_proxy.h
index b578734..c2cefc7 100644
--- a/chrome/plugin/webplugin_proxy.h
+++ b/chrome/plugin/webplugin_proxy.h
@@ -86,6 +86,8 @@ class WebPluginProxy : public WebPlugin {
const base::SharedMemoryHandle& windowless_buffer,
const base::SharedMemoryHandle& background_buffer);
+ void CancelDocumentLoad();
+
void InitiateHTTPRangeRequest(const char* url,
const char* range_info,
void* existing_stream,
diff --git a/chrome/renderer/webplugin_delegate_proxy.cc b/chrome/renderer/webplugin_delegate_proxy.cc
index e36f024..c688817 100644
--- a/chrome/renderer/webplugin_delegate_proxy.cc
+++ b/chrome/renderer/webplugin_delegate_proxy.cc
@@ -322,6 +322,7 @@ void WebPluginDelegateProxy::OnMessageReceived(const IPC::Message& msg) {
IPC_MESSAGE_HANDLER(PluginHostMsg_URLRequest, OnHandleURLRequest)
IPC_MESSAGE_HANDLER(PluginHostMsg_GetCPBrowsingContext,
OnGetCPBrowsingContext)
+ IPC_MESSAGE_HANDLER(PluginHostMsg_CancelDocumentLoad, OnCancelDocumentLoad)
IPC_MESSAGE_HANDLER(PluginHostMsg_InitiateHTTPRangeRequest,
OnInitiateHTTPRangeRequest)
IPC_MESSAGE_UNHANDLED_ERROR()
@@ -734,6 +735,10 @@ void WebPluginDelegateProxy::URLRequestRouted(const std::string& url,
notify_data));
}
+void WebPluginDelegateProxy::OnCancelDocumentLoad() {
+ plugin_->CancelDocumentLoad();
+}
+
void WebPluginDelegateProxy::OnInitiateHTTPRangeRequest(
const std::string& url, const std::string& range_info,
HANDLE existing_stream, bool notify_needed, HANDLE notify_data) {
diff --git a/chrome/renderer/webplugin_delegate_proxy.h b/chrome/renderer/webplugin_delegate_proxy.h
index b51d07c..392682c 100644
--- a/chrome/renderer/webplugin_delegate_proxy.h
+++ b/chrome/renderer/webplugin_delegate_proxy.h
@@ -124,6 +124,7 @@ class WebPluginDelegateProxy : public WebPluginDelegate,
std::string* json_retval);
void OnMissingPluginStatus(int status);
void OnGetCPBrowsingContext(uint32* context);
+ void OnCancelDocumentLoad();
void OnInitiateHTTPRangeRequest(const std::string& url,
const std::string& range_info,
HANDLE existing_stream, bool notify_needed,