WebKit Bugzilla
Attachment 362664 Details for
Bug 192963
: REGRESSION(r?): Web Inspector: Popovers have inset shadows
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-192963-20190221162304.patch (text/plain), 3.96 KB, created by
Devin Rousso
on 2019-02-21 16:23:05 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Devin Rousso
Created:
2019-02-21 16:23:05 PST
Size:
3.96 KB
patch
obsolete
>diff --git a/Source/WebInspectorUI/ChangeLog b/Source/WebInspectorUI/ChangeLog >index fce7a3e86b94317037527189770742a439698881..06870db30875d480d0a0941110e0e925885b7788 100644 >--- a/Source/WebInspectorUI/ChangeLog >+++ b/Source/WebInspectorUI/ChangeLog >@@ -1,3 +1,17 @@ >+2019-02-21 Devin Rousso <drousso@apple.com> >+ >+ REGRESSION(r?): Web Inspector: Popovers have inset shadows >+ https://bugs.webkit.org/show_bug.cgi?id=192963 >+ <rdar://problem/46888679> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * UserInterface/Views/Popover.js: >+ (WI.Popover.prototype._drawBackground): >+ (WI.Popover.prototype._drawBackground.isolate): Added. >+ * UserInterface/Views/Popover.css: >+ (.popover): >+ > 2019-02-21 Devin Rousso <drousso@apple.com> > > Web Inspector: Canvas: recordings with a single frame sometimes missing TreeElement >diff --git a/Source/WebInspectorUI/UserInterface/Views/Popover.css b/Source/WebInspectorUI/UserInterface/Views/Popover.css >index 0431803354bb59690fb70aee42afc5ba4b6d0ae6..e08b2a7fd2d2c7e6a1999820e427a5f4695868cb 100644 >--- a/Source/WebInspectorUI/UserInterface/Views/Popover.css >+++ b/Source/WebInspectorUI/UserInterface/Views/Popover.css >@@ -31,7 +31,6 @@ > pointer-events: none; > z-index: var(--z-index-popover); > >- --popover-text-color: black; > --popover-background-color: var(--panel-background-color); > --popover-border-color: hsla(0, 0%, 0%, 0.25); > --popover-shadow-color: hsla(0, 0%, 0%, 0.5); >diff --git a/Source/WebInspectorUI/UserInterface/Views/Popover.js b/Source/WebInspectorUI/UserInterface/Views/Popover.js >index 876f15b72ef5c8e8d3a5be5e7b44709f3b2ffca2..2618f1b66a3350757d6778021dc7a7e9c86d8998 100644 >--- a/Source/WebInspectorUI/UserInterface/Views/Popover.js >+++ b/Source/WebInspectorUI/UserInterface/Views/Popover.js >@@ -421,30 +421,32 @@ WI.Popover = class Popover extends WI.Object > let computedStyle = window.getComputedStyle(this._element, null); > > let context = document.getCSSCanvasContext("2d", "popover", scaledWidth, scaledHeight); >- context.save(); > context.clearRect(0, 0, scaledWidth, scaledHeight); >- context.shadowOffsetX = 1; >- context.shadowOffsetY = 1; >- context.shadowBlur = 5; >- context.shadowColor = computedStyle.getPropertyValue("--popover-shadow-color").trim(); >- context.scale(scaleFactor, scaleFactor); > >- // Clip the frame. >- context.fillStyle = computedStyle.getPropertyValue("--popover-text-color").trim(); >- this._drawFrame(context, bounds, this._edge, this._anchorPoint); >- context.clip(); >+ function isolate(callback) { >+ context.save(); >+ callback(); >+ context.restore(); >+ } > >- // Panel background color fill. >- context.fillStyle = computedStyle.getPropertyValue("--popover-background-color").trim(); >+ isolate(() => { >+ context.scale(scaleFactor, scaleFactor); >+ this._drawFrame(context, bounds, this._edge, this._anchorPoint); > >- context.fillRect(0, 0, width, height); >+ isolate(() => { >+ context.shadowBlur = 4; >+ context.shadowColor = computedStyle.getPropertyValue("--popover-shadow-color").trim(); > >- // Stroke. >- context.strokeStyle = computedStyle.getPropertyValue("--popover-border-color").trim(); >- context.lineWidth = 2; >- this._drawFrame(context, bounds, this._edge, this._anchorPoint); >- context.stroke(); >- context.restore(); >+ context.strokeStyle = computedStyle.getPropertyValue("--popover-border-color").trim(); >+ context.lineWidth = 2; >+ context.stroke(); >+ }); >+ >+ isolate(() => { >+ context.fillStyle = computedStyle.getPropertyValue("--popover-background-color").trim(); >+ context.fill(); >+ }); >+ }); > } > > _bestMetricsForEdge(preferredSize, targetFrame, containerFrame, edge)
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 192963
:
357905
| 362664 |
362665
|
362666