2014-10-31 18:17:05 +00:00
|
|
|
// Copyright (c) 2014 GitHub, Inc.
|
2014-08-27 12:48:49 +00:00
|
|
|
// Use of this source code is governed by the MIT license that can be
|
|
|
|
// found in the LICENSE file.
|
|
|
|
|
2020-02-04 20:19:40 +00:00
|
|
|
#ifndef SHELL_APP_ELECTRON_CONTENT_CLIENT_H_
|
|
|
|
#define SHELL_APP_ELECTRON_CONTENT_CLIENT_H_
|
2014-08-27 12:48:49 +00:00
|
|
|
|
2014-08-27 13:16:45 +00:00
|
|
|
#include <vector>
|
|
|
|
|
2019-08-24 01:14:23 +00:00
|
|
|
#include "base/files/file_path.h"
|
2018-10-22 17:04:23 +00:00
|
|
|
#include "content/public/common/content_client.h"
|
2014-08-27 12:48:49 +00:00
|
|
|
|
2019-06-19 21:23:04 +00:00
|
|
|
namespace electron {
|
2014-08-27 12:48:49 +00:00
|
|
|
|
2020-02-04 20:19:40 +00:00
|
|
|
class ElectronContentClient : public content::ContentClient {
|
2014-08-27 12:48:49 +00:00
|
|
|
public:
|
2020-02-04 20:19:40 +00:00
|
|
|
ElectronContentClient();
|
|
|
|
~ElectronContentClient() override;
|
2014-08-27 12:48:49 +00:00
|
|
|
|
|
|
|
protected:
|
|
|
|
// content::ContentClient:
|
2021-03-16 16:18:45 +00:00
|
|
|
std::u16string GetLocalizedString(int message_id) override;
|
2019-07-03 01:22:09 +00:00
|
|
|
base::StringPiece GetDataResource(int resource_id, ui::ScaleFactor) override;
|
|
|
|
gfx::Image& GetNativeImageNamed(int resource_id) override;
|
|
|
|
base::RefCountedMemory* GetDataResourceBytes(int resource_id) override;
|
2017-04-04 04:50:44 +00:00
|
|
|
void AddAdditionalSchemes(Schemes* schemes) override;
|
2015-04-28 15:45:58 +00:00
|
|
|
void AddPepperPlugins(
|
|
|
|
std::vector<content::PepperPluginInfo>* plugins) override;
|
2018-04-12 15:20:00 +00:00
|
|
|
void AddContentDecryptionModules(
|
|
|
|
std::vector<content::CdmInfo>* cdms,
|
|
|
|
std::vector<media::CdmHostFilePath>* cdm_host_file_paths) override;
|
2014-08-27 12:48:49 +00:00
|
|
|
|
|
|
|
private:
|
2020-02-04 20:19:40 +00:00
|
|
|
DISALLOW_COPY_AND_ASSIGN(ElectronContentClient);
|
2014-08-27 12:48:49 +00:00
|
|
|
};
|
|
|
|
|
2019-06-19 21:23:04 +00:00
|
|
|
} // namespace electron
|
2014-08-27 12:48:49 +00:00
|
|
|
|
2020-02-04 20:19:40 +00:00
|
|
|
#endif // SHELL_APP_ELECTRON_CONTENT_CLIENT_H_
|