Title: [282880] trunk
- Revision
- 282880
- Author
- commit-qu...@webkit.org
- Date
- 2021-09-22 10:19:36 -0700 (Wed, 22 Sep 2021)
Log Message
Source/WebCore:
RenderBox is a RenderElement which can have image updates from style changes. We should call
the base class imageChanged method and handle image changes appropriately in RenderListMarker.
https://bugs.webkit.org/show_bug.cgi?id=230431
Patch by Gabriel Nava Marino <gnavamar...@apple.com> on 2021-09-22
Reviewed by Darin Adler.
Test: fast/lists/list-marker-image-changed.html
* rendering/RenderListMarker.cpp:
(WebCore::RenderListMarker::imageChanged):
LayoutTests:
RenderListMarker::imageChanged RenderBox image handling
https://bugs.webkit.org/show_bug.cgi?id=230431
Patch by Gabriel Nava Marino <gnavamar...@apple.com> on 2021-09-22
Reviewed by Darin Adler.
* fast/lists/list-marker-image-changed-expected.txt: Added.
* fast/lists/list-marker-image-changed.html: Added.
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (282879 => 282880)
--- trunk/LayoutTests/ChangeLog 2021-09-22 17:07:21 UTC (rev 282879)
+++ trunk/LayoutTests/ChangeLog 2021-09-22 17:19:36 UTC (rev 282880)
@@ -1,3 +1,13 @@
+2021-09-22 Gabriel Nava Marino <gnavamar...@apple.com>
+
+ RenderListMarker::imageChanged RenderBox image handling
+ https://bugs.webkit.org/show_bug.cgi?id=230431
+
+ Reviewed by Darin Adler.
+
+ * fast/lists/list-marker-image-changed-expected.txt: Added.
+ * fast/lists/list-marker-image-changed.html: Added.
+
2021-09-22 Philippe Normand <pnorm...@igalia.com>
[Flatpak SDK] Switch runtime to 21.08 SDK
Added: trunk/LayoutTests/fast/lists/list-marker-image-changed-expected.txt (0 => 282880)
--- trunk/LayoutTests/fast/lists/list-marker-image-changed-expected.txt (rev 0)
+++ trunk/LayoutTests/fast/lists/list-marker-image-changed-expected.txt 2021-09-22 17:19:36 UTC (rev 282880)
@@ -0,0 +1 @@
+PASS
Added: trunk/LayoutTests/fast/lists/list-marker-image-changed.html (0 => 282880)
--- trunk/LayoutTests/fast/lists/list-marker-image-changed.html (rev 0)
+++ trunk/LayoutTests/fast/lists/list-marker-image-changed.html 2021-09-22 17:19:36 UTC (rev 282880)
@@ -0,0 +1,17 @@
+<style>
+ @keyframes a0 {
+ from {
+ -webkit-mask-box-image-source: url()
+ }
+ }
+ :not(:target)::marker {
+ animation-name: a0;
+ animation-duration: 1ms;
+ }
+</style>
+<li>PASS</li>
+<script>
+ if (window.testRunner) {
+ testRunner.dumpAsText();
+ }
+</script>
Modified: trunk/Source/WebCore/ChangeLog (282879 => 282880)
--- trunk/Source/WebCore/ChangeLog 2021-09-22 17:07:21 UTC (rev 282879)
+++ trunk/Source/WebCore/ChangeLog 2021-09-22 17:19:36 UTC (rev 282880)
@@ -1,3 +1,16 @@
+2021-09-22 Gabriel Nava Marino <gnavamar...@apple.com>
+
+ RenderBox is a RenderElement which can have image updates from style changes. We should call
+ the base class imageChanged method and handle image changes appropriately in RenderListMarker.
+ https://bugs.webkit.org/show_bug.cgi?id=230431
+
+ Reviewed by Darin Adler.
+
+ Test: fast/lists/list-marker-image-changed.html
+
+ * rendering/RenderListMarker.cpp:
+ (WebCore::RenderListMarker::imageChanged):
+
2021-09-22 Simon Fraser <simon.fra...@apple.com>
Remove ENABLE(SMOOTH_SCROLLING)
Modified: trunk/Source/WebCore/rendering/RenderListMarker.cpp (282879 => 282880)
--- trunk/Source/WebCore/rendering/RenderListMarker.cpp 2021-09-22 17:07:21 UTC (rev 282879)
+++ trunk/Source/WebCore/rendering/RenderListMarker.cpp 2021-09-22 17:19:36 UTC (rev 282880)
@@ -1797,16 +1797,15 @@
clearNeedsLayout();
}
-void RenderListMarker::imageChanged(WrappedImagePtr o, const IntRect*)
+void RenderListMarker::imageChanged(WrappedImagePtr o, const IntRect* rect)
{
- // A list marker can't have a background or border image, so no need to call the base class method.
- if (o != m_image->data())
- return;
-
- if (width() != m_image->imageSize(this, style().effectiveZoom()).width() || height() != m_image->imageSize(this, style().effectiveZoom()).height() || m_image->errorOccurred())
- setNeedsLayoutAndPrefWidthsRecalc();
- else
- repaint();
+ if (m_image && o == m_image->data()) {
+ if (width() != m_image->imageSize(this, style().effectiveZoom()).width() || height() != m_image->imageSize(this, style().effectiveZoom()).height() || m_image->errorOccurred())
+ setNeedsLayoutAndPrefWidthsRecalc();
+ else
+ repaint();
+ }
+ RenderBox::imageChanged(o, rect);
}
void RenderListMarker::updateMarginsAndContent()
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes