[webkit-changes] [289883] trunk

2022-02-16 Thread ajuma
Title: [289883] trunk








Revision 289883
Author aj...@chromium.org
Date 2022-02-16 01:29:18 -0800 (Wed, 16 Feb 2022)


Log Message
Floating point exception in RenderListBox::numVisibleItems
https://bugs.webkit.org/show_bug.cgi?id=229307

Reviewed by Mark Lam.

Source/WebCore:

FontMetrics::height can return a negative value when setAscent() is called with
with a value that is too large to be represented as an int. Prevent this by
making setAscent() ensure that m_intAscent is set to a non-negative value.

Test: fast/forms/listbox-zero-item-height.html

* platform/graphics/FontMetrics.h:
(WebCore::FontMetrics::setAscent):

LayoutTests:

* fast/forms/listbox-zero-item-height-expected.txt: Added.
* fast/forms/listbox-zero-item-height.html: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/platform/graphics/FontMetrics.h


Added Paths

trunk/LayoutTests/fast/forms/listbox-zero-item-height-expected.txt
trunk/LayoutTests/fast/forms/listbox-zero-item-height.html




Diff

Modified: trunk/LayoutTests/ChangeLog (289882 => 289883)

--- trunk/LayoutTests/ChangeLog	2022-02-16 09:19:57 UTC (rev 289882)
+++ trunk/LayoutTests/ChangeLog	2022-02-16 09:29:18 UTC (rev 289883)
@@ -1,3 +1,13 @@
+2022-02-16  Ali Juma  
+
+Floating point exception in RenderListBox::numVisibleItems
+https://bugs.webkit.org/show_bug.cgi?id=229307
+
+Reviewed by Mark Lam.
+
+* fast/forms/listbox-zero-item-height-expected.txt: Added.
+* fast/forms/listbox-zero-item-height.html: Added.
+
 2022-02-16  Jon Lee  
 
 Reset GPU Process TestExpectations after accelerated drawing is enabled.


Added: trunk/LayoutTests/fast/forms/listbox-zero-item-height-expected.txt (0 => 289883)

--- trunk/LayoutTests/fast/forms/listbox-zero-item-height-expected.txt	(rev 0)
+++ trunk/LayoutTests/fast/forms/listbox-zero-item-height-expected.txt	2022-02-16 09:29:18 UTC (rev 289883)
@@ -0,0 +1,3 @@
+This test passes if it doesn't crash.
+
+


Added: trunk/LayoutTests/fast/forms/listbox-zero-item-height.html (0 => 289883)

--- trunk/LayoutTests/fast/forms/listbox-zero-item-height.html	(rev 0)
+++ trunk/LayoutTests/fast/forms/listbox-zero-item-height.html	2022-02-16 09:29:18 UTC (rev 289883)
@@ -0,0 +1,17 @@
+
+
+if (window.testRunner) {
+testRunner.dumpAsText();
+}
+
+
+
+  *{zoom:4000;}
+
+
+
+  
+This test passes if it doesn't crash.
+
+  
+
\ No newline at end of file


Modified: trunk/Source/WebCore/ChangeLog (289882 => 289883)

--- trunk/Source/WebCore/ChangeLog	2022-02-16 09:19:57 UTC (rev 289882)
+++ trunk/Source/WebCore/ChangeLog	2022-02-16 09:29:18 UTC (rev 289883)
@@ -1,3 +1,19 @@
+2022-02-16  Ali Juma  
+
+Floating point exception in RenderListBox::numVisibleItems
+https://bugs.webkit.org/show_bug.cgi?id=229307
+
+Reviewed by Mark Lam.
+
+FontMetrics::height can return a negative value when setAscent() is called with
+with a value that is too large to be represented as an int. Prevent this by
+making setAscent() ensure that m_intAscent is set to a non-negative value.
+
+Test: fast/forms/listbox-zero-item-height.html
+
+* platform/graphics/FontMetrics.h:
+(WebCore::FontMetrics::setAscent):
+
 2022-02-16  Wenson Hsieh  
 
 [macOS] Add an "Markup Image" item to the sharing services picker context menu


Modified: trunk/Source/WebCore/platform/graphics/FontMetrics.h (289882 => 289883)

--- trunk/Source/WebCore/platform/graphics/FontMetrics.h	2022-02-16 09:19:57 UTC (rev 289882)
+++ trunk/Source/WebCore/platform/graphics/FontMetrics.h	2022-02-16 09:29:18 UTC (rev 289883)
@@ -42,7 +42,7 @@
 void setAscent(float ascent)
 {
 m_floatAscent = ascent;
-m_intAscent = lroundf(ascent);
+m_intAscent = std::max(static_cast(lroundf(ascent)), 0);
 }
 
 float floatDescent(FontBaseline baselineType = AlphabeticBaseline) const






___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [284175] trunk

2021-10-14 Thread ajuma
Title: [284175] trunk








Revision 284175
Author aj...@chromium.org
Date 2021-10-14 10:54:42 -0700 (Thu, 14 Oct 2021)


Log Message
Add my GitHub username to contributors.json

Unreviewed.

* metadata/contributors.json:

Modified Paths

trunk/ChangeLog
trunk/metadata/contributors.json




Diff

Modified: trunk/ChangeLog (284174 => 284175)

--- trunk/ChangeLog	2021-10-14 17:53:03 UTC (rev 284174)
+++ trunk/ChangeLog	2021-10-14 17:54:42 UTC (rev 284175)
@@ -1,3 +1,11 @@
+2021-10-14  Ali Juma  
+
+Add my GitHub username to contributors.json
+
+Unreviewed.
+
+* metadata/contributors.json:
+
 2021-10-14  Víctor Manuel Jáquez Leal  
 
 Add my GitHub username to contributors.json


Modified: trunk/metadata/contributors.json (284174 => 284175)

--- trunk/metadata/contributors.json	2021-10-14 17:53:03 UTC (rev 284174)
+++ trunk/metadata/contributors.json	2021-10-14 17:54:42 UTC (rev 284175)
@@ -438,6 +438,7 @@
   "emails" : [
  "aj...@chromium.org"
   ],
+  "github" : "alijuma",
   "name" : "Ali Juma",
   "nicks" : [
  "ajuma"






___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [269752] trunk/Tools

2020-11-12 Thread ajuma
Title: [269752] trunk/Tools








Revision 269752
Author aj...@chromium.org
Date 2020-11-12 14:18:46 -0800 (Thu, 12 Nov 2020)


Log Message
configure-xcode-for-embedded-development breaks @available in Swift files
https://bugs.webkit.org/show_bug.cgi?id=218850

Reviewed by Jonathan Bedard.

The changes applied by configure-xcode-for-embedded-development
for AvailabilityProhibitedInternal.h cause API_AVAILABLE to be ignored
in Objective-C, but @available is not ignored in Swift. As a result,
if an Objective-C method marked with API_AVAILABLE makes a call
into a Swift class marked with @available, this can lead to an
availability warning even when the calling method is only available
when the callee is available.

To fix this, ensure that @available is also ignored in Swift.

* Scripts/configure-xcode-for-embedded-development:

Modified Paths

trunk/Tools/ChangeLog
trunk/Tools/Scripts/configure-xcode-for-embedded-development




Diff

Modified: trunk/Tools/ChangeLog (269751 => 269752)

--- trunk/Tools/ChangeLog	2020-11-12 22:12:21 UTC (rev 269751)
+++ trunk/Tools/ChangeLog	2020-11-12 22:18:46 UTC (rev 269752)
@@ -1,3 +1,22 @@
+2020-11-12  Ali Juma  
+
+configure-xcode-for-embedded-development breaks @available in Swift files
+https://bugs.webkit.org/show_bug.cgi?id=218850
+
+Reviewed by Jonathan Bedard.
+
+The changes applied by configure-xcode-for-embedded-development
+for AvailabilityProhibitedInternal.h cause API_AVAILABLE to be ignored
+in Objective-C, but @available is not ignored in Swift. As a result,
+if an Objective-C method marked with API_AVAILABLE makes a call
+into a Swift class marked with @available, this can lead to an
+availability warning even when the calling method is only available
+when the callee is available.
+
+To fix this, ensure that @available is also ignored in Swift.
+
+* Scripts/configure-xcode-for-embedded-development:
+
 2020-11-12  Chris Dumez  
 
 [GPUProcess] Add basic GPUProcess crash handling for media playback


Modified: trunk/Tools/Scripts/configure-xcode-for-embedded-development (269751 => 269752)

--- trunk/Tools/Scripts/configure-xcode-for-embedded-development	2020-11-12 22:12:21 UTC (rev 269751)
+++ trunk/Tools/Scripts/configure-xcode-for-embedded-development	2020-11-12 22:18:46 UTC (rev 269752)
@@ -97,6 +97,9 @@
 #undef __API_AVAILABLE_GET_MACRO
 #define __API_AVAILABLE_GET_MACRO(...) __NULL_AVAILABILITY
 
+#undef SWIFT_AVAILABILITY
+#define SWIFT_AVAILABILITY __NULL_AVAILABILITY
+
 // Take care of {A,S}PI_DEPRECATED{,WITH_REPLACEMENT}{,_BEGIN,_END}
 #undef __API_DEPRECATED_MSG_GET_MACRO
 #define __API_DEPRECATED_MSG_GET_MACRO(...) __NULL_AVAILABILITY






___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [258791] trunk/LayoutTests

2020-03-20 Thread ajuma
Title: [258791] trunk/LayoutTests








Revision 258791
Author aj...@chromium.org
Date 2020-03-20 14:54:46 -0700 (Fri, 20 Mar 2020)


Log Message
Intersection Observer intersections are wrong with zooming
https://bugs.webkit.org/show_bug.cgi?id=209264

Unreviewed test gardening.

Add an expected.txt file that was accidentally omitted in r258787.

* intersection-observer/root-margin-with-zoom-expected.txt: Added.

Modified Paths

trunk/LayoutTests/ChangeLog


Added Paths

trunk/LayoutTests/intersection-observer/root-margin-with-zoom-expected.txt




Diff

Modified: trunk/LayoutTests/ChangeLog (258790 => 258791)

--- trunk/LayoutTests/ChangeLog	2020-03-20 21:38:36 UTC (rev 258790)
+++ trunk/LayoutTests/ChangeLog	2020-03-20 21:54:46 UTC (rev 258791)
@@ -1,3 +1,14 @@
+2020-03-20  Ali Juma  
+
+Intersection Observer intersections are wrong with zooming
+https://bugs.webkit.org/show_bug.cgi?id=209264
+
+Unreviewed test gardening.
+
+Add an expected.txt file that was accidentally omitted in r258787.
+
+* intersection-observer/root-margin-with-zoom-expected.txt: Added.
+
 2020-03-20  David Kilzer  
 
 Fix name of "X-Content-Type:" HTTP header in console logging


Added: trunk/LayoutTests/intersection-observer/root-margin-with-zoom-expected.txt (0 => 258791)

--- trunk/LayoutTests/intersection-observer/root-margin-with-zoom-expected.txt	(rev 0)
+++ trunk/LayoutTests/intersection-observer/root-margin-with-zoom-expected.txt	2020-03-20 21:54:46 UTC (rev 258791)
@@ -0,0 +1,3 @@
+
+PASS IntersectionObserver's root margin accounts for zooming 
+






___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [258787] trunk

2020-03-20 Thread ajuma
Title: [258787] trunk








Revision 258787
Author aj...@chromium.org
Date 2020-03-20 13:58:54 -0700 (Fri, 20 Mar 2020)


Log Message
Intersection Observer intersections are wrong with zooming
https://bugs.webkit.org/show_bug.cgi?id=209264

Reviewed by Simon Fraser.

Source/WebCore:

An IntersectionObserver's rootMargin is expressed in CSS pixels,
but we weren't accounting for page zoom. Fix this by multiplying
the root margin by the zoom factor.

Test: intersection-observer/root-margin-with-zoom.html

* dom/Document.cpp:
(WebCore::expandRootBoundsWithRootMargin):
(WebCore::computeIntersectionState):

LayoutTests:

* intersection-observer/root-margin-with-zoom.html: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/dom/Document.cpp


Added Paths

trunk/LayoutTests/intersection-observer/root-margin-with-zoom.html




Diff

Modified: trunk/LayoutTests/ChangeLog (258786 => 258787)

--- trunk/LayoutTests/ChangeLog	2020-03-20 20:44:56 UTC (rev 258786)
+++ trunk/LayoutTests/ChangeLog	2020-03-20 20:58:54 UTC (rev 258787)
@@ -1,3 +1,12 @@
+2020-03-20  Ali Juma  
+
+Intersection Observer intersections are wrong with zooming
+https://bugs.webkit.org/show_bug.cgi?id=209264
+
+Reviewed by Simon Fraser.
+
+* intersection-observer/root-margin-with-zoom.html: Added.
+
 2020-03-20  Jason Lawrence  
 
 REGRESSION: (r258747) [ Mac wk1 Release ] media/video-background-tab-playback.html is failing.


Added: trunk/LayoutTests/intersection-observer/root-margin-with-zoom.html (0 => 258787)

--- trunk/LayoutTests/intersection-observer/root-margin-with-zoom.html	(rev 0)
+++ trunk/LayoutTests/intersection-observer/root-margin-with-zoom.html	2020-03-20 20:58:54 UTC (rev 258787)
@@ -0,0 +1,34 @@
+
+
+#target {
+position: absolute;
+height: 40px;
+width: 100px;
+top: -40px;
+background-color: green;
+}
+
+
+
+
+
+
+// The target is positioned 40 px above the viewport so should fully intersect
+// when the viewport is expanded by a root margin of 40 px, no matter what
+// page zoom factor is used, since page zoom should equally affect both the
+// positioning of the target and the size of the root margin.
+window.internals.setPageZoomFactor(2);
+async_test((t) =>  {
+let options = {
+rootMargin: '40px 0px 0px 0px',
+threshold: [1]
+}
+let observer = new IntersectionObserver(t.step_func_done((entries) => {
+assert_true(entries[0].isIntersecting, "isIntersecting"); 
+}), options);
+observer.observe(document.getElementById("target"));
+}, "IntersectionObserver's root margin accounts for zooming");
+


Modified: trunk/Source/WebCore/ChangeLog (258786 => 258787)

--- trunk/Source/WebCore/ChangeLog	2020-03-20 20:44:56 UTC (rev 258786)
+++ trunk/Source/WebCore/ChangeLog	2020-03-20 20:58:54 UTC (rev 258787)
@@ -1,3 +1,20 @@
+2020-03-20  Ali Juma  
+
+Intersection Observer intersections are wrong with zooming
+https://bugs.webkit.org/show_bug.cgi?id=209264
+
+Reviewed by Simon Fraser.
+
+An IntersectionObserver's rootMargin is expressed in CSS pixels,
+but we weren't accounting for page zoom. Fix this by multiplying
+the root margin by the zoom factor.
+
+Test: intersection-observer/root-margin-with-zoom.html
+
+* dom/Document.cpp:
+(WebCore::expandRootBoundsWithRootMargin):
+(WebCore::computeIntersectionState):
+
 2020-03-20  Don Olmstead  
 
 [GPUP] Add PlatformLayerContainer to hold pointer to PlatformLayer


Modified: trunk/Source/WebCore/dom/Document.cpp (258786 => 258787)

--- trunk/Source/WebCore/dom/Document.cpp	2020-03-20 20:44:56 UTC (rev 258786)
+++ trunk/Source/WebCore/dom/Document.cpp	2020-03-20 20:58:54 UTC (rev 258787)
@@ -7488,13 +7488,13 @@
 m_intersectionObservers.removeFirst();
 }
 
-static void expandRootBoundsWithRootMargin(FloatRect& localRootBounds, const LengthBox& rootMargin)
+static void expandRootBoundsWithRootMargin(FloatRect& localRootBounds, const LengthBox& rootMargin, float zoomFactor)
 {
 FloatBoxExtent rootMarginFloatBox(
-floatValueForLength(rootMargin.top(), localRootBounds.height()),
-floatValueForLength(rootMargin.right(), localRootBounds.width()),
-floatValueForLength(rootMargin.bottom(), localRootBounds.height()),
-floatValueForLength(rootMargin.left(), localRootBounds.width())
+floatValueForLength(rootMargin.top(), localRootBounds.height()) * zoomFactor,
+floatValueForLength(rootMargin.right(), localRootBounds.width()) * zoomFactor,
+floatValueForLength(rootMargin.bottom(), localRootBounds.height()) * zoomFactor,
+floatValueForLength(rootMargin.left(), localRootBounds.width()) * zoomFactor
 );
 
 localRootBounds.expand(rootMarginFloatBox);
@@ -7560,7 +7560,7 @@
 }
 
 if (applyRootMargin)
-   

[webkit-changes] [255971] trunk

2020-02-06 Thread ajuma
Title: [255971] trunk








Revision 255971
Author aj...@chromium.org
Date 2020-02-06 11:54:37 -0800 (Thu, 06 Feb 2020)


Log Message
Crash in RenderTableCol::willBeRemovedFromTree()
https://bugs.webkit.org/show_bug.cgi?id=207031

Reviewed by Antti Koivisto.

Source/WebCore:

A RenderTableCol's table() can be null during willBeRemovedFromTree. This can
happen when the RenderTableCol's table is an ancestor rather than a direct
parent. If RenderTreeBuilder::destroy is then called on an ancestor of the
the RenderTableCol's table, RenderTreeBuilder::destroy proceeds down the ancestor
chain, detaching each node along the way. By the time the RenderTableCol is
reached, the table (a non-parent ancestor) has already been detached, so
table() is null and we crash while trying to use it.

The underlying bug is that RenderTreeBuilder::destroyAndCleanUpAnonymousWrappers
is getting called on the RenderTableCol's ancestor before its descendants (including
the RenderTableCol) are destroyed.

Fix this by changing the order of operations in RenderTreeUpdater::tearDownRenderers
so that tearDownLeftoverShadowHostChildren happens before destroyAndCleanUpAnonymousWrappers.
This ensures that the RenderTableCol is destroyed before destroyAndCleanUpAnonymousWrappers is
called on its ancestor.

Test: tables/table-col-indent-crash.html

* rendering/updating/RenderTreeUpdater.cpp:
(WebCore::RenderTreeUpdater::tearDownRenderers):

LayoutTests:

* tables/table-col-indent-crash-expected.txt: Added.
* tables/table-col-indent-crash.html: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/rendering/updating/RenderTreeUpdater.cpp


Added Paths

trunk/LayoutTests/tables/table-col-indent-crash-expected.txt
trunk/LayoutTests/tables/table-col-indent-crash.html




Diff

Modified: trunk/LayoutTests/ChangeLog (255970 => 255971)

--- trunk/LayoutTests/ChangeLog	2020-02-06 19:53:08 UTC (rev 255970)
+++ trunk/LayoutTests/ChangeLog	2020-02-06 19:54:37 UTC (rev 255971)
@@ -1,3 +1,13 @@
+2020-02-06  Ali Juma  
+
+Crash in RenderTableCol::willBeRemovedFromTree()
+https://bugs.webkit.org/show_bug.cgi?id=207031
+
+Reviewed by Antti Koivisto.
+
+* tables/table-col-indent-crash-expected.txt: Added.
+* tables/table-col-indent-crash.html: Added.
+
 2020-02-06  Jason Lawrence  
 
 Regression: (r255150?) [ Mac wk1 ] http/wpt/css/css-animations/start-animation-001.html is flaky failing.


Added: trunk/LayoutTests/tables/table-col-indent-crash-expected.txt (0 => 255971)

--- trunk/LayoutTests/tables/table-col-indent-crash-expected.txt	(rev 0)
+++ trunk/LayoutTests/tables/table-col-indent-crash-expected.txt	2020-02-06 19:54:37 UTC (rev 255971)
@@ -0,0 +1,3 @@
+ 
+This test passes if it doesn't crash.
+


Added: trunk/LayoutTests/tables/table-col-indent-crash.html (0 => 255971)

--- trunk/LayoutTests/tables/table-col-indent-crash.html	(rev 0)
+++ trunk/LayoutTests/tables/table-col-indent-crash.html	2020-02-06 19:54:37 UTC (rev 255971)
@@ -0,0 +1,25 @@
+
+   body { -webkit-user-modify: read-write; }
+
+
+
+window._onload_ = function() {
+if (window.testRunner)
+testRunner.dumpAsText();
+window.getSelection().setPosition(tableElement);
+document.execCommand("indent", false);
+document.execCommand("indent", false);
+}
+
+
+
+  
+  
+
+  
+
+This test passes if it doesn't crash.
+  
+
+  
+
\ No newline at end of file


Modified: trunk/Source/WebCore/ChangeLog (255970 => 255971)

--- trunk/Source/WebCore/ChangeLog	2020-02-06 19:53:08 UTC (rev 255970)
+++ trunk/Source/WebCore/ChangeLog	2020-02-06 19:54:37 UTC (rev 255971)
@@ -1,3 +1,32 @@
+2020-02-06  Ali Juma  
+
+Crash in RenderTableCol::willBeRemovedFromTree()
+https://bugs.webkit.org/show_bug.cgi?id=207031
+
+Reviewed by Antti Koivisto.
+
+A RenderTableCol's table() can be null during willBeRemovedFromTree. This can
+happen when the RenderTableCol's table is an ancestor rather than a direct
+parent. If RenderTreeBuilder::destroy is then called on an ancestor of the
+the RenderTableCol's table, RenderTreeBuilder::destroy proceeds down the ancestor
+chain, detaching each node along the way. By the time the RenderTableCol is
+reached, the table (a non-parent ancestor) has already been detached, so
+table() is null and we crash while trying to use it.
+
+The underlying bug is that RenderTreeBuilder::destroyAndCleanUpAnonymousWrappers
+is getting called on the RenderTableCol's ancestor before its descendants (including
+the RenderTableCol) are destroyed.
+
+Fix this by changing the order of operations in RenderTreeUpdater::tearDownRenderers
+so that tearDownLeftoverShadowHostChildren happens before destroyAndCleanUpAnonymousWrappers.
+This ensures that the RenderTableCol is destroyed before 

[webkit-changes] [253469] trunk

2019-12-13 Thread ajuma
Title: [253469] trunk








Revision 253469
Author aj...@chromium.org
Date 2019-12-13 06:32:55 -0800 (Fri, 13 Dec 2019)


Log Message
Crash in RenderLayerBacking::updateCompositedBounds from using cleared WeakPtr from m_backingSharingLayers
https://bugs.webkit.org/show_bug.cgi?id=204648

Reviewed by Simon Fraser.

Source/WebCore:

RenderLayerBacking's clearBackingSharingProviders clears layers'
backingSharingProviders unconditionally, even when a layer's
backingSharingProvider is some other RenderLayerBacking's owning
layer. This leaves the layer in a state where its backingProviderLayer
is null, even though it appears in the other RenderLayerBacking's
m_backingSharingLayers, which leads to a crash if this layer is destroyed
and the other RenderLayerBacking tries to use its pointer to this
layer.

Avoid this inconsistency by making clearBackingSharingProviders check
whether a layer's backingSharingProvider is the current RenderLayerBacking's
owner, before clearing it.

Test: compositing/shared-backing/move-sharing-child.html

* rendering/RenderLayerBacking.cpp:
(WebCore::clearBackingSharingLayerProviders):
(WebCore::RenderLayerBacking::setBackingSharingLayers):
(WebCore::RenderLayerBacking::clearBackingSharingLayers):

LayoutTests:

* compositing/shared-backing/move-sharing-child-expected.txt: Added.
* compositing/shared-backing/move-sharing-child.html: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/rendering/RenderLayerBacking.cpp


Added Paths

trunk/LayoutTests/compositing/shared-backing/move-sharing-child-expected.txt
trunk/LayoutTests/compositing/shared-backing/move-sharing-child.html




Diff

Modified: trunk/LayoutTests/ChangeLog (253468 => 253469)

--- trunk/LayoutTests/ChangeLog	2019-12-13 13:47:50 UTC (rev 253468)
+++ trunk/LayoutTests/ChangeLog	2019-12-13 14:32:55 UTC (rev 253469)
@@ -1,3 +1,13 @@
+2019-12-13  Ali Juma  
+
+Crash in RenderLayerBacking::updateCompositedBounds from using cleared WeakPtr from m_backingSharingLayers
+https://bugs.webkit.org/show_bug.cgi?id=204648
+
+Reviewed by Simon Fraser.
+
+* compositing/shared-backing/move-sharing-child-expected.txt: Added.
+* compositing/shared-backing/move-sharing-child.html: Added.
+
 2019-12-13  Carlos Garcia Campos  
 
 [GTK] Several tests crashing after r247898 "Reorganize UIScriptController into platform-specific subclasses"


Added: trunk/LayoutTests/compositing/shared-backing/move-sharing-child-expected.txt (0 => 253469)

--- trunk/LayoutTests/compositing/shared-backing/move-sharing-child-expected.txt	(rev 0)
+++ trunk/LayoutTests/compositing/shared-backing/move-sharing-child-expected.txt	2019-12-13 14:32:55 UTC (rev 253469)
@@ -0,0 +1,3 @@
+This test should not crash or assert.
+
+


Added: trunk/LayoutTests/compositing/shared-backing/move-sharing-child.html (0 => 253469)

--- trunk/LayoutTests/compositing/shared-backing/move-sharing-child.html	(rev 0)
+++ trunk/LayoutTests/compositing/shared-backing/move-sharing-child.html	2019-12-13 14:32:55 UTC (rev 253469)
@@ -0,0 +1,75 @@
+
+
+  Tests that there is no crash when a layer's backing provider layer changes
+  and the layer is then removed.
+ 
+
+
+   .positioned {
+   position: absolute;
+   left: 25px;
+   width: 100px;
+   height: 100px;
+   }
+
+   .composited {
+   transform: translateZ(0);
+   background-color: blue;
+   }
+
+   .stackingContext {
+   position: absolute;
+   z-index: 0;
+   }
+
+   #child1 {
+   background-color: orange;
+   }
+
+   #child2 {
+   background-color: yellow;
+   }
+
+   #grandchild {
+   background-color: pink;
+   }
+
+   #container {
+   background-color: green;
+   }
+
+
+
+if (window.testRunner) {
+testRunner.dumpAsText();
+testRunner.waitUntilDone();
+}
+
+function triggerLayout() {
+document.body.scrollTop;
+}
+
+window._onload_ = function() {
+triggerLayout();
+
+document.getElementById('container').classList.add("stackingContext");
+document.getElementById('child1').classList.add("composited");
+triggerLayout();
+
+document.getElementById('grandchild').classList.remove("positioned");
+triggerLayout();
+
+if (window.testRunner)
+testRunner.notifyDone();
+}
+
+
+This test should not crash or assert.
+
+
+
+
+
+
+
+


Modified: trunk/Source/WebCore/ChangeLog (253468 => 253469)

--- trunk/Source/WebCore/ChangeLog	2019-12-13 13:47:50 UTC (rev 253468)
+++ trunk/Source/WebCore/ChangeLog	2019-12-13 14:32:55 UTC (rev 253469)
@@ -1,3 +1,30 @@
+2019-12-13  Ali Juma  
+
+Crash in RenderLayerBacking::updateCompositedBounds from using cleared WeakPtr from m_backingSharingLayers
+https://bugs.webkit.org/show_bug.cgi?id=204648
+
+Reviewed by Simon Fraser.
+
+RenderLayerBacking's 

[webkit-changes] [250846] trunk/LayoutTests

2019-10-08 Thread ajuma
Title: [250846] trunk/LayoutTests








Revision 250846
Author aj...@chromium.org
Date 2019-10-08 11:58:52 -0700 (Tue, 08 Oct 2019)


Log Message
Unreviewed test gardening

* TestExpectations:

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/LayoutTests/TestExpectations




Diff

Modified: trunk/LayoutTests/ChangeLog (250845 => 250846)

--- trunk/LayoutTests/ChangeLog	2019-10-08 18:54:01 UTC (rev 250845)
+++ trunk/LayoutTests/ChangeLog	2019-10-08 18:58:52 UTC (rev 250846)
@@ -1,3 +1,9 @@
+2019-10-08  Ali Juma  
+
+Unreviewed test gardening
+
+* TestExpectations:
+
 2019-10-08  Jiewen Tan  
 
 Unreviewed, test gardening


Modified: trunk/LayoutTests/TestExpectations (250845 => 250846)

--- trunk/LayoutTests/TestExpectations	2019-10-08 18:54:01 UTC (rev 250845)
+++ trunk/LayoutTests/TestExpectations	2019-10-08 18:58:52 UTC (rev 250846)
@@ -396,6 +396,7 @@
 imported/w3c/web-platform-tests/html/browsers/history/the-history-interface/combination_history_002.html [ Failure Pass ]
 imported/w3c/web-platform-tests/html/browsers/history/the-history-interface/combination_history_003.html [ Failure Pass ]
 imported/w3c/web-platform-tests/html/semantics/scripting-1/the-script-element/execution-timing/058.html [ Failure Pass ]
+imported/w3c/web-platform-tests/html/interaction/focus/the-autofocus-attribute/update-the-rendering.html [ Failure Pass ]
 
 imported/w3c/web-platform-tests/fetch/api/basic/mode-same-origin.any.html [ DumpJSConsoleLogInStdErr ]
 imported/w3c/web-platform-tests/fetch/api/basic/scheme-about.any.html [ DumpJSConsoleLogInStdErr ]






___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [250823] trunk/LayoutTests

2019-10-08 Thread ajuma
Title: [250823] trunk/LayoutTests








Revision 250823
Author aj...@chromium.org
Date 2019-10-08 06:56:50 -0700 (Tue, 08 Oct 2019)


Log Message
Import autofocus Web Platform Tests
https://bugs.webkit.org/show_bug.cgi?id=202641

Reviewed by Ryosuke Niwa.

LayoutTests/imported/w3c:

Import web platform tests for autofocus, and remove duplicated test from
http/wpt/html/semantics/forms/autofocus.

* resources/import-expectations.json:
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/autofocus-in-not-fully-active-document-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/autofocus-in-not-fully-active-document.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/autofocus-on-stable-document-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/autofocus-on-stable-document.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/first-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/first-reconnected-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/first-reconnected.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/first-when-later-but-before-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/first-when-later-but-before.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/first-when-later-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/first-when-later.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/first.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/focusable-area-in-top-document-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/focusable-area-in-top-document.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/no-cross-origin-autofocus-expected.txt: Renamed from LayoutTests/http/wpt/html/semantics/forms/autofocus/no-cross-origin-autofocus.sub-expected.txt.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/no-cross-origin-autofocus.html: Copied from LayoutTests/http/wpt/html/semantics/forms/autofocus/no-cross-origin-autofocus.sub.html.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/no-sandboxed-automatic-features-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/no-sandboxed-automatic-features.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/not-on-first-task-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/not-on-first-task.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/queue-non-focusable-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/queue-non-focusable.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/resources/child-autofocus.html: Renamed from LayoutTests/http/wpt/html/semantics/forms/autofocus/resources/child-autofocus.html.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/resources/child-iframe.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/resources/erase-first.css: Added.
(#first):
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/resources/frame-with-autofocus-element.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/resources/grand-child-autofocus.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/resources/moving-autofocus-to-parent.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/resources/utils.js: Added.
(waitForEvent):
(timeOut):
(async.waitUntilStableAutofocusState):
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/resources/w3c-import.log: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/same-origin-autofocus-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/same-origin-autofocus.html: Renamed from LayoutTests/http/wpt/html/semantics/forms/autofocus/no-cross-origin-autofocus.sub.html.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/skip-another-top-level-browsing-context-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/skip-another-top-level-browsing-context.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/skip-document-with-fragment-expected.txt: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/skip-document-with-fragment.html: Added.
* web-platform-tests/html/interaction/focus/the-autofocus-attribute/skip-non-focusable-expected.txt: Added.
* 

[webkit-changes] [249845] trunk

2019-09-13 Thread ajuma
Title: [249845] trunk








Revision 249845
Author aj...@chromium.org
Date 2019-09-13 11:46:56 -0700 (Fri, 13 Sep 2019)


Log Message
IntersectionObserverEntry#intersectionRatio can be larger than 1
https://bugs.webkit.org/show_bug.cgi?id=200776

Reviewed by Simon Fraser.

Source/WebCore:

When computing the intersection between a target and an intersection observer's
root, RenderBox::computeVisibleRectInContainer is used to map the target rect
up the containing block chain, clipping along the way. When a RenderBox has
a transform, this method expands the given rect to the enclosing rect in device
pixels. This is fine for the use case of computing an invalidation rect, but for
the intersection observer use case it means that it is possible for the computed
intersection rect to be slightly larger than the original target rect, resulting
in an intersection ratio greater than 1.

Fix this by performing a final intersection between the intersection rect as
computed above and the target rect.

Test: intersection-observer/intersection-clipped-to-target.html

* dom/Document.cpp:
(WebCore::computeIntersectionState):

LayoutTests:

* intersection-observer/intersection-clipped-to-target-expected.txt: Added.
* intersection-observer/intersection-clipped-to-target.html: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/dom/Document.cpp


Added Paths

trunk/LayoutTests/intersection-observer/intersection-clipped-to-target-expected.txt
trunk/LayoutTests/intersection-observer/intersection-clipped-to-target.html




Diff

Modified: trunk/LayoutTests/ChangeLog (249844 => 249845)

--- trunk/LayoutTests/ChangeLog	2019-09-13 18:46:32 UTC (rev 249844)
+++ trunk/LayoutTests/ChangeLog	2019-09-13 18:46:56 UTC (rev 249845)
@@ -1,3 +1,13 @@
+2019-09-13  Ali Juma  
+
+IntersectionObserverEntry#intersectionRatio can be larger than 1
+https://bugs.webkit.org/show_bug.cgi?id=200776
+
+Reviewed by Simon Fraser.
+
+* intersection-observer/intersection-clipped-to-target-expected.txt: Added.
+* intersection-observer/intersection-clipped-to-target.html: Added.
+
 2019-09-13  Russell Epstein  
 
 Layout Test http/tests/appcache/remove-cache.html is a flaky failure.


Added: trunk/LayoutTests/intersection-observer/intersection-clipped-to-target-expected.txt (0 => 249845)

--- trunk/LayoutTests/intersection-observer/intersection-clipped-to-target-expected.txt	(rev 0)
+++ trunk/LayoutTests/intersection-observer/intersection-clipped-to-target-expected.txt	2019-09-13 18:46:56 UTC (rev 249845)
@@ -0,0 +1,3 @@
+
+PASS IntersectionObserverEntry's intersection rect is not larger than the target rect 
+


Added: trunk/LayoutTests/intersection-observer/intersection-clipped-to-target.html (0 => 249845)

--- trunk/LayoutTests/intersection-observer/intersection-clipped-to-target.html	(rev 0)
+++ trunk/LayoutTests/intersection-observer/intersection-clipped-to-target.html	2019-09-13 18:46:56 UTC (rev 249845)
@@ -0,0 +1,31 @@
+
+
+#container {
+width: 100%;
+transform: translateZ(0);
+overflow: hidden;
+}
+
+#target {
+margin-top: 0.66px;
+height: 40px;
+background-color: green;
+}
+
+
+
+
+
+ +