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

Unified Diff: content/browser/frame_host/render_frame_host_impl.cc

Issue 2734943003: Device Service: Decouple Wake Lock from //content (Closed)
Patch Set: Rebase Created 3 years, 9 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/frame_host/render_frame_host_impl.cc
diff --git a/content/browser/frame_host/render_frame_host_impl.cc b/content/browser/frame_host/render_frame_host_impl.cc
index 1043df3be56ae3082508965a1bec685131fbfc53..b04daf76b905695673f7ab8c63a08d4539363069 100644
--- a/content/browser/frame_host/render_frame_host_impl.cc
+++ b/content/browser/frame_host/render_frame_host_impl.cc
@@ -98,7 +98,8 @@
#include "device/generic_sensor/sensor_provider_impl.h"
#include "device/geolocation/geolocation_service_context.h"
#include "device/vr/features.h"
-#include "device/wake_lock/wake_lock_service_context.h"
+#include "device/wake_lock/public/interfaces/wake_lock_context.mojom.h"
+#include "device/wake_lock/public/interfaces/wake_lock_service.mojom.h"
#include "media/base/media_switches.h"
#include "media/media_features.h"
#include "media/mojo/interfaces/media_service.mojom.h"
@@ -2440,14 +2441,14 @@ void RenderFrameHostImpl::RegisterMojoInterfaces() {
base::Unretained(geolocation_service_context)));
}
- device::WakeLockServiceContext* wake_lock_service_context =
+ device::mojom::WakeLockContext* wake_lock_service_context =
delegate_ ? delegate_->GetWakeLockServiceContext() : nullptr;
if (wake_lock_service_context) {
// WakeLockServiceContext is owned by WebContentsImpl so it will outlive
// this RenderFrameHostImpl, hence a raw pointer can be bound to service
// factory callback.
GetInterfaceRegistry()->AddInterface<device::mojom::WakeLockService>(
- base::Bind(&device::WakeLockServiceContext::CreateService,
+ base::Bind(&device::mojom::WakeLockContext::GetWakeLock,
base::Unretained(wake_lock_service_context)));
}
« no previous file with comments | « content/browser/frame_host/render_frame_host_delegate.cc ('k') | content/browser/service_manager/service_manager_context.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698