[Webkit-unassigned] [Bug 30659] Web Inspector: Leftover Breakpoints in the Sidebar Pane
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Nov 2 21:17:36 PST 2009
https://bugs.webkit.org/show_bug.cgi?id=30659
Patrick Mueller <pmuellr at yahoo.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |pmuellr at yahoo.com
--- Comment #2 from Patrick Mueller <pmuellr at yahoo.com> 2009-11-02 21:17:35 PDT ---
I have a fix for this that I haven't fully investigated yet. In
ScriptsPanel.addScript(), I changed the logic to not just update the sourceID
for existing breakpoints, but to delete the old ones, and add new ones. Code
now looks like this:
if (sourceURL in this._breakpointsURLMap && sourceID) {
var breakpoints = this._breakpointsURLMap[sourceURL];
var breakpointsLength = breakpoints.length;
for (var i = 0; i < breakpointsLength; ++i) {
var breakpoint = breakpoints[i];
var enabled = breakpoint.enabled;
this.removeBreakpoint(breakpoint);
if (startingLine <= breakpoint.line) {
breakpoint = new WebInspector.Breakpoint(breakpoint.url,
breakpoint.line, sourceID, breakpoint.condition);
this.addBreakpoint(breakpoint);
breakpoint.enabled = enabled;
}
}
}
Fixes the problem for me.
Looking at the code, it appears there are bits of breakpoint goop all over the
place; it would be nice to have this a little more centralized, somehow. I
would have expected most of the breakpoint logic to actually be in
BreakPoint.js, but in fact that class pretty much just handles breakpoint
state, and none of the interesting behavior.
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list