Bug 156385

Summary: Web Inspector: Attempting to dismiss a popover that is already being dismissed causes an error
Product: WebKit Reporter: Matt Baker <mattbaker>
Component: Web InspectorAssignee: Matt Baker <mattbaker>
Status: RESOLVED FIXED    
Severity: Normal CC: bburg, commit-queue, graouts, joepeck, mattbaker, nvasilyev, timothy, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: All   
OS: All   
Attachments:
Description Flags
[Patch] Proposed Fix
none
[Patch] Proposed Fix none

Description Matt Baker 2016-04-07 20:23:12 PDT
* SUMMARY
Attempting to dismiss a popover that is already being dismissed causes an error.

* STEPS TO REPRODUCE
1. Set breakpoint, open Edit Breakpoint popover
2. Condition field has the focus. Hit Enter twice in quick succession.
  => BreakpointPopoverController.js:249:22: CONSOLE ERROR TypeError: null is not an object (evaluating 'this._popover.dismiss')

1. Debugger tab > Scope Chain sidebar panel > Add Watch Expression
2. Condition field has the focus. Hit Enter twice in quick succession.
  => ScopeChainDetailsSidebarPanel.js:453:46: CONSOLE ERROR TypeError: null is not an object (evaluating 'this._codeMirror.getValue')
Comment 1 Radar WebKit Bug Importer 2016-04-07 20:23:26 PDT
<rdar://problem/25617962>
Comment 2 Matt Baker 2016-04-07 20:34:04 PDT
Created attachment 275973 [details]
[Patch] Proposed Fix
Comment 3 BJ Burg 2016-04-07 20:42:14 PDT
Comment on attachment 275973 [details]
[Patch] Proposed Fix

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

Is the dismissing flag ever cleared when the animation completes? Or do you rely on later present() calls to reset it? It seems weird to have the dismissing flag always true even once it's out of the DOM.

> Source/WebInspectorUI/ChangeLog:24
> +2016-04-07  Matt Baker  <mattbaker@apple.com>

You made a double changelog.
Comment 4 Matt Baker 2016-04-08 01:50:46 PDT
Created attachment 275984 [details]
[Patch] Proposed Fix
Comment 5 WebKit Commit Bot 2016-04-08 09:05:20 PDT
Comment on attachment 275984 [details]
[Patch] Proposed Fix

Clearing flags on attachment: 275984

Committed r199227: <http://trac.webkit.org/changeset/199227>
Comment 6 WebKit Commit Bot 2016-04-08 09:05:24 PDT
All reviewed patches have been landed.  Closing bug.