Title: [207208] branches/safari-602-branch

Diff

Modified: branches/safari-602-branch/LayoutTests/ChangeLog (207207 => 207208)


--- branches/safari-602-branch/LayoutTests/ChangeLog	2016-10-12 08:41:40 UTC (rev 207207)
+++ branches/safari-602-branch/LayoutTests/ChangeLog	2016-10-12 08:41:44 UTC (rev 207208)
@@ -1,5 +1,20 @@
 2016-10-12  Matthew Hanson  <matthew_han...@apple.com>
 
+        Merge r205861. rdar://problem/28409523
+
+    2016-09-12  Zalan Bujtas  <za...@apple.com>
+
+            Input type object and the associated render can go out of sync.
+            https://bugs.webkit.org/show_bug.cgi?id=161871
+            <rdar://problem/28178094>
+
+            Reviewed by Antti Koivisto.
+
+            * fast/forms/assert-on-input-type-change-expected.txt: Added.
+            * fast/forms/assert-on-input-type-change.html: Added.
+
+2016-10-12  Matthew Hanson  <matthew_han...@apple.com>
+
         Merge r205786. rdar://problem/28476956
 
     2016-09-10  Chris Dumez  <cdu...@apple.com>

Added: branches/safari-602-branch/LayoutTests/fast/forms/assert-on-input-type-change-expected.txt (0 => 207208)


--- branches/safari-602-branch/LayoutTests/fast/forms/assert-on-input-type-change-expected.txt	                        (rev 0)
+++ branches/safari-602-branch/LayoutTests/fast/forms/assert-on-input-type-change-expected.txt	2016-10-12 08:41:44 UTC (rev 207208)
@@ -0,0 +1 @@
+PASS if no assert in debug. 

Added: branches/safari-602-branch/LayoutTests/fast/forms/assert-on-input-type-change.html (0 => 207208)


--- branches/safari-602-branch/LayoutTests/fast/forms/assert-on-input-type-change.html	                        (rev 0)
+++ branches/safari-602-branch/LayoutTests/fast/forms/assert-on-input-type-change.html	2016-10-12 08:41:44 UTC (rev 207208)
@@ -0,0 +1,19 @@
+<!DOCTYPE html>
+<html>
+<head>
+<title>This tests that we manage input type change properly.</title>
+<script>
+if (window.testRunner)
+    testRunner.dumpAsText();
+
+function runTest() {
+    var item = document.getElementById("foobar");
+    item.type = 'image';
+    item.alt="foobar";
+}
+</script>
+<body _onload_="runTest();">
+PASS if no assert in debug.
+<input id=foobar type="text">
+</body>
+</html>

Modified: branches/safari-602-branch/Source/WebCore/ChangeLog (207207 => 207208)


--- branches/safari-602-branch/Source/WebCore/ChangeLog	2016-10-12 08:41:40 UTC (rev 207207)
+++ branches/safari-602-branch/Source/WebCore/ChangeLog	2016-10-12 08:41:44 UTC (rev 207208)
@@ -1,5 +1,24 @@
 2016-10-12  Matthew Hanson  <matthew_han...@apple.com>
 
+        Merge r205861. rdar://problem/28409523
+
+    2016-09-12  Zalan Bujtas  <za...@apple.com>
+
+            Input type object and the associated render can go out of sync.
+            https://bugs.webkit.org/show_bug.cgi?id=161871
+            <rdar://problem/28178094>
+
+            Reviewed by Antti Koivisto.
+
+            Bail out when we've got a mismatched renderer.
+
+            Test: fast/forms/assert-on-input-type-change.html
+
+            * html/ImageInputType.cpp:
+            (WebCore::ImageInputType::altAttributeChanged):
+
+2016-10-12  Matthew Hanson  <matthew_han...@apple.com>
+
         Merge r205786. rdar://problem/28476956
 
     2016-09-10  Chris Dumez  <cdu...@apple.com>

Modified: branches/safari-602-branch/Source/WebCore/html/ImageInputType.cpp (207207 => 207208)


--- branches/safari-602-branch/Source/WebCore/html/ImageInputType.cpp	2016-10-12 08:41:40 UTC (rev 207207)
+++ branches/safari-602-branch/Source/WebCore/html/ImageInputType.cpp	2016-10-12 08:41:44 UTC (rev 207208)
@@ -109,6 +109,9 @@
 
 void ImageInputType::altAttributeChanged()
 {
+    if (!is<RenderImage>(element().renderer()))
+        return;
+
     auto* renderer = downcast<RenderImage>(element().renderer());
     if (!renderer)
         return;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to