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

Unified Diff: chrome/renderer/render_view.cc

Issue 194079: renderer process notifications support (Closed)
Patch Set: last change for code review Created 11 years, 3 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: chrome/renderer/render_view.cc
diff --git a/chrome/renderer/render_view.cc b/chrome/renderer/render_view.cc
index 2861d9c0197fa4e522c050a7d7199ee96a3d0638..8be991e90d51563b429d24d1662538009e62aff8 100644
--- a/chrome/renderer/render_view.cc
+++ b/chrome/renderer/render_view.cc
@@ -45,6 +45,7 @@
#include "chrome/renderer/localized_error.h"
#include "chrome/renderer/media/audio_renderer_impl.h"
#include "chrome/renderer/navigation_state.h"
+#include "chrome/renderer/notification_provider.h"
#include "chrome/renderer/plugin_channel_host.h"
#include "chrome/renderer/print_web_view_helper.h"
#include "chrome/renderer/render_process.h"
@@ -252,6 +253,7 @@ RenderView::~RenderView() {
#endif
render_thread_->RemoveFilter(audio_message_filter_);
+ render_thread_->RemoveFilter(notification_provider_.get());
}
/*static*/
@@ -312,6 +314,8 @@ void RenderView::Init(gfx::NativeViewId parent_hwnd,
devtools_agent_.reset(new DevToolsAgent(routing_id, this));
+ notification_provider_ = new NotificationProvider(this);
+
webwidget_ = WebView::Create(this);
webkit_preferences_.Apply(webview());
webview()->InitializeMainFrame(this);
@@ -344,6 +348,7 @@ void RenderView::Init(gfx::NativeViewId parent_hwnd,
audio_message_filter_ = new AudioMessageFilter(routing_id_);
render_thread_->AddFilter(audio_message_filter_);
+ render_thread_->AddFilter(notification_provider_.get());
}
void RenderView::OnMessageReceived(const IPC::Message& message) {

Powered by Google App Engine
This is Rietveld 408576698