[webkit-reviews] review granted: [Bug 193218] Web Inspector: Styles: clicking on property that soon to be discarded shouldn't start selection : [Attachment 358542] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Jan 8 18:54:22 PST 2019


Devin Rousso <drousso at apple.com> has granted Nikita Vasilyev
<nvasilyev at apple.com>'s request for review:
Bug 193218: Web Inspector: Styles: clicking on property that soon to be
discarded shouldn't start selection
https://bugs.webkit.org/show_bug.cgi?id=193218

Attachment 358542: Patch

https://bugs.webkit.org/attachment.cgi?id=358542&action=review




--- Comment #7 from Devin Rousso <drousso at apple.com> ---
Comment on attachment 358542
  --> https://bugs.webkit.org/attachment.cgi?id=358542
Patch

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

r=me, nice refactor/fix

>
Source/WebInspectorUI/UserInterface/Views/SpreadsheetCSSStyleDeclarationSection
.js:414
> +	       this._stopSelection();

Rather than set `_isMousePressed` to `true` and then almost immediately reset
it back to `false`, could we early return:

    if (!propertyElement || !propertyElement.parentNode)


More information about the webkit-reviews mailing list