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

Side by Side Diff: chrome/renderer/render_process_impl.cc

Issue 3039016: Part 2 of Make NaCl/Chromium startup interface easier to maintain (Closed) Base URL: git://codf21.jail/chromium.git
Patch Set: Use new RegisterInternalNaClPlugin() Created 10 years, 5 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/nacl/sel_main.cc ('k') | no next file » | 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "build/build_config.h" 5 #include "build/build_config.h"
6 6
7 #if defined(OS_WIN) 7 #if defined(OS_WIN)
8 #include <windows.h> 8 #include <windows.h>
9 #include <objidl.h> 9 #include <objidl.h>
10 #include <mlang.h> 10 #include <mlang.h>
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 147
148 if (command_line.HasSwitch(switches::kEnableWatchdog)) { 148 if (command_line.HasSwitch(switches::kEnableWatchdog)) {
149 // TODO(JAR): Need to implement renderer IO msgloop watchdog. 149 // TODO(JAR): Need to implement renderer IO msgloop watchdog.
150 } 150 }
151 151
152 if (command_line.HasSwitch(switches::kDumpHistogramsOnExit)) { 152 if (command_line.HasSwitch(switches::kDumpHistogramsOnExit)) {
153 StatisticsRecorder::set_dump_on_exit(true); 153 StatisticsRecorder::set_dump_on_exit(true);
154 } 154 }
155 155
156 #ifndef DISABLE_NACL 156 #ifndef DISABLE_NACL
157 if (command_line.HasSwitch(switches::kInternalNaCl)) 157 if (command_line.HasSwitch(switches::kInternalNaCl)) {
158 RegisterInternalNaClPlugin(LaunchNaClProcess); 158 std::map<std::string, uintptr_t> funcs;
159 funcs["launch_nacl_process"] =
160 reinterpret_cast<uintptr_t>(LaunchNaClProcess);
161 RegisterInternalNaClPlugin(funcs);
162 }
159 #endif 163 #endif
160 164
161 if (!command_line.HasSwitch(switches::kDisableByteRangeSupport)) { 165 if (!command_line.HasSwitch(switches::kDisableByteRangeSupport)) {
162 webkit_glue::SetMediaCacheEnabled(true); 166 webkit_glue::SetMediaCacheEnabled(true);
163 } 167 }
164 168
165 #if defined(OS_MACOSX) 169 #if defined(OS_MACOSX)
166 FilePath bundle_path = mac_util::MainAppBundlePath(); 170 FilePath bundle_path = mac_util::MainAppBundlePath();
167 171
168 initialized_media_library_ = 172 initialized_media_library_ =
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
353 } 357 }
354 358
355 void RenderProcessImpl::ClearTransportDIBCache() { 359 void RenderProcessImpl::ClearTransportDIBCache() {
356 for (size_t i = 0; i < arraysize(shared_mem_cache_); ++i) { 360 for (size_t i = 0; i < arraysize(shared_mem_cache_); ++i) {
357 if (shared_mem_cache_[i]) { 361 if (shared_mem_cache_[i]) {
358 FreeTransportDIB(shared_mem_cache_[i]); 362 FreeTransportDIB(shared_mem_cache_[i]);
359 shared_mem_cache_[i] = NULL; 363 shared_mem_cache_[i] = NULL;
360 } 364 }
361 } 365 }
362 } 366 }
OLDNEW
« no previous file with comments | « chrome/nacl/sel_main.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698