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

Side by Side Diff: content/public/common/pepper_plugin_info.cc

Issue 19894003: Move webplugininfo.h to content/public. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 7 years, 5 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/public/common/pepper_plugin_info.h" 5 #include "content/public/common/pepper_plugin_info.h"
6 6
7 #include "base/strings/utf_string_conversions.h" 7 #include "base/strings/utf_string_conversions.h"
8 8
9 namespace content { 9 namespace content {
10 10
11 PepperPluginInfo::PepperPluginInfo() 11 PepperPluginInfo::PepperPluginInfo()
12 : is_internal(false), 12 : is_internal(false),
13 is_out_of_process(false), 13 is_out_of_process(false),
14 is_sandboxed(true), 14 is_sandboxed(true),
15 permissions(0) { 15 permissions(0) {
16 } 16 }
17 17
18 PepperPluginInfo::~PepperPluginInfo() { 18 PepperPluginInfo::~PepperPluginInfo() {
19 } 19 }
20 20
21 webkit::WebPluginInfo PepperPluginInfo::ToWebPluginInfo() const { 21 WebPluginInfo PepperPluginInfo::ToWebPluginInfo() const {
22 webkit::WebPluginInfo info; 22 WebPluginInfo info;
23 23
24 info.type = is_out_of_process ? 24 info.type = is_out_of_process ?
25 (is_sandboxed ? 25 (is_sandboxed ?
26 webkit::WebPluginInfo::PLUGIN_TYPE_PEPPER_OUT_OF_PROCESS : 26 WebPluginInfo::PLUGIN_TYPE_PEPPER_OUT_OF_PROCESS :
27 webkit::WebPluginInfo::PLUGIN_TYPE_PEPPER_UNSANDBOXED) : 27 WebPluginInfo::PLUGIN_TYPE_PEPPER_UNSANDBOXED) :
28 webkit::WebPluginInfo::PLUGIN_TYPE_PEPPER_IN_PROCESS; 28 WebPluginInfo::PLUGIN_TYPE_PEPPER_IN_PROCESS;
29 29
30 info.name = name.empty() ? 30 info.name = name.empty() ?
31 path.BaseName().LossyDisplayName() : UTF8ToUTF16(name); 31 path.BaseName().LossyDisplayName() : UTF8ToUTF16(name);
32 info.path = path; 32 info.path = path;
33 info.version = ASCIIToUTF16(version); 33 info.version = ASCIIToUTF16(version);
34 info.desc = ASCIIToUTF16(description); 34 info.desc = ASCIIToUTF16(description);
35 info.mime_types = mime_types; 35 info.mime_types = mime_types;
36 info.pepper_permissions = permissions; 36 info.pepper_permissions = permissions;
37 37
38 return info; 38 return info;
39 } 39 }
40 40
41 } // namespace content 41 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698