| OLD | NEW |
| 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 <windows.h> | 5 #include <windows.h> |
| 6 #include <objidl.h> | 6 #include <objidl.h> |
| 7 #include <mlang.h> | 7 #include <mlang.h> |
| 8 | 8 |
| 9 #include "chrome/renderer/render_process.h" | 9 #include "chrome/renderer/render_process.h" |
| 10 | 10 |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 GdiInitializeLanguagePack gdi_init_lpk = | 56 GdiInitializeLanguagePack gdi_init_lpk = |
| 57 reinterpret_cast<GdiInitializeLanguagePack>(GetProcAddress( | 57 reinterpret_cast<GdiInitializeLanguagePack>(GetProcAddress( |
| 58 GetModuleHandle(L"GDI32.DLL"), | 58 GetModuleHandle(L"GDI32.DLL"), |
| 59 "GdiInitializeLanguagePack")); | 59 "GdiInitializeLanguagePack")); |
| 60 DCHECK(gdi_init_lpk); | 60 DCHECK(gdi_init_lpk); |
| 61 if (gdi_init_lpk) { | 61 if (gdi_init_lpk) { |
| 62 gdi_init_lpk(0); | 62 gdi_init_lpk(0); |
| 63 } | 63 } |
| 64 } | 64 } |
| 65 | 65 |
| 66 CommandLine command_line; | 66 const CommandLine& command_line = *CommandLine::ForCurrentProcess(); |
| 67 if (command_line.HasSwitch(switches::kJavaScriptFlags)) { | 67 if (command_line.HasSwitch(switches::kJavaScriptFlags)) { |
| 68 webkit_glue::SetJavaScriptFlags( | 68 webkit_glue::SetJavaScriptFlags( |
| 69 command_line.GetSwitchValue(switches::kJavaScriptFlags)); | 69 command_line.GetSwitchValue(switches::kJavaScriptFlags)); |
| 70 } | 70 } |
| 71 if (command_line.HasSwitch(switches::kPlaybackMode) || | 71 if (command_line.HasSwitch(switches::kPlaybackMode) || |
| 72 command_line.HasSwitch(switches::kRecordMode)) { | 72 command_line.HasSwitch(switches::kRecordMode)) { |
| 73 webkit_glue::SetRecordPlaybackMode(true); | 73 webkit_glue::SetRecordPlaybackMode(true); |
| 74 } | 74 } |
| 75 | 75 |
| 76 if (command_line.HasSwitch(switches::kInProcessPlugins) || | 76 if (command_line.HasSwitch(switches::kInProcessPlugins) || |
| (...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 200 5000 /* 5 seconds */); | 200 5000 /* 5 seconds */); |
| 201 } | 201 } |
| 202 | 202 |
| 203 void RenderProcess::Cleanup() { | 203 void RenderProcess::Cleanup() { |
| 204 #ifndef NDEBUG | 204 #ifndef NDEBUG |
| 205 // log important leaked objects | 205 // log important leaked objects |
| 206 webkit_glue::CheckForLeaks(); | 206 webkit_glue::CheckForLeaks(); |
| 207 #endif | 207 #endif |
| 208 } | 208 } |
| 209 | 209 |
| OLD | NEW |