2020-06-28 23:05:36 +02:00
|
|
|
// Copyright 2015 The Chromium Embedded Framework Authors.
|
|
|
|
// Portions copyright 2014 The Chromium Authors. All rights reserved.
|
|
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
|
|
// found in the LICENSE file.
|
|
|
|
|
2024-04-30 17:45:07 +02:00
|
|
|
#include "cef/libcef/common/chrome/chrome_content_client_cef.h"
|
2020-06-28 23:05:36 +02:00
|
|
|
|
2024-04-30 17:45:07 +02:00
|
|
|
#include "cef/libcef/common/app_manager.h"
|
2022-10-04 21:54:13 +02:00
|
|
|
#include "chrome/common/media/cdm_registration.h"
|
|
|
|
|
|
|
|
#if BUILDFLAG(ENABLE_CDM_HOST_VERIFICATION)
|
2024-04-30 17:45:07 +02:00
|
|
|
#include "cef/libcef/common/cdm_host_file_path.h"
|
2022-10-04 21:54:13 +02:00
|
|
|
#endif
|
|
|
|
|
2020-06-28 23:05:36 +02:00
|
|
|
ChromeContentClientCef::ChromeContentClientCef() = default;
|
|
|
|
ChromeContentClientCef::~ChromeContentClientCef() = default;
|
|
|
|
|
2022-10-04 21:54:13 +02:00
|
|
|
void ChromeContentClientCef::AddContentDecryptionModules(
|
|
|
|
std::vector<content::CdmInfo>* cdms,
|
|
|
|
std::vector<media::CdmHostFilePath>* cdm_host_file_paths) {
|
2023-01-02 23:59:03 +01:00
|
|
|
if (cdms) {
|
2022-10-04 21:54:13 +02:00
|
|
|
RegisterCdmInfo(cdms);
|
2023-01-02 23:59:03 +01:00
|
|
|
}
|
2022-10-04 21:54:13 +02:00
|
|
|
|
|
|
|
#if BUILDFLAG(ENABLE_CDM_HOST_VERIFICATION)
|
2023-01-02 23:59:03 +01:00
|
|
|
if (cdm_host_file_paths) {
|
2022-10-04 21:54:13 +02:00
|
|
|
cef::AddCdmHostFilePaths(cdm_host_file_paths);
|
2023-01-02 23:59:03 +01:00
|
|
|
}
|
2022-10-04 21:54:13 +02:00
|
|
|
#endif
|
|
|
|
}
|
|
|
|
|
2020-06-28 23:05:36 +02:00
|
|
|
void ChromeContentClientCef::AddAdditionalSchemes(Schemes* schemes) {
|
|
|
|
ChromeContentClient::AddAdditionalSchemes(schemes);
|
|
|
|
CefAppManager::Get()->AddAdditionalSchemes(schemes);
|
|
|
|
}
|