Title: [112686] branches/chromium/1084
- Revision
- 112686
- Author
- [email protected]
- Date
- 2012-03-30 10:32:18 -0700 (Fri, 30 Mar 2012)
Log Message
Merge 112379 - Web Inspector: breakpoints are not shown in sidebar pane after reload.
https://bugs.webkit.org/show_bug.cgi?id=82351
Reviewed by Pavel Feldman.
Source/WebCore:
When UISourceCode is added to ScriptsPanel, it could already have breakpoints.
We should iterate over existing breakpoints and add them to sidebar pane.
* inspector/front-end/ScriptsPanel.js:
(WebInspector.ScriptsPanel.prototype._uiSourceCodeAdded):
LayoutTests:
* inspector/debugger/set-breakpoint-expected.txt:
* inspector/debugger/set-breakpoint.html:
[email protected]
BUG=120853
Review URL: https://chromiumcodereview.appspot.com/9958020
Modified Paths
Diff
Modified: branches/chromium/1084/LayoutTests/inspector/debugger/set-breakpoint-expected.txt (112685 => 112686)
--- branches/chromium/1084/LayoutTests/inspector/debugger/set-breakpoint-expected.txt 2012-03-30 17:31:33 UTC (rev 112685)
+++ branches/chromium/1084/LayoutTests/inspector/debugger/set-breakpoint-expected.txt 2012-03-30 17:32:18 UTC (rev 112686)
@@ -8,6 +8,14 @@
Script execution paused.
Call stack:
0) testFunction (set-breakpoint.html:17)
+
+Dump breakpoint sidebar pane:
+
+ set-breakpoint.html:17
+ var x = Math.sqrt(10);
+
+Dump breakpoint sidebar pane:
+
Script execution resumed.
Running: testSetBreakpointOnTheLastLine
Modified: branches/chromium/1084/LayoutTests/inspector/debugger/set-breakpoint.html (112685 => 112686)
--- branches/chromium/1084/LayoutTests/inspector/debugger/set-breakpoint.html 2012-03-30 17:31:33 UTC (rev 112685)
+++ branches/chromium/1084/LayoutTests/inspector/debugger/set-breakpoint.html 2012-03-30 17:32:18 UTC (rev 112686)
@@ -39,6 +39,7 @@
{
InspectorTest.addResult("Script execution paused.");
InspectorTest.captureStackTrace(callFrames);
+ dumpBreakpointSidebarPane()
InspectorTest.addSniffer(currentSourceFrame, "removeBreakpoint", breakpointRemoved);
InspectorTest.removeBreakpoint(currentSourceFrame, 16);
}
@@ -50,6 +51,7 @@
function didResume()
{
+ dumpBreakpointSidebarPane()
InspectorTest.addResult("Script execution resumed.");
next();
}
@@ -114,6 +116,14 @@
}
}
]);
+
+ function dumpBreakpointSidebarPane()
+ {
+ var paneElement = WebInspector.panels.scripts.sidebarPanes.jsBreakpoints.listElement
+ InspectorTest.addResult("");
+ InspectorTest.addResult("Dump breakpoint sidebar pane:");
+ InspectorTest.addResult(InspectorTest.textContentWithLineBreaks(paneElement));
+ }
}
</script>
Modified: branches/chromium/1084/Source/WebCore/inspector/front-end/ScriptsPanel.js (112685 => 112686)
--- branches/chromium/1084/Source/WebCore/inspector/front-end/ScriptsPanel.js 2012-03-30 17:31:33 UTC (rev 112685)
+++ branches/chromium/1084/Source/WebCore/inspector/front-end/ScriptsPanel.js 2012-03-30 17:32:18 UTC (rev 112686)
@@ -256,6 +256,10 @@
_uiSourceCodeAdded: function(event)
{
var uiSourceCode = /** @type {WebInspector.UISourceCode} */ event.data;
+
+ var breakpoints = uiSourceCode.breakpoints();
+ for (var lineNumber in breakpoints)
+ this._uiBreakpointAdded({ data: breakpoints[lineNumber] });
this._addBreakpointListeners(uiSourceCode);
if (!uiSourceCode.url || uiSourceCode.isSnippetEvaluation) {
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes