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

Unified Diff: chrome/browser/profiles/profile_impl.cc

Issue 2820163002: Move MediaDeviceIDSalt from ProfileIOData to ProfileImpl. (Closed)
Patch Set: Fix Created 3 years, 8 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/browser/profiles/profile_impl.cc
diff --git a/chrome/browser/profiles/profile_impl.cc b/chrome/browser/profiles/profile_impl.cc
index 0e6340d54882e17307f2bf2a0251ccfcbf8fdbcb..ac2db17de265d15c48f8a32048b00aaed1398f50 100644
--- a/chrome/browser/profiles/profile_impl.cc
+++ b/chrome/browser/profiles/profile_impl.cc
@@ -44,6 +44,7 @@
#include "chrome/browser/download/chrome_download_manager_delegate.h"
#include "chrome/browser/download/download_service.h"
#include "chrome/browser/download/download_service_factory.h"
+#include "chrome/browser/media/media_device_id_salt.h"
#include "chrome/browser/net/predictor.h"
#include "chrome/browser/net/proxy_service_factory.h"
#include "chrome/browser/permissions/permission_manager.h"
@@ -565,6 +566,8 @@ void ProfileImpl::DoFinalInit() {
base::Bind(&ProfileImpl::UpdateIsEphemeralInStorage,
base::Unretained(this)));
+ media_device_id_salt_ = new MediaDeviceIDSalt(prefs_.get());
+
// It would be nice to use PathService for fetching this directory, but
// the cache directory depends on the profile directory, which isn't available
// to PathService.
@@ -1096,6 +1099,10 @@ void ProfileImpl::RegisterInProcessServices(StaticServiceMap* services) {
std::make_pair(identity::mojom::kServiceName, identity_service_info));
}
+std::string ProfileImpl::GetMediaDeviceIDSalt() {
+ return media_device_id_salt_->GetSalt();
+}
+
bool ProfileImpl::IsSameProfile(Profile* profile) {
if (profile == static_cast<Profile*>(this))
return true;

Powered by Google App Engine
This is Rietveld 408576698