Web Inspector: Sources: add a special breakpoint for controlling whether debugger
statements pause
https://bugs.webkit.org/show_bug.cgi?id=206818
Reviewed by Timothy Hatcher.
Source/JavaScriptCore:
- inspector/protocol/Debugger.json:
- inspector/agents/InspectorDebuggerAgent.h:
- inspector/agents/InspectorDebuggerAgent.cpp:
(Inspector::InspectorDebuggerAgent::setPauseOnDebuggerStatements): Added.
- bytecompiler/NodesCodegen.cpp:
(JSC::DebuggerStatementNode::emitBytecode):
(JSC::CodeBlock::finishCreation):
- bytecode/UnlinkedCodeBlock.cpp:
(JSC::dumpLineColumnEntry):
- interpreter/Interpreter.h:
- interpreter/Interpreter.cpp:
(JSC::Interpreter::debug):
(WTF::printInternal):
(JSC::Debugger::setPauseOnDebuggerStatements): Added.
(JSC::Debugger::didReachDebuggerStatement): Added.
(JSC::Debugger::didReachBreakpoint): Deleted.
Replace DebugHookType::DidReachBreakpoint
with DebugHookType::DidReachDebuggerStatement
,
as it is only actually used for debugger;
statements, not breakpoints.
Source/WebInspectorUI:
- UserInterface/Controllers/DebuggerManager.js:
(WI.DebuggerManager):
(WI.DebuggerManager.prototype.async initializeTarget):
(WI.DebuggerManager.prototype.get debuggerStatementsBreakpoint): Added.
(WI.DebuggerManager.prototype.isBreakpointRemovable):
(WI.DebuggerManager.prototype._breakpointDisabledStateDidChange):
- UserInterface/Views/SourcesNavigationSidebarPanel.js:
(WI.SourcesNavigationSidebarPanel):
(WI.SourcesNavigationSidebarPanel.prototype._insertDebuggerTreeElement):
(WI.SourcesNavigationSidebarPanel.prototype._addBreakpoint):
- UserInterface/Views/BreakpointTreeElement.css:
(.breakpoint-debugger-statement-icon .icon): Added.
- UserInterface/Images/DebuggerStatement.svg: Added.
- Localizations/en.lproj/localizedStrings.js:
LayoutTests:
- inspector/debugger/setPauseOnDebuggerStatements.html: Added.
- inspector/debugger/setPauseOnDebuggerStatements-expected.txt: Added.