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

Unified Diff: content/renderer/battery_status/battery_status_dispatcher.cc

Issue 833983002: Stop using [Client=...] feature of Mojom for BatteryMonitor (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fixup content integration tests Created 5 years, 12 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/renderer/battery_status/battery_status_dispatcher.cc
diff --git a/content/renderer/battery_status/battery_status_dispatcher.cc b/content/renderer/battery_status/battery_status_dispatcher.cc
index e7496113d7edd18bc6b9cb7199d605ba21da6af4..5eff04f01d29b76061bda26b8559d7f7ce709ddf 100644
--- a/content/renderer/battery_status/battery_status_dispatcher.cc
+++ b/content/renderer/battery_status/battery_status_dispatcher.cc
@@ -12,11 +12,15 @@ namespace content {
BatteryStatusDispatcher::BatteryStatusDispatcher(
blink::WebBatteryStatusListener* listener)
- : listener_(listener) {
+ : binding_(this),
+ listener_(listener) {
DCHECK(listener_);
RenderThread::Get()->GetServiceRegistry()->ConnectToRemoteService(&monitor_);
jamesr 2015/01/05 23:33:09 i'm not as familiar with content::'s service regis
- monitor_.set_client(this);
+
+ device::BatteryMonitorClientPtr proxy;
+ binding_.Bind(&proxy);
+ monitor_->SetClient(proxy.Pass());
}
BatteryStatusDispatcher::~BatteryStatusDispatcher() {

Powered by Google App Engine
This is Rietveld 408576698