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

Side by Side Diff: content/renderer/render_thread_impl.cc

Issue 1830883002: Add blink::ServiceRegistry and expose it from LocalFrame and Platform. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 | « content/renderer/render_frame_impl.cc ('k') | content/renderer/renderer_blink_platform_impl.h » ('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/render_thread_impl.h" 5 #include "content/renderer/render_thread_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <limits> 8 #include <limits>
9 #include <map> 9 #include <map>
10 #include <utility> 10 #include <utility>
(...skipping 1178 matching lines...) Expand 10 before | Expand all | Expand 10 after
1189 const base::CommandLine& command_line = 1189 const base::CommandLine& command_line =
1190 *base::CommandLine::ForCurrentProcess(); 1190 *base::CommandLine::ForCurrentProcess();
1191 1191
1192 #ifdef ENABLE_VTUNE_JIT_INTERFACE 1192 #ifdef ENABLE_VTUNE_JIT_INTERFACE
1193 if (command_line.HasSwitch(switches::kEnableVtune)) 1193 if (command_line.HasSwitch(switches::kEnableVtune))
1194 gin::Debug::SetJitCodeEventHandler(vTune::GetVtuneCodeEventHandler()); 1194 gin::Debug::SetJitCodeEventHandler(vTune::GetVtuneCodeEventHandler());
1195 #endif 1195 #endif
1196 1196
1197 SetRuntimeFeaturesDefaultsAndUpdateFromArgs(command_line); 1197 SetRuntimeFeaturesDefaultsAndUpdateFromArgs(command_line);
1198 1198
1199 blink_platform_impl_.reset( 1199 blink_platform_impl_.reset(new RendererBlinkPlatformImpl(
1200 new RendererBlinkPlatformImpl(renderer_scheduler_.get())); 1200 renderer_scheduler_.get(),
1201 static_cast<ServiceRegistryImpl*>(service_registry())->GetWeakPtr()));
1201 blink::initialize(blink_platform_impl_.get()); 1202 blink::initialize(blink_platform_impl_.get());
1202 1203
1203 v8::Isolate* isolate = blink::mainThreadIsolate(); 1204 v8::Isolate* isolate = blink::mainThreadIsolate();
1204 isolate->SetCreateHistogramFunction(CreateHistogram); 1205 isolate->SetCreateHistogramFunction(CreateHistogram);
1205 isolate->SetAddHistogramSampleFunction(AddHistogramSample); 1206 isolate->SetAddHistogramSampleFunction(AddHistogramSample);
1206 1207
1207 main_thread_compositor_task_runner_ = 1208 main_thread_compositor_task_runner_ =
1208 renderer_scheduler_->CompositorTaskRunner(); 1209 renderer_scheduler_->CompositorTaskRunner();
1209 1210
1210 main_input_callback_.Reset( 1211 main_input_callback_.Reset(
(...skipping 929 matching lines...) Expand 10 before | Expand all | Expand 10 after
2140 } 2141 }
2141 2142
2142 void RenderThreadImpl::PendingRenderFrameConnect::OnConnectionError() { 2143 void RenderThreadImpl::PendingRenderFrameConnect::OnConnectionError() {
2143 size_t erased = 2144 size_t erased =
2144 RenderThreadImpl::current()->pending_render_frame_connects_.erase( 2145 RenderThreadImpl::current()->pending_render_frame_connects_.erase(
2145 routing_id_); 2146 routing_id_);
2146 DCHECK_EQ(1u, erased); 2147 DCHECK_EQ(1u, erased);
2147 } 2148 }
2148 2149
2149 } // namespace content 2150 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/render_frame_impl.cc ('k') | content/renderer/renderer_blink_platform_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698