summaryrefslogtreecommitdiffstats
path: root/chrome/plugin/webplugin_proxy.cc
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-07-08 21:40:55 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-07-08 21:40:55 +0000
commitef9162785c55957324e72f737bb9b6b2406053dd (patch)
treed8c4b934a957eff37caffa911c91066fe27e04fb /chrome/plugin/webplugin_proxy.cc
parent9e6f8526f9a60410b6d448103a9015d72a067deb (diff)
downloadchromium_src-ef9162785c55957324e72f737bb9b6b2406053dd.zip
chromium_src-ef9162785c55957324e72f737bb9b6b2406053dd.tar.gz
chromium_src-ef9162785c55957324e72f737bb9b6b2406053dd.tar.bz2
Add the page url to plugin crashes to aid debugging.
Review URL: http://codereview.chromium.org/155238 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@20191 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/plugin/webplugin_proxy.cc')
-rw-r--r--chrome/plugin/webplugin_proxy.cc21
1 files changed, 12 insertions, 9 deletions
diff --git a/chrome/plugin/webplugin_proxy.cc b/chrome/plugin/webplugin_proxy.cc
index 3d6a6ac..b2fe778 100644
--- a/chrome/plugin/webplugin_proxy.cc
+++ b/chrome/plugin/webplugin_proxy.cc
@@ -13,6 +13,7 @@
#include "base/singleton.h"
#include "base/waitable_event.h"
#include "build/build_config.h"
+#include "chrome/common/child_process_logging.h"
#include "chrome/common/plugin_messages.h"
#include "chrome/common/url_constants.h"
#include "chrome/plugin/npobject_proxy.h"
@@ -35,7 +36,8 @@ static ContextMap& GetContextMap() {
WebPluginProxy::WebPluginProxy(
PluginChannel* channel,
int route_id,
- WebPluginDelegate* delegate)
+ WebPluginDelegate* delegate,
+ const GURL& page_url)
: channel_(channel),
route_id_(route_id),
cp_browsing_context_(0),
@@ -43,6 +45,7 @@ WebPluginProxy::WebPluginProxy(
plugin_element_(NULL),
delegate_(delegate),
waiting_for_paint_(false),
+ page_url_(page_url),
ALLOW_THIS_IN_INITIALIZER_LIST(runnable_method_factory_(this))
{
}
@@ -159,10 +162,9 @@ NPObject* WebPluginProxy::GetWindowScriptNPObject() {
if (!success)
return NULL;
- window_npobject_ = NPObjectProxy::Create(channel_,
- npobject_route_id,
- npobject_ptr,
- modal_dialog_event_.get());
+ window_npobject_ = NPObjectProxy::Create(
+ channel_, npobject_route_id, npobject_ptr, modal_dialog_event_.get(),
+ page_url_);
return window_npobject_;
}
@@ -179,10 +181,9 @@ NPObject* WebPluginProxy::GetPluginElement() {
if (!success)
return NULL;
- plugin_element_ = NPObjectProxy::Create(channel_,
- npobject_route_id,
- npobject_ptr,
- modal_dialog_event_.get());
+ plugin_element_ = NPObjectProxy::Create(
+ channel_, npobject_route_id, npobject_ptr, modal_dialog_event_.get(),
+ page_url_);
return plugin_element_;
}
@@ -518,6 +519,8 @@ void WebPluginProxy::InitiateHTTPRangeRequest(const char* url,
}
void WebPluginProxy::OnPaint(const gfx::Rect& damaged_rect) {
+ child_process_logging::ScopedActiveURLSetter url_setter(page_url_);
+
Paint(damaged_rect);
Send(new PluginHostMsg_InvalidateRect(route_id_, damaged_rect));
}