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

Unified Diff: content/browser/media/webrtc/webrtc_internals.cc

Issue 2072403002: Remove content/browser/power_save_blocker_factory.* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: gyp Created 4 years, 6 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
« no previous file with comments | « content/browser/media/media_web_contents_observer.cc ('k') | content/browser/power_save_blocker_factory.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/media/webrtc/webrtc_internals.cc
diff --git a/content/browser/media/webrtc/webrtc_internals.cc b/content/browser/media/webrtc/webrtc_internals.cc
index de28bb0a14d268d71ace167a7cc2b447bfb50cd2..afce8c1c7021a0ed2560c4c1ac2213462d934453 100644
--- a/content/browser/media/webrtc/webrtc_internals.cc
+++ b/content/browser/media/webrtc/webrtc_internals.cc
@@ -9,12 +9,12 @@
#include "base/strings/string_number_conversions.h"
#include "build/build_config.h"
#include "content/browser/media/webrtc/webrtc_internals_ui_observer.h"
-#include "content/browser/power_save_blocker_factory.h"
#include "content/browser/web_contents/web_contents_view.h"
#include "content/public/browser/browser_thread.h"
#include "content/public/browser/content_browser_client.h"
#include "content/public/browser/render_process_host.h"
#include "content/public/browser/web_contents.h"
+#include "device/power_save_blocker/power_save_blocker.h"
using base::ProcessId;
using std::string;
@@ -500,10 +500,12 @@ void WebRTCInternals::CreateOrReleasePowerSaveBlocker() {
} else if (!peer_connection_data_.empty() && !power_save_blocker_) {
DVLOG(1) << ("Preventing the application from being suspended while one or "
"more PeerConnections are active.");
- power_save_blocker_ = content::CreatePowerSaveBlocker(
+ power_save_blocker_ = device::PowerSaveBlocker::CreateWithTaskRunners(
device::PowerSaveBlocker::kPowerSaveBlockPreventAppSuspension,
device::PowerSaveBlocker::kReasonOther,
- "WebRTC has active PeerConnections");
+ "WebRTC has active PeerConnections",
+ BrowserThread::GetMessageLoopProxyForThread(BrowserThread::UI),
+ BrowserThread::GetMessageLoopProxyForThread(BrowserThread::FILE));
}
}
« no previous file with comments | « content/browser/media/media_web_contents_observer.cc ('k') | content/browser/power_save_blocker_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698