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

Side by Side Diff: third_party/WebKit/Source/core/workers/WorkerThread.cpp

Issue 2761693002: Wrapped PassRefPtrs in move where passed to RefPtr constructor. (Closed)
Patch Set: Added move wraps for multiple instances in 1 line. Created 3 years, 9 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after
296 } 296 }
297 NOTREACHED() << static_cast<int>(m_exitCode); 297 NOTREACHED() << static_cast<int>(m_exitCode);
298 return false; 298 return false;
299 } 299 }
300 300
301 WorkerThread::WorkerThread(PassRefPtr<WorkerLoaderProxy> workerLoaderProxy, 301 WorkerThread::WorkerThread(PassRefPtr<WorkerLoaderProxy> workerLoaderProxy,
302 WorkerReportingProxy& workerReportingProxy) 302 WorkerReportingProxy& workerReportingProxy)
303 : m_workerThreadId(getNextWorkerThreadId()), 303 : m_workerThreadId(getNextWorkerThreadId()),
304 m_forcibleTerminationDelayInMs(kForcibleTerminationDelayInMs), 304 m_forcibleTerminationDelayInMs(kForcibleTerminationDelayInMs),
305 m_inspectorTaskRunner(WTF::makeUnique<InspectorTaskRunner>()), 305 m_inspectorTaskRunner(WTF::makeUnique<InspectorTaskRunner>()),
306 m_workerLoaderProxy(workerLoaderProxy), 306 m_workerLoaderProxy(std::move(workerLoaderProxy)),
307 m_workerReportingProxy(workerReportingProxy), 307 m_workerReportingProxy(workerReportingProxy),
308 m_shutdownEvent(WTF::wrapUnique( 308 m_shutdownEvent(WTF::wrapUnique(
309 new WaitableEvent(WaitableEvent::ResetPolicy::Manual, 309 new WaitableEvent(WaitableEvent::ResetPolicy::Manual,
310 WaitableEvent::InitialState::NonSignaled))), 310 WaitableEvent::InitialState::NonSignaled))),
311 m_workerThreadLifecycleContext(new WorkerThreadLifecycleContext) { 311 m_workerThreadLifecycleContext(new WorkerThreadLifecycleContext) {
312 DCHECK(isMainThread()); 312 DCHECK(isMainThread());
313 MutexLocker lock(threadSetMutex()); 313 MutexLocker lock(threadSetMutex());
314 workerThreads().insert(this); 314 workerThreads().insert(this);
315 } 315 }
316 316
(...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after
656 MutexLocker lock(m_threadStateMutex); 656 MutexLocker lock(m_threadStateMutex);
657 return m_requestedToTerminate; 657 return m_requestedToTerminate;
658 } 658 }
659 659
660 ExitCode WorkerThread::getExitCodeForTesting() { 660 ExitCode WorkerThread::getExitCodeForTesting() {
661 MutexLocker lock(m_threadStateMutex); 661 MutexLocker lock(m_threadStateMutex);
662 return m_exitCode; 662 return m_exitCode;
663 } 663 }
664 664
665 } // namespace blink 665 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/style/ShapeValue.h ('k') | third_party/WebKit/Source/core/xml/parser/SharedBufferReader.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698