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

Side by Side Diff: webkit/glue/plugins/plugin_list_mac.mm

Issue 546041: Make the Pepper test run on the mac. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years, 11 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
« no previous file with comments | « chrome/renderer/render_view.cc ('k') | webkit/tools/pepper_test_plugin/Info.plist » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2009 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 "webkit/glue/plugins/plugin_list.h" 5 #include "webkit/glue/plugins/plugin_list.h"
6 6
7 #import <Foundation/Foundation.h> 7 #import <Foundation/Foundation.h>
8 8
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/mac_util.h" 10 #include "base/mac_util.h"
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 // Plugins that we know are working reasonably well. 99 // Plugins that we know are working reasonably well.
100 const char* whitelisted_plugin_mimes[] = { 100 const char* whitelisted_plugin_mimes[] = {
101 "application/geplugin", 101 "application/geplugin",
102 "application/googletalk", 102 "application/googletalk",
103 "application/vnd.npapi-test", 103 "application/vnd.npapi-test",
104 "application/x-id-quakelive", 104 "application/x-id-quakelive",
105 "application/x-picasa-detect", 105 "application/x-picasa-detect",
106 "application/x-shockwave-flash", 106 "application/x-shockwave-flash",
107 "application/x-silverlight", 107 "application/x-silverlight",
108 "application/x-webkit-test-netscape", 108 "application/x-webkit-test-netscape",
109 "pepper-application/x-pepper-test-plugin",
109 "video/quicktime", 110 "video/quicktime",
110 }; 111 };
111 112
112 // Start with names. 113 // Start with names.
113 std::string plugin_name = WideToUTF8(info.name); 114 std::string plugin_name = WideToUTF8(info.name);
114 if (ArrayContainsString(blacklisted_plugin_names, 115 if (ArrayContainsString(blacklisted_plugin_names,
115 arraysize(blacklisted_plugin_names), plugin_name)) { 116 arraysize(blacklisted_plugin_names), plugin_name)) {
116 return false; 117 return false;
117 } 118 }
118 // Then check mime types. 119 // Then check mime types.
(...skipping 24 matching lines...) Expand all
143 for (size_t i = 0; i < plugins->size(); ++i) { 144 for (size_t i = 0; i < plugins->size(); ++i) {
144 if ((*plugins)[i].path.BaseName() == info.path.BaseName()) { 145 if ((*plugins)[i].path.BaseName() == info.path.BaseName()) {
145 return false; // We already have a loaded plugin higher in the hierarchy. 146 return false; // We already have a loaded plugin higher in the hierarchy.
146 } 147 }
147 } 148 }
148 149
149 return true; 150 return true;
150 } 151 }
151 152
152 } // namespace NPAPI 153 } // namespace NPAPI
OLDNEW
« no previous file with comments | « chrome/renderer/render_view.cc ('k') | webkit/tools/pepper_test_plugin/Info.plist » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698