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

Side by Side Diff: components/html_viewer/blink_platform_impl.cc

Issue 1112603003: mojo: Fix html_viewer build break from https://codereview.chromium.org/1115443002 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 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 | « components/html_viewer/blink_platform_impl.h ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "components/html_viewer/blink_platform_impl.h" 5 #include "components/html_viewer/blink_platform_impl.h"
6 6
7 #include <cmath> 7 #include <cmath>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/rand_util.h" 10 #include "base/rand_util.h"
11 #include "base/stl_util.h" 11 #include "base/stl_util.h"
12 #include "base/synchronization/waitable_event.h" 12 #include "base/synchronization/waitable_event.h"
13 #include "base/thread_task_runner_handle.h"
13 #include "base/threading/platform_thread.h" 14 #include "base/threading/platform_thread.h"
14 #include "base/time/time.h" 15 #include "base/time/time.h"
15 #include "components/html_viewer/blink_resource_constants.h" 16 #include "components/html_viewer/blink_resource_constants.h"
16 #include "components/html_viewer/web_clipboard_impl.h" 17 #include "components/html_viewer/web_clipboard_impl.h"
17 #include "components/html_viewer/web_cookie_jar_impl.h" 18 #include "components/html_viewer/web_cookie_jar_impl.h"
18 #include "components/html_viewer/web_message_port_channel_impl.h" 19 #include "components/html_viewer/web_message_port_channel_impl.h"
19 #include "components/html_viewer/web_socket_handle_impl.h" 20 #include "components/html_viewer/web_socket_handle_impl.h"
20 #include "components/html_viewer/web_thread_impl.h" 21 #include "components/html_viewer/web_thread_impl.h"
21 #include "components/html_viewer/web_url_loader_impl.h" 22 #include "components/html_viewer/web_url_loader_impl.h"
22 #include "net/base/data_url.h" 23 #include "net/base/data_url.h"
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
255 return new WebThreadImpl(name); 256 return new WebThreadImpl(name);
256 } 257 }
257 258
258 blink::WebThread* BlinkPlatformImpl::currentThread() { 259 blink::WebThread* BlinkPlatformImpl::currentThread() {
259 WebThreadImplForMessageLoop* thread = 260 WebThreadImplForMessageLoop* thread =
260 static_cast<WebThreadImplForMessageLoop*>(current_thread_slot_.Get()); 261 static_cast<WebThreadImplForMessageLoop*>(current_thread_slot_.Get());
261 if (thread) 262 if (thread)
262 return (thread); 263 return (thread);
263 264
264 scoped_refptr<base::MessageLoopProxy> message_loop = 265 scoped_refptr<base::MessageLoopProxy> message_loop =
265 base::MessageLoopProxy::current(); 266 base::MessageLoopProxy::current();
msw 2015/04/28 17:50:11 This file might need an explicit base/message_loop
266 if (!message_loop.get()) 267 if (!message_loop.get())
267 return NULL; 268 return NULL;
268 269
269 thread = new WebThreadImplForMessageLoop(message_loop.get()); 270 thread = new WebThreadImplForMessageLoop(message_loop.get());
270 current_thread_slot_.Set(thread); 271 current_thread_slot_.Set(thread);
271 return thread; 272 return thread;
272 } 273 }
273 274
274 void BlinkPlatformImpl::yieldCurrentThread() { 275 void BlinkPlatformImpl::yieldCurrentThread() {
275 base::PlatformThread::YieldCurrentThread(); 276 base::PlatformThread::YieldCurrentThread();
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
311 } 312 }
312 313
313 // static 314 // static
314 void BlinkPlatformImpl::DestroyCurrentThread(void* thread) { 315 void BlinkPlatformImpl::DestroyCurrentThread(void* thread) {
315 WebThreadImplForMessageLoop* impl = 316 WebThreadImplForMessageLoop* impl =
316 static_cast<WebThreadImplForMessageLoop*>(thread); 317 static_cast<WebThreadImplForMessageLoop*>(thread);
317 delete impl; 318 delete impl;
318 } 319 }
319 320
320 } // namespace html_viewer 321 } // namespace html_viewer
OLDNEW
« no previous file with comments | « components/html_viewer/blink_platform_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698