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

Unified Diff: content/browser/browser_plugin/browser_plugin_guest.cc

Issue 11035067: Add loadCommit and loadStop Event (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix Comments and Nits Created 8 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/browser_plugin/browser_plugin_guest.cc
diff --git a/content/browser/browser_plugin/browser_plugin_guest.cc b/content/browser/browser_plugin/browser_plugin_guest.cc
index d470801eb6667279c79734097e1488e0357222c4..bfdafb4f1fc4739dfdde35875f2e11325ed01f9c 100644
--- a/content/browser/browser_plugin/browser_plugin_guest.cc
+++ b/content/browser/browser_plugin/browser_plugin_guest.cc
@@ -383,14 +383,19 @@ void BrowserPluginGuest::DidCommitProvisionalLoadForFrame(
PageTransition transition_type,
RenderViewHost* render_view_host) {
// Inform its embedder of the updated URL.
- if (is_main_frame) {
- SendMessageToEmbedder(
- new BrowserPluginMsg_DidNavigate(
- instance_id(),
- url,
- render_view_host->GetProcess()->GetID()));
- RecordAction(UserMetricsAction("BrowserPlugin.Guest.DidNavigate"));
- }
+ SendMessageToEmbedder(
+ new BrowserPluginMsg_LoadCommit(
+ instance_id(),
+ url,
+ render_view_host->GetProcess()->GetID(),
+ is_main_frame));
+ RecordAction(UserMetricsAction("BrowserPlugin.Guest.DidNavigate"));
+}
+
+void BrowserPluginGuest::DidStopLoading(RenderViewHost* render_view_host) {
+ // Inform its embedder of loadStop.
Charlie Reis 2012/10/11 18:55:28 nit: This is clear from the code, so we don't need
irobert 2012/10/11 20:45:49 Done.
+ SendMessageToEmbedder(
+ new BrowserPluginMsg_LoadStop(instance_id()));
}
void BrowserPluginGuest::RenderViewGone(base::TerminationStatus status) {

Powered by Google App Engine
This is Rietveld 408576698