X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=src%2Fthird_party%2FWebKit%2FSource%2Fweb%2FWebEmbeddedWorkerImpl.h;h=624680730ab7a132cdb5e84e0fa369a6d1c2b136;hb=3545e9f2671f595d2a2f3ee75ca0393b01e35ef6;hp=d4b7ce98137e31bf3316bf01089867be166b84d0;hpb=7d210d4c7e9ba36e635eabc5b5780495f8a63292;p=platform%2Fframework%2Fweb%2Fcrosswalk.git diff --git a/src/third_party/WebKit/Source/web/WebEmbeddedWorkerImpl.h b/src/third_party/WebKit/Source/web/WebEmbeddedWorkerImpl.h index d4b7ce9..6246807 100644 --- a/src/third_party/WebKit/Source/web/WebEmbeddedWorkerImpl.h +++ b/src/third_party/WebKit/Source/web/WebEmbeddedWorkerImpl.h @@ -32,6 +32,7 @@ #define WebEmbeddedWorkerImpl_h #include "public/web/WebContentSecurityPolicy.h" +#include "public/web/WebDevToolsAgentClient.h" #include "public/web/WebEmbeddedWorker.h" #include "public/web/WebEmbeddedWorkerStartData.h" #include "public/web/WebFrameClient.h" @@ -41,12 +42,14 @@ namespace blink { class ServiceWorkerGlobalScopeProxy; class WebServiceWorkerNetworkProvider; class WebView; +class WorkerInspectorProxy; class WorkerScriptLoader; class WorkerThread; class WebEmbeddedWorkerImpl FINAL : public WebEmbeddedWorker - , public WebFrameClient { + , public WebFrameClient + , public WebDevToolsAgentClient { WTF_MAKE_NONCOPYABLE(WebEmbeddedWorkerImpl); public: WebEmbeddedWorkerImpl( @@ -64,11 +67,13 @@ public: virtual void resumeAfterDownload() OVERRIDE; virtual void terminateWorkerContext() OVERRIDE; virtual void resumeWorkerContext() OVERRIDE; - virtual void attachDevTools() OVERRIDE; - virtual void reattachDevTools(const WebString& savedState) OVERRIDE; + virtual void attachDevTools(const WebString& hostId) OVERRIDE; + virtual void reattachDevTools(const WebString& hostId, const WebString& savedState) OVERRIDE; virtual void detachDevTools() OVERRIDE; virtual void dispatchDevToolsMessage(const WebString&) OVERRIDE; + void postMessageToPageInspector(const WTF::String&); + private: class Loader; class LoaderProxy; @@ -81,6 +86,12 @@ private: const WebURLResponse& redirectResponse) OVERRIDE; virtual void didFinishDocumentLoad(WebLocalFrame*) OVERRIDE; + // WebDevToolsAgentClient overrides. + virtual void sendMessageToInspectorFrontend(const WebString&) OVERRIDE; + virtual void saveAgentRuntimeState(const WebString&) OVERRIDE; + virtual void resumeStartup() OVERRIDE; + + void startScriptLoader(WebLocalFrame*); void onScriptLoaderFinished(); void startWorkerThread(); @@ -102,6 +113,7 @@ private: RefPtr m_workerThread; OwnPtr m_loaderProxy; OwnPtr m_workerGlobalScopeProxy; + OwnPtr m_workerInspectorProxy; // 'shadow page' - created to proxy loading requests from the worker. // Both WebView and WebFrame objects are close()'ed (where they're @@ -112,11 +124,19 @@ private: bool m_askedToTerminate; + enum WaitingForDebuggerState { + WaitingForDebuggerBeforeLoadingScript, + WaitingForDebuggerAfterScriptLoaded, + NotWaitingForDebugger + }; + enum { DontPauseAfterDownload, DoPauseAfterDownload, IsPausedAfterDownload } m_pauseAfterDownloadState; + + WaitingForDebuggerState m_waitingForDebuggerState; }; } // namespace blink