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

Side by Side Diff: ppapi/proxy/pdf_resource.cc

Issue 819203002: Make callers of CommandLine use it via the base:: namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 12 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
« no previous file with comments | « ppapi/nacl_irt/ppapi_dispatcher.cc ('k') | ppapi/proxy/ppp_messaging_proxy_perftest.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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "ppapi/proxy/pdf_resource.h" 5 #include "ppapi/proxy/pdf_resource.h"
6 6
7 #include <stdlib.h> 7 #include <stdlib.h>
8 #include <string.h> 8 #include <string.h>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 10 matching lines...) Expand all
21 namespace ppapi { 21 namespace ppapi {
22 namespace proxy { 22 namespace proxy {
23 23
24 namespace { 24 namespace {
25 25
26 // TODO(raymes): This is just copied from render_thread_impl.cc. We should have 26 // TODO(raymes): This is just copied from render_thread_impl.cc. We should have
27 // generic code somewhere to get the locale in the plugin. 27 // generic code somewhere to get the locale in the plugin.
28 std::string GetLocale() { 28 std::string GetLocale() {
29 // The browser process should have passed the locale to the plugin via the 29 // The browser process should have passed the locale to the plugin via the
30 // --lang command line flag. 30 // --lang command line flag.
31 const CommandLine& parsed_command_line = *CommandLine::ForCurrentProcess(); 31 const base::CommandLine& parsed_command_line =
32 *base::CommandLine::ForCurrentProcess();
32 const std::string& lang = parsed_command_line.GetSwitchValueASCII("lang"); 33 const std::string& lang = parsed_command_line.GetSwitchValueASCII("lang");
33 DCHECK(!lang.empty()); 34 DCHECK(!lang.empty());
34 return lang; 35 return lang;
35 } 36 }
36 37
37 } // namespace 38 } // namespace
38 39
39 PDFResource::PDFResource(Connection connection, PP_Instance instance) 40 PDFResource::PDFResource(Connection connection, PP_Instance instance)
40 : PluginResource(connection, instance) { 41 : PluginResource(connection, instance) {
41 SendCreate(RENDERER, PpapiHostMsg_PDF_Create()); 42 SendCreate(RENDERER, PpapiHostMsg_PDF_Create());
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 void PDFResource::GetV8ExternalSnapshotData(const char** natives_data_out, 209 void PDFResource::GetV8ExternalSnapshotData(const char** natives_data_out,
209 int* natives_size_out, 210 int* natives_size_out,
210 const char** snapshot_data_out, 211 const char** snapshot_data_out,
211 int* snapshot_size_out) { 212 int* snapshot_size_out) {
212 gin::IsolateHolder::GetV8ExternalSnapshotData(natives_data_out, 213 gin::IsolateHolder::GetV8ExternalSnapshotData(natives_data_out,
213 natives_size_out, snapshot_data_out, snapshot_size_out); 214 natives_size_out, snapshot_data_out, snapshot_size_out);
214 } 215 }
215 216
216 } // namespace proxy 217 } // namespace proxy
217 } // namespace ppapi 218 } // namespace ppapi
OLDNEW
« no previous file with comments | « ppapi/nacl_irt/ppapi_dispatcher.cc ('k') | ppapi/proxy/ppp_messaging_proxy_perftest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698