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

Unified Diff: device/wake_lock/wake_lock_service_impl.cc

Issue 2867303003: Generalize the API of WakeLockContext mojo interface. (Closed)
Patch Set: Created 3 years, 7 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: device/wake_lock/wake_lock_service_impl.cc
diff --git a/device/wake_lock/wake_lock_service_impl.cc b/device/wake_lock/wake_lock_service_impl.cc
index 6e1571806cb7d185afabe6c7f05e679defa165a7..83fc8e5b03a8999c4aa727fc50484419537889ac 100644
--- a/device/wake_lock/wake_lock_service_impl.cc
+++ b/device/wake_lock/wake_lock_service_impl.cc
@@ -88,14 +88,6 @@ void WakeLockServiceImpl::UpdateWakeLock() {
void WakeLockServiceImpl::CreateWakeLock() {
DCHECK(!wake_lock_);
- if (type_ != device::PowerSaveBlocker::kPowerSaveBlockPreventDisplaySleep ||
- reason_ != device::PowerSaveBlocker::kReasonOther ||
- *description_ != "Wake Lock API") {
- // TODO(ke.he@intel.com): Fully generalize the WakeLock interface and impl.
- NOTREACHED();
- return;
- }
-
wake_lock_ = base::MakeUnique<device::PowerSaveBlocker>(
type_, reason_, *description_, main_task_runner_, file_task_runner_);

Powered by Google App Engine
This is Rietveld 408576698