Bug 105085 - Pass debuggerTaskMode as a parameter in WorkerScriptDebugServer constructor
Summary: Pass debuggerTaskMode as a parameter in WorkerScriptDebugServer constructor
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (Deprecated) (show other bugs)
Version: 528+ (Nightly build)
Hardware: All Linux
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-12-15 01:36 PST by Seokju Kwon
Modified: 2012-12-19 02:40 PST (History)
12 users (show)

See Also:


Attachments
Patch (1.81 KB, patch)
2012-12-15 01:43 PST, Seokju Kwon
no flags Details | Formatted Diff | Diff
Patch (6.66 KB, patch)
2012-12-18 07:19 PST, Seokju Kwon
no flags Details | Formatted Diff | Diff
Patch (6.66 KB, patch)
2012-12-19 01:34 PST, Seokju Kwon
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Seokju Kwon 2012-12-15 01:36:33 PST
Build break occurs when ENABLE_INSPECTOR is disabled.
(Source/WebCore/bindings/js/WorkerScriptDebugServer.cpp:96:82: error: ‘WorkerDebuggerAgent’ has not been declared)
And Use WorkerScriptDebugServer::debuggerTaskMode instead of WorkerDebuggerAgent::debuggerTaskMode.
Comment 1 Seokju Kwon 2012-12-15 01:43:12 PST
Created attachment 179582 [details]
Patch
Comment 2 Seokju Kwon 2012-12-17 18:55:49 PST
yurys : What do you think about it?
Comment 3 Yury Semikhatsky 2012-12-17 21:16:08 PST
Comment on attachment 179582 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=179582&action=review

> Source/WebCore/bindings/js/WorkerScriptDebugServer.cpp:96
> +        result = m_workerContext->thread()->runLoop().runInMode(m_workerContext, WorkerScriptDebugServer::debuggerTaskMode);

We should leave only one of WorkerDebuggerAgent::debuggerTaskMode and WorkerScriptDebugServer::debuggerTaskMode and remove other one. It'd prefer leaving  WorkerDebuggerAgent::debuggerTaskMode but WorkerScriptDebugServer should not depend on WorkerDebuggerAgent as dependency is in the opposite direction. To overcome this we way pass debuggerTaskMode as a parameter in WorkerScriptDebugServer constructor.
Comment 4 Seokju Kwon 2012-12-18 07:19:20 PST
Created attachment 179937 [details]
Patch
Comment 5 Seokju Kwon 2012-12-18 18:00:32 PST
(In reply to comment #3)
> (From update of attachment 179582 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=179582&action=review
> 
> > Source/WebCore/bindings/js/WorkerScriptDebugServer.cpp:96
> > +        result = m_workerContext->thread()->runLoop().runInMode(m_workerContext, WorkerScriptDebugServer::debuggerTaskMode);
> 
> We should leave only one of WorkerDebuggerAgent::debuggerTaskMode and WorkerScriptDebugServer::debuggerTaskMode and remove other one. It'd prefer leaving  WorkerDebuggerAgent::debuggerTaskMode but WorkerScriptDebugServer should not depend on WorkerDebuggerAgent as dependency is in the opposite direction. To overcome this we way pass debuggerTaskMode as a parameter in WorkerScriptDebugServer constructor.

As you said, I have fixed them.
Comment 6 Yury Semikhatsky 2012-12-18 23:45:13 PST
Comment on attachment 179937 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=179937&action=review

> Source/WebCore/bindings/js/WorkerScriptDebugServer.h:45
> +    WorkerScriptDebugServer(WorkerContext*, const String);

const String -> const String&

> Source/WebCore/bindings/v8/WorkerScriptDebugServer.h:50
> +    WorkerScriptDebugServer(WorkerContext*, const String);

const String -> const String&
Comment 7 Yury Semikhatsky 2012-12-18 23:45:45 PST
(In reply to comment #6)
> const String -> const String&

Apart from that looks good to me.
Comment 8 Seokju Kwon 2012-12-19 01:34:41 PST
Created attachment 180118 [details]
Patch
Comment 9 Seokju Kwon 2012-12-19 01:37:39 PST
Comment on attachment 180118 [details]
Patch

Fixed it. Thank you for your review.
Comment 10 WebKit Review Bot 2012-12-19 02:40:23 PST
Comment on attachment 180118 [details]
Patch

Clearing flags on attachment: 180118

Committed r138135: <http://trac.webkit.org/changeset/138135>
Comment 11 WebKit Review Bot 2012-12-19 02:40:27 PST
All reviewed patches have been landed.  Closing bug.