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

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

Issue 2116113002: [worklets] Make WorkerThread handle both Worker and Worklet global scopes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase again Created 4 years, 4 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 * Copyright (C) 2009 Google Inc. All Rights Reserved. 3 * Copyright (C) 2009 Google Inc. All Rights Reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 26 matching lines...) Expand all
37 #include "core/frame/FrameConsole.h" 37 #include "core/frame/FrameConsole.h"
38 #include "core/frame/LocalFrame.h" 38 #include "core/frame/LocalFrame.h"
39 #include "core/frame/csp/ContentSecurityPolicy.h" 39 #include "core/frame/csp/ContentSecurityPolicy.h"
40 #include "core/inspector/ConsoleMessage.h" 40 #include "core/inspector/ConsoleMessage.h"
41 #include "core/loader/DocumentLoadTiming.h" 41 #include "core/loader/DocumentLoadTiming.h"
42 #include "core/loader/DocumentLoader.h" 42 #include "core/loader/DocumentLoader.h"
43 #include "core/origin_trials/OriginTrialContext.h" 43 #include "core/origin_trials/OriginTrialContext.h"
44 #include "core/workers/InProcessWorkerBase.h" 44 #include "core/workers/InProcessWorkerBase.h"
45 #include "core/workers/InProcessWorkerObjectProxy.h" 45 #include "core/workers/InProcessWorkerObjectProxy.h"
46 #include "core/workers/WorkerClients.h" 46 #include "core/workers/WorkerClients.h"
47 #include "core/workers/WorkerGlobalScope.h"
47 #include "core/workers/WorkerInspectorProxy.h" 48 #include "core/workers/WorkerInspectorProxy.h"
48 #include "core/workers/WorkerThreadStartupData.h" 49 #include "core/workers/WorkerThreadStartupData.h"
49 #include "wtf/WTF.h" 50 #include "wtf/WTF.h"
50 #include <memory> 51 #include <memory>
51 52
52 namespace blink { 53 namespace blink {
53 54
54 namespace { 55 namespace {
55 56
56 void processUnhandledExceptionOnWorkerGlobalScope(const String& errorMessage, st d::unique_ptr<SourceLocation> location, ExecutionContext* scriptContext) 57 void processUnhandledExceptionOnWorkerGlobalScope(const String& errorMessage, st d::unique_ptr<SourceLocation> location, ExecutionContext* scriptContext)
(...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after
299 300
300 bool InProcessWorkerMessagingProxy::isParentContextThread() const 301 bool InProcessWorkerMessagingProxy::isParentContextThread() const
301 { 302 {
302 // TODO(nhiroki): Nested worker is not supported yet, so the parent context 303 // TODO(nhiroki): Nested worker is not supported yet, so the parent context
303 // thread should be equal to the main thread (http://crbug.com/31666). 304 // thread should be equal to the main thread (http://crbug.com/31666).
304 DCHECK(getExecutionContext()->isDocument()); 305 DCHECK(getExecutionContext()->isDocument());
305 return isMainThread(); 306 return isMainThread();
306 } 307 }
307 308
308 } // namespace blink 309 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698