Skip to content
Permalink
Browse files
Web Inspector: breakpoints enabled state is not persisted across re-o…
…pening the inspector

https://bugs.webkit.org/show_bug.cgi?id=135745

Patch by Joseph Pecoraro <pecoraro@apple.com> on 2014-08-07
Reviewed by Timothy Hatcher.

When restoring breakpoints when the inspector is initializing, do not
let setting these breakpoints automatically enable breakpoints. We should
respect the setting in this case.

* UserInterface/Controllers/DebuggerManager.js:
(WebInspector.DebuggerManager.restoreBreakpointsSoon):
(WebInspector.DebuggerManager):

Canonical link: https://commits.webkit.org/153624@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@172333 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
JosephPecoraro authored and webkit-commit-queue committed Aug 8, 2014
1 parent af0eccf commit edde07190d1da980827021d310f2c23f8add1b94
Showing 2 changed files with 22 additions and 3 deletions.
@@ -1,3 +1,18 @@
2014-08-07 Joseph Pecoraro <pecoraro@apple.com>

Web Inspector: breakpoints enabled state is not persisted across re-opening the inspector
https://bugs.webkit.org/show_bug.cgi?id=135745

Reviewed by Timothy Hatcher.

When restoring breakpoints when the inspector is initializing, do not
let setting these breakpoints automatically enable breakpoints. We should
respect the setting in this case.

* UserInterface/Controllers/DebuggerManager.js:
(WebInspector.DebuggerManager.restoreBreakpointsSoon):
(WebInspector.DebuggerManager):

2014-08-07 Timothy Hatcher <timothy@apple.com>

Web Inspector: Combine and minify Esprima
@@ -67,8 +67,10 @@ WebInspector.DebuggerManager = function()
this._updateBreakOnExceptionsState();

function restoreBreakpointsSoon() {
this._restoringBreakpoints = true;
for (var cookie of this._breakpointsSetting.value)
this.addBreakpoint(new WebInspector.Breakpoint(cookie));
delete this._restoringBreakpoints;
}

// Ensure that all managers learn about restored breakpoints,
@@ -523,9 +525,11 @@ WebInspector.DebuggerManager.prototype = {
if (breakpoint.identifier || breakpoint.disabled)
return;

// Enable breakpoints since a breakpoint is being set. This eliminates
// a multi-step process for the user that can be confusing.
this.breakpointsEnabled = true;
if (!this._restoringBreakpoints) {
// Enable breakpoints since a breakpoint is being set. This eliminates
// a multi-step process for the user that can be confusing.
this.breakpointsEnabled = true;
}

function didSetBreakpoint(error, breakpointIdentifier, locations)
{

0 comments on commit edde071

Please sign in to comment.