mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Persist media device IDs across navigation and restart (fixes issue #2064)
Media device IDs will now be persisted across navigation and reload by default. The device IDs will also be persisted across restart if --cache-path=<path> and --persist-user-preferences settings are specified.
This commit is contained in:
@@ -21,6 +21,7 @@
|
||||
#include "base/logging.h"
|
||||
#include "base/strings/string_util.h"
|
||||
#include "chrome/browser/font_family_cache.h"
|
||||
#include "chrome/browser/media/media_device_id_salt.h"
|
||||
#include "chrome/browser/plugins/chrome_plugin_service_filter.h"
|
||||
#include "chrome/browser/profiles/profile_key.h"
|
||||
#include "chrome/browser/ui/zoom/chrome_zoom_level_prefs.h"
|
||||
@@ -168,6 +169,8 @@ void AlloyBrowserContext::Initialize() {
|
||||
extension_system_->Init();
|
||||
|
||||
ChromePluginServiceFilter::GetInstance()->RegisterProfile(this);
|
||||
|
||||
media_device_id_salt_ = new MediaDeviceIDSalt(pref_service);
|
||||
}
|
||||
|
||||
void AlloyBrowserContext::Shutdown() {
|
||||
@@ -397,6 +400,10 @@ AlloyBrowserContext::GetBrowsingDataRemoverDelegate() {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
std::string AlloyBrowserContext::GetMediaDeviceIDSalt() {
|
||||
return media_device_id_salt_->GetSalt();
|
||||
}
|
||||
|
||||
PrefService* AlloyBrowserContext::GetPrefs() {
|
||||
return pref_service_.get();
|
||||
}
|
||||
|
Reference in New Issue
Block a user