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

Side by Side Diff: Source/web/WebSharedWorkerImpl.h

Issue 137633004: Add WorkerGlobalScope* param to WorkerReportingProxy::workerGlobalScopeStarted (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 11 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 | Annotate | Revision Log
« no previous file with comments | « Source/web/ServiceWorkerGlobalScopeProxy.cpp ('k') | Source/web/WebSharedWorkerImpl.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google 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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * 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 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 26 matching lines...) Expand all
37 #include "WebFrameClient.h" 37 #include "WebFrameClient.h"
38 #include "WebSharedWorkerClient.h" 38 #include "WebSharedWorkerClient.h"
39 #include "core/dom/ExecutionContext.h" 39 #include "core/dom/ExecutionContext.h"
40 #include "core/workers/WorkerLoaderProxy.h" 40 #include "core/workers/WorkerLoaderProxy.h"
41 #include "core/workers/WorkerReportingProxy.h" 41 #include "core/workers/WorkerReportingProxy.h"
42 #include "core/workers/WorkerThread.h" 42 #include "core/workers/WorkerThread.h"
43 #include "wtf/PassOwnPtr.h" 43 #include "wtf/PassOwnPtr.h"
44 #include "wtf/RefPtr.h" 44 #include "wtf/RefPtr.h"
45 #include "wtf/WeakPtr.h" 45 #include "wtf/WeakPtr.h"
46 46
47
48 namespace blink { 47 namespace blink {
49 class WebApplicationCacheHost; 48 class WebApplicationCacheHost;
50 class WebApplicationCacheHostClient; 49 class WebApplicationCacheHostClient;
51 class WebWorkerClient; 50 class WebWorkerClient;
52 class WebSecurityOrigin; 51 class WebSecurityOrigin;
53 class WebString; 52 class WebString;
54 class WebURL; 53 class WebURL;
55 class WebView; 54 class WebView;
56 class WebWorker; 55 class WebWorker;
57 class WebSharedWorkerClient; 56 class WebSharedWorkerClient;
57
58 // This class is used by the worker process code to talk to the WebCore::SharedW orker implementation. 58 // This class is used by the worker process code to talk to the WebCore::SharedW orker implementation.
59 // It can't use it directly since it uses WebKit types, so this class converts t he data types. 59 // It can't use it directly since it uses WebKit types, so this class converts t he data types.
60 // When the WebCore::SharedWorker object wants to call WebCore::WorkerReportingP roxy, this class will 60 // When the WebCore::SharedWorker object wants to call WebCore::WorkerReportingP roxy, this class will
61 // convert to Chrome data types first and then call the supplied WebCommonWorker Client. 61 // convert to Chrome data types first and then call the supplied WebCommonWorker Client.
62 class WebSharedWorkerImpl 62 class WebSharedWorkerImpl
63 : public WebCore::WorkerReportingProxy 63 : public WebCore::WorkerReportingProxy
64 , public WebCore::WorkerLoaderProxy 64 , public WebCore::WorkerLoaderProxy
65 , public WebFrameClient 65 , public WebFrameClient
66 , public WebSharedWorker { 66 , public WebSharedWorker {
67 public: 67 public:
68 explicit WebSharedWorkerImpl(WebSharedWorkerClient*); 68 explicit WebSharedWorkerImpl(WebSharedWorkerClient*);
69 69
70 // WebCore::WorkerReportingProxy methods: 70 // WebCore::WorkerReportingProxy methods:
71 virtual void reportException( 71 virtual void reportException(
72 const WTF::String&, int, int, const WTF::String&); 72 const WTF::String&, int, int, const WTF::String&);
73 virtual void reportConsoleMessage( 73 virtual void reportConsoleMessage(
74 WebCore::MessageSource, WebCore::MessageLevel, 74 WebCore::MessageSource, WebCore::MessageLevel,
75 const WTF::String&, int, const WTF::String&); 75 const WTF::String&, int, const WTF::String&);
76 virtual void postMessageToPageInspector(const WTF::String&); 76 virtual void postMessageToPageInspector(const WTF::String&);
77 virtual void updateInspectorStateCookie(const WTF::String&); 77 virtual void updateInspectorStateCookie(const WTF::String&);
78 virtual void workerGlobalScopeStarted(); 78 virtual void workerGlobalScopeStarted(WebCore::WorkerGlobalScope*);
79 virtual void workerGlobalScopeClosed(); 79 virtual void workerGlobalScopeClosed();
80 virtual void workerGlobalScopeDestroyed(); 80 virtual void workerGlobalScopeDestroyed();
81 81
82 // WebCore::WorkerLoaderProxy methods: 82 // WebCore::WorkerLoaderProxy methods:
83 virtual void postTaskToLoader(PassOwnPtr<WebCore::ExecutionContextTask>); 83 virtual void postTaskToLoader(PassOwnPtr<WebCore::ExecutionContextTask>);
84 virtual bool postTaskForModeToWorkerGlobalScope( 84 virtual bool postTaskForModeToWorkerGlobalScope(
85 PassOwnPtr<WebCore::ExecutionContextTask>, const WTF::String& mode); 85 PassOwnPtr<WebCore::ExecutionContextTask>, const WTF::String& mode);
86 86
87 // WebFrameClient methods to support resource loading thru the 'shadow page' . 87 // WebFrameClient methods to support resource loading thru the 'shadow page' .
88 virtual WebApplicationCacheHost* createApplicationCacheHost(WebFrame*, WebAp plicationCacheHostClient*); 88 virtual WebApplicationCacheHost* createApplicationCacheHost(WebFrame*, WebAp plicationCacheHostClient*);
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 // class itself, but here it's implemented by Chrome so we create 134 // class itself, but here it's implemented by Chrome so we create
135 // our own WeakPtr. 135 // our own WeakPtr.
136 WeakPtr<WebSharedWorkerClient> m_clientWeakPtr; 136 WeakPtr<WebSharedWorkerClient> m_clientWeakPtr;
137 137
138 bool m_pauseWorkerContextOnStart; 138 bool m_pauseWorkerContextOnStart;
139 }; 139 };
140 140
141 } // namespace blink 141 } // namespace blink
142 142
143 #endif 143 #endif
OLDNEW
« no previous file with comments | « Source/web/ServiceWorkerGlobalScopeProxy.cpp ('k') | Source/web/WebSharedWorkerImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698