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

Side by Side Diff: chrome/plugin/plugin_main.cc

Issue 18248: CommandLine API rework (Closed)
Patch Set: fixes Created 11 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
« no previous file with comments | « chrome/installer/setup/setup.cc ('k') | chrome/plugin/webplugin_delegate_stub.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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 "base/command_line.h" 5 #include "base/command_line.h"
6 #include "base/message_loop.h" 6 #include "base/message_loop.h"
7 #include "base/system_monitor.h" 7 #include "base/system_monitor.h"
8 #include "chrome/common/chrome_constants.h" 8 #include "chrome/common/chrome_constants.h"
9 #include "chrome/common/chrome_switches.h" 9 #include "chrome/common/chrome_switches.h"
10 #include "chrome/common/logging_chrome.h" 10 #include "chrome/common/logging_chrome.h"
11 #include "chrome/common/main_function_params.h" 11 #include "chrome/common/main_function_params.h"
12 #include "chrome/common/win_util.h" 12 #include "chrome/common/win_util.h"
13 #include "chrome/plugin/plugin_process.h" 13 #include "chrome/plugin/plugin_process.h"
14 #include "chrome/test/injection_test_dll.h" 14 #include "chrome/test/injection_test_dll.h"
15 #include "sandbox/src/sandbox.h" 15 #include "sandbox/src/sandbox.h"
16 16
17 // mainline routine for running as the plugin process 17 // mainline routine for running as the plugin process
18 int PluginMain(const MainFunctionParams& parameters) { 18 int PluginMain(const MainFunctionParams& parameters) {
19 CommandLine& parsed_command_line = parameters.command_line_; 19 const CommandLine& parsed_command_line = parameters.command_line_;
20 sandbox::TargetServices* target_services = 20 sandbox::TargetServices* target_services =
21 parameters.sandbox_info_.TargetServices(); 21 parameters.sandbox_info_.TargetServices();
22 22
23 // The main thread of the plugin services IO. 23 // The main thread of the plugin services IO.
24 MessageLoopForIO main_message_loop; 24 MessageLoopForIO main_message_loop;
25 std::wstring app_name = chrome::kBrowserAppName; 25 std::wstring app_name = chrome::kBrowserAppName;
26 PlatformThread::SetName(WideToASCII(app_name + L"_PluginMain").c_str()); 26 PlatformThread::SetName(WideToASCII(app_name + L"_PluginMain").c_str());
27 27
28 // Initialize the SystemMonitor 28 // Initialize the SystemMonitor
29 base::SystemMonitor::Start(); 29 base::SystemMonitor::Start();
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 // Load the accelerator table from the browser executable and tell the 81 // Load the accelerator table from the browser executable and tell the
82 // message loop to use it when translating messages. 82 // message loop to use it when translating messages.
83 MessageLoop::current()->Run(); 83 MessageLoop::current()->Run();
84 } 84 }
85 PluginProcess::GlobalCleanup(); 85 PluginProcess::GlobalCleanup();
86 86
87 CoUninitialize(); 87 CoUninitialize();
88 return 0; 88 return 0;
89 } 89 }
90 90
OLDNEW
« no previous file with comments | « chrome/installer/setup/setup.cc ('k') | chrome/plugin/webplugin_delegate_stub.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698