Pin Chrome's shortcut to the Win10 Start menu on install and OS upgrade.
[chromium-blink-merge.git] / content / public / common / pepper_plugin_info.cc
blob018bf183103bab75d393f7984f2050aa058d67f0
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "content/public/common/pepper_plugin_info.h"
7 #include "base/strings/utf_string_conversions.h"
9 namespace content {
11 PepperPluginInfo::EntryPoints::EntryPoints()
12 : get_interface(NULL),
13 initialize_module(NULL),
14 shutdown_module(NULL) {
17 PepperPluginInfo::PepperPluginInfo()
18 : is_internal(false),
19 is_out_of_process(false),
20 permissions(0) {
23 PepperPluginInfo::~PepperPluginInfo() {
26 WebPluginInfo PepperPluginInfo::ToWebPluginInfo() const {
27 WebPluginInfo info;
29 info.type = is_out_of_process ?
30 WebPluginInfo::PLUGIN_TYPE_PEPPER_OUT_OF_PROCESS :
31 WebPluginInfo::PLUGIN_TYPE_PEPPER_IN_PROCESS;
33 info.name = name.empty() ?
34 path.BaseName().LossyDisplayName() : base::UTF8ToUTF16(name);
35 info.path = path;
36 info.version = base::ASCIIToUTF16(version);
37 info.desc = base::ASCIIToUTF16(description);
38 info.mime_types = mime_types;
39 info.pepper_permissions = permissions;
41 return info;
44 } // namespace content