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

Side by Side Diff: content/renderer/pepper/plugin_module.cc

Issue 803813003: Make callers of CommandLine use it via the base:: namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years 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
« no previous file with comments | « content/renderer/pepper/host_globals.cc ('k') | content/renderer/render_frame_impl.cc » ('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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/renderer/pepper/plugin_module.h" 5 #include "content/renderer/pepper/plugin_module.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after
320 if (strcmp(name, iface_str) == 0) \ 320 if (strcmp(name, iface_str) == 0) \
321 return function_name; 321 return function_name;
322 322
323 #include "ppapi/thunk/interfaces_legacy.h" 323 #include "ppapi/thunk/interfaces_legacy.h"
324 324
325 #undef LEGACY_IFACE 325 #undef LEGACY_IFACE
326 326
327 // Only support the testing interface when the command line switch is 327 // Only support the testing interface when the command line switch is
328 // specified. This allows us to prevent people from (ab)using this interface 328 // specified. This allows us to prevent people from (ab)using this interface
329 // in production code. 329 // in production code.
330 if (CommandLine::ForCurrentProcess()->HasSwitch( 330 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
331 switches::kEnablePepperTesting)) { 331 switches::kEnablePepperTesting)) {
332 if (strcmp(name, PPB_TESTING_PRIVATE_INTERFACE) == 0) 332 if (strcmp(name, PPB_TESTING_PRIVATE_INTERFACE) == 0)
333 return &testing_interface; 333 return &testing_interface;
334 } 334 }
335 return NULL; 335 return NULL;
336 } 336 }
337 337
338 const void* GetInterface(const char* name) { 338 const void* GetInterface(const char* name) {
339 // All interfaces should be used on the main thread. 339 // All interfaces should be used on the main thread.
340 CHECK(IsMainThread()); 340 CHECK(IsMainThread());
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after
720 channel_handle, 720 channel_handle,
721 peer_pid, 721 peer_pid,
722 plugin_child_id, 722 plugin_child_id,
723 false)) // is_external = false 723 false)) // is_external = false
724 return scoped_refptr<PluginModule>(); 724 return scoped_refptr<PluginModule>();
725 725
726 return module; 726 return module;
727 } 727 }
728 728
729 } // namespace content 729 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/pepper/host_globals.cc ('k') | content/renderer/render_frame_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698