[webkit-changes] [295127] trunk/metadata/contributors.json

2022-06-02 Thread fred . wang
Title: [295127] trunk/metadata/contributors.json








Revision 295127
Author fred.w...@free.fr
Date 2022-06-02 07:23:48 -0700 (Thu, 02 Jun 2022)


Log Message
Add fred-wang github account to contributors.json
https://bugs.webkit.org/show_bug.cgi?id=241219

Reviewed by Tim Nguyen.

* metadata/contributors.json: Add my github account.

Canonical link: https://commits.webkit.org/251218@main

Modified Paths

trunk/metadata/contributors.json




Diff

Modified: trunk/metadata/contributors.json (295126 => 295127)

--- trunk/metadata/contributors.json	2022-06-02 13:56:32 UTC (rev 295126)
+++ trunk/metadata/contributors.json	2022-06-02 14:23:48 UTC (rev 295127)
@@ -2546,6 +2546,7 @@
  "fred.w...@free.fr",
  "fw...@igalia.com"
   ],
+  "github" : "fred-wang",
   "name" : "Fr\u00e9d\u00e9ric Wang",
   "nicks" : [
  "fredw"






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


[webkit-changes] [227191] trunk/LayoutTests

2018-01-18 Thread fred . wang
Title: [227191] trunk/LayoutTests








Revision 227191
Author fred.w...@free.fr
Date 2018-01-18 23:03:50 -0800 (Thu, 18 Jan 2018)


Log Message
Move helper files for iOS touch gestures into LayoutTests/resources
https://bugs.webkit.org/show_bug.cgi?id=181798

Patch by Frederic Wang  on 2018-01-18
Reviewed by Wenson Hsieh.

* fast/events/touch/ios/drag-to-autoscroll-in-single-line-editable.html: Change URL of
basic-gestures.js ; remove gesture-helpers.js it seems unused and has the wrong URL anyway.
* fast/events/touch/ios/long-press-then-drag-down-to-change-selected-text.html: Change URL
of basic-gestures.js.
* fast/events/touch/ios/long-press-then-drag-left-to-change-selected-text.html: Ditto.
* fast/events/touch/ios/long-press-then-drag-right-to-change-selected-text.html: Ditto.
* fast/events/touch/ios/long-press-then-drag-to-select-text.html: Ditto.
* fast/events/touch/ios/long-press-then-drag-up-to-change-selected-text.html: Ditto.
* fast/events/touch/ios/long-press-to-select-and-tap-to-clear.html: Ditto.
* fast/events/touch/ios/long-press-to-select-text.html: Ditto.
* resources/basic-gestures.js: Renamed from LayoutTests/fast/events/touch/ios/resources/basic-gestures.js.
* resources/ui-debugging.js: Renamed from LayoutTests/fast/events/touch/ios/resources/ui-debugging.js.
Note that this file was introduced in r222517 but seems unused for now.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/LayoutTests/fast/events/touch/ios/drag-to-autoscroll-in-single-line-editable.html
trunk/LayoutTests/fast/events/touch/ios/long-press-then-drag-down-to-change-selected-text.html
trunk/LayoutTests/fast/events/touch/ios/long-press-then-drag-left-to-change-selected-text.html
trunk/LayoutTests/fast/events/touch/ios/long-press-then-drag-right-to-change-selected-text.html
trunk/LayoutTests/fast/events/touch/ios/long-press-then-drag-to-select-text.html
trunk/LayoutTests/fast/events/touch/ios/long-press-then-drag-up-to-change-selected-text.html
trunk/LayoutTests/fast/events/touch/ios/long-press-to-select-and-tap-to-clear.html
trunk/LayoutTests/fast/events/touch/ios/long-press-to-select-text.html


Added Paths

trunk/LayoutTests/resources/basic-gestures.js
trunk/LayoutTests/resources/ui-debugging.js


Removed Paths

trunk/LayoutTests/fast/events/touch/ios/resources/




Diff

Modified: trunk/LayoutTests/ChangeLog (227190 => 227191)

--- trunk/LayoutTests/ChangeLog	2018-01-19 06:33:11 UTC (rev 227190)
+++ trunk/LayoutTests/ChangeLog	2018-01-19 07:03:50 UTC (rev 227191)
@@ -1,3 +1,24 @@
+2018-01-18  Frederic Wang  
+
+Move helper files for iOS touch gestures into LayoutTests/resources
+https://bugs.webkit.org/show_bug.cgi?id=181798
+
+Reviewed by Wenson Hsieh.
+
+* fast/events/touch/ios/drag-to-autoscroll-in-single-line-editable.html: Change URL of
+basic-gestures.js ; remove gesture-helpers.js it seems unused and has the wrong URL anyway.
+* fast/events/touch/ios/long-press-then-drag-down-to-change-selected-text.html: Change URL
+of basic-gestures.js.
+* fast/events/touch/ios/long-press-then-drag-left-to-change-selected-text.html: Ditto.
+* fast/events/touch/ios/long-press-then-drag-right-to-change-selected-text.html: Ditto.
+* fast/events/touch/ios/long-press-then-drag-to-select-text.html: Ditto.
+* fast/events/touch/ios/long-press-then-drag-up-to-change-selected-text.html: Ditto.
+* fast/events/touch/ios/long-press-to-select-and-tap-to-clear.html: Ditto.
+* fast/events/touch/ios/long-press-to-select-text.html: Ditto.
+* resources/basic-gestures.js: Renamed from LayoutTests/fast/events/touch/ios/resources/basic-gestures.js.
+* resources/ui-debugging.js: Renamed from LayoutTests/fast/events/touch/ios/resources/ui-debugging.js.
+Note that this file was introduced in r222517 but seems unused for now.
+
 2018-01-18  Ryan Haddad  
 
 Mark platform/mac/webrtc/captureCanvas-webrtc-software-encoder.html as flaky.


Modified: trunk/LayoutTests/fast/events/touch/ios/drag-to-autoscroll-in-single-line-editable.html (227190 => 227191)

--- trunk/LayoutTests/fast/events/touch/ios/drag-to-autoscroll-in-single-line-editable.html	2018-01-19 06:33:11 UTC (rev 227190)
+++ trunk/LayoutTests/fast/events/touch/ios/drag-to-autoscroll-in-single-line-editable.html	2018-01-19 07:03:50 UTC (rev 227191)
@@ -2,8 +2,7 @@
 
 
 
-

[webkit-changes] [226618] trunk/Tools

2018-01-09 Thread fred . wang
Title: [226618] trunk/Tools








Revision 226618
Author fred.w...@free.fr
Date 2018-01-09 01:05:34 -0800 (Tue, 09 Jan 2018)


Log Message
check-webkit-style: Verify syntax for WK_API_AVAILABLE
https://bugs.webkit.org/show_bug.cgi?id=181394

Patch by Frederic Wang  on 2018-01-09
Reviewed by Darin Adler.

A common syntax error for WK_API_AVAILABLE is to write ios(WK_MAC_TBA)
as the second parameter instead of ios(WK_IOS_TBA). This generally
builds for iOS on EWS but not when using the public SDK. See r224057,
r223207 and r226211 for example. This patch adds a basic style check
for that macro to prevent this kind of mistake.

* Scripts/webkitpy/style/checkers/cpp.py:
(check_min_versions_of_wk_api_available): New function to verify the parameters of WX_API_AVAILABLE.
(check_style): Run new style check.
(CppChecker): Add build type for the new style check.
* Scripts/webkitpy/style/checkers/cpp_unittest.py:
(WebKitStyleTest.test_min_versions_of_wk_api_available): Add tests for the new style check.

Modified Paths

trunk/Tools/ChangeLog
trunk/Tools/Scripts/webkitpy/style/checkers/cpp.py
trunk/Tools/Scripts/webkitpy/style/checkers/cpp_unittest.py




Diff

Modified: trunk/Tools/ChangeLog (226617 => 226618)

--- trunk/Tools/ChangeLog	2018-01-09 08:34:34 UTC (rev 226617)
+++ trunk/Tools/ChangeLog	2018-01-09 09:05:34 UTC (rev 226618)
@@ -1,3 +1,23 @@
+2018-01-09  Frederic Wang  
+
+check-webkit-style: Verify syntax for WK_API_AVAILABLE
+https://bugs.webkit.org/show_bug.cgi?id=181394
+
+Reviewed by Darin Adler.
+
+A common syntax error for WK_API_AVAILABLE is to write ios(WK_MAC_TBA)
+as the second parameter instead of ios(WK_IOS_TBA). This generally
+builds for iOS on EWS but not when using the public SDK. See r224057,
+r223207 and r226211 for example. This patch adds a basic style check
+for that macro to prevent this kind of mistake.
+
+* Scripts/webkitpy/style/checkers/cpp.py:
+(check_min_versions_of_wk_api_available): New function to verify the parameters of WX_API_AVAILABLE.
+(check_style): Run new style check.
+(CppChecker): Add build type for the new style check.
+* Scripts/webkitpy/style/checkers/cpp_unittest.py:
+(WebKitStyleTest.test_min_versions_of_wk_api_available): Add tests for the new style check.
+
 2018-01-08  Wenson Hsieh  
 
 [Attachment Support] Expose HTMLAttachmentElement.uniqueIdentifier to bindings


Modified: trunk/Tools/Scripts/webkitpy/style/checkers/cpp.py (226617 => 226618)

--- trunk/Tools/Scripts/webkitpy/style/checkers/cpp.py	2018-01-09 08:34:34 UTC (rev 226617)
+++ trunk/Tools/Scripts/webkitpy/style/checkers/cpp.py	2018-01-09 09:05:34 UTC (rev 226618)
@@ -2767,6 +2767,27 @@
 return len(line)
 
 
+def check_min_versions_of_wk_api_available(clean_lines, line_number, error):
+"""Checks the min version numbers of WK_API_AVAILABLE
+
+Args:
+  clean_lines: A CleansedLines instance containing the file.
+  line_number: The number of the line to check.
+  error: The function to call with any errors found.
+"""
+
+line = clean_lines.elided[line_number]  # Get rid of comments and strings.
+
+wk_api_available = search(r'WK_API_AVAILABLE\(macosx\(([^\)]+)\), ios\(([^\)]+)\)\)', line)
+if wk_api_available:
+macosxMinVersion = wk_api_available.group(1)
+if not match(r'^([\d\.]+|WK_MAC_TBA)$', macosxMinVersion):
+error(line_number, 'build/wk_api_available', 5, '%s is neither a version number nor WK_MAC_TBA' % macosxMinVersion)
+
+iosMinVersion = wk_api_available.group(2)
+if not match(r'^([\d\.]+|WK_IOS_TBA)$', iosMinVersion):
+error(line_number, 'build/wk_api_available', 5, '%s is neither a version number nor WK_IOS_TBA' % iosMinVersion)
+
 def check_style(clean_lines, line_number, file_extension, class_state, file_state, enum_state, error):
 """Checks rules from the 'C++ style rules' section of cppguide.html.
 
@@ -2842,6 +2863,7 @@
 check_soft_link_class_alloc(clean_lines, line_number, error)
 check_indentation_amount(clean_lines, line_number, error)
 check_enum_casing(clean_lines, line_number, enum_state, error)
+check_min_versions_of_wk_api_available(clean_lines, line_number, error)
 
 
 _RE_PATTERN_INCLUDE_NEW_STYLE = re.compile(r'#(?:include|import) +"[^/]+\.h"')
@@ -3892,6 +3914,7 @@
 'build/using_std',
 'build/using_namespace',
 'build/cpp_comment',
+'build/wk_api_available',
 'legal/copyright',
 'readability/braces',
 'readability/casting',


Modified: trunk/Tools/Scripts/webkitpy/style/checkers/cpp_unittest.py (226617 => 226618)

--- trunk/Tools/Scripts/webkitpy/style/checkers/cpp_unittest.py	2018-01-09 08:34:34 UTC (rev 226617)
+++ trunk/Tools/Scripts/webkitpy/style/checkers/cpp_unittest.py	2018-01-09 09:05:34 UTC (rev 226618)
@@ 

[webkit-changes] [226513] trunk/Source/WebKit

2018-01-08 Thread fred . wang
Title: [226513] trunk/Source/WebKit








Revision 226513
Author fred.w...@free.fr
Date 2018-01-08 08:14:02 -0800 (Mon, 08 Jan 2018)


Log Message
Unreviewed build fix after r226211.

Patch by Frederic Wang  on 2018-01-08

* UIProcess/API/Cocoa/WKPreferencesPrivate.h: Use WK_IOS_TBA for iOS.

Modified Paths

trunk/Source/WebKit/ChangeLog
trunk/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h




Diff

Modified: trunk/Source/WebKit/ChangeLog (226512 => 226513)

--- trunk/Source/WebKit/ChangeLog	2018-01-08 15:55:14 UTC (rev 226512)
+++ trunk/Source/WebKit/ChangeLog	2018-01-08 16:14:02 UTC (rev 226513)
@@ -1,3 +1,9 @@
+2018-01-08  Frederic Wang  
+
+Unreviewed build fix after r226211.
+
+* UIProcess/API/Cocoa/WKPreferencesPrivate.h: Use WK_IOS_TBA for iOS.
+
 2018-01-08  Youenn Fablet  
 
 navigator.onLine does not work inside service workers


Modified: trunk/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h (226512 => 226513)

--- trunk/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h	2018-01-08 15:55:14 UTC (rev 226512)
+++ trunk/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h	2018-01-08 16:14:02 UTC (rev 226513)
@@ -112,7 +112,7 @@
 
 @property (nonatomic, setter=_setPeerConnectionEnabled:) BOOL _peerConnectionEnabled WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));
 @property (nonatomic, setter=_setMediaDevicesEnabled:) BOOL _mediaDevicesEnabled WK_API_AVAILABLE(macosx(10.13), ios(11.0));
-@property (nonatomic, setter=_setScreenCaptureEnabled:) BOOL _screenCaptureEnabled WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_MAC_TBA));
+@property (nonatomic, setter=_setScreenCaptureEnabled:) BOOL _screenCaptureEnabled WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));
 @property (nonatomic, setter=_setMockCaptureDevicesEnabled:) BOOL _mockCaptureDevicesEnabled WK_API_AVAILABLE(macosx(10.13), ios(11.0));
 @property (nonatomic, setter=_setMockCaptureDevicesPromptEnabled:) BOOL _mockCaptureDevicesPromptEnabled WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));
 @property (nonatomic, setter=_setMediaCaptureRequiresSecureConnection:) BOOL _mediaCaptureRequiresSecureConnection WK_API_AVAILABLE(macosx(10.13), ios(11.0));






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


[webkit-changes] [226119] trunk/LayoutTests

2017-12-19 Thread fred . wang
Title: [226119] trunk/LayoutTests








Revision 226119
Author fred.w...@free.fr
Date 2017-12-19 03:50:39 -0800 (Tue, 19 Dec 2017)


Log Message
Unreviewed test gardening.

Patch by Frederic Wang  on 2017-12-19

* platform/gtk/mathml/opentype/opentype-stretchy-horizontal-expected.png:
* platform/gtk/mathml/opentype/opentype-stretchy-horizontal-expected.txt: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/LayoutTests/platform/gtk/mathml/opentype/opentype-stretchy-horizontal-expected.png


Added Paths

trunk/LayoutTests/platform/gtk/mathml/opentype/opentype-stretchy-horizontal-expected.txt




Diff

Modified: trunk/LayoutTests/ChangeLog (226118 => 226119)

--- trunk/LayoutTests/ChangeLog	2017-12-19 09:24:48 UTC (rev 226118)
+++ trunk/LayoutTests/ChangeLog	2017-12-19 11:50:39 UTC (rev 226119)
@@ -1,3 +1,10 @@
+2017-12-19  Frederic Wang  
+
+Unreviewed test gardening.
+
+* platform/gtk/mathml/opentype/opentype-stretchy-horizontal-expected.png:
+* platform/gtk/mathml/opentype/opentype-stretchy-horizontal-expected.txt: Added.
+
 2017-12-18  Chris Dumez  
 
 Default scope used when registering a service worker is wrong


Modified: trunk/LayoutTests/platform/gtk/mathml/opentype/opentype-stretchy-horizontal-expected.png

(Binary files differ)


Added: trunk/LayoutTests/platform/gtk/mathml/opentype/opentype-stretchy-horizontal-expected.txt (0 => 226119)

--- trunk/LayoutTests/platform/gtk/mathml/opentype/opentype-stretchy-horizontal-expected.txt	(rev 0)
+++ trunk/LayoutTests/platform/gtk/mathml/opentype/opentype-stretchy-horizontal-expected.txt	2017-12-19 11:50:39 UTC (rev 226119)
@@ -0,0 +1,35 @@
+layer at (0,0) size 800x600
+  RenderView at (0,0) size 800x600
+layer at (0,0) size 800x157
+  RenderBlock {HTML} at (0,0) size 800x157
+RenderBody {BODY} at (8,16) size 784x125
+  RenderBlock {P} at (0,0) size 784x25
+RenderMathMLMath {math} at (0,2) size 10x23
+  RenderMathMLRow {mstyle} at (0,0) size 10x23
+RenderMathMLUnderOver {mover} at (0,0) size 10x23
+  RenderMathMLOperator {mo} at (0,1) size 10x22
+RenderBlock (anonymous) at (0,0) size 1x4
+  RenderText {#text} at (0,-3) size 1x0
+text run at (0,-3) width 1: "\x{219C}"
+  RenderMathMLSpace {mspace} at (1,0) size 8x1
+RenderText {#text} at (0,0) size 0x0
+  RenderBlock {P} at (0,41) size 784x25
+RenderMathMLMath {math} at (0,2) size 20x23
+  RenderMathMLRow {mstyle} at (0,0) size 20x23
+RenderMathMLUnderOver {mover} at (0,0) size 20x23
+  RenderMathMLOperator {mo} at (0,1) size 20x22
+RenderBlock (anonymous) at (0,0) size 1x4
+  RenderText {#text} at (0,-3) size 1x0
+text run at (0,-3) width 1: "\x{219C}"
+  RenderMathMLSpace {mspace} at (2,0) size 16x1
+RenderText {#text} at (0,0) size 0x0
+  RenderBlock {P} at (0,82) size 784x43
+RenderMathMLMath {math} at (0,0) size 150x43
+  RenderMathMLRow {mstyle} at (0,0) size 150x43
+RenderMathMLUnderOver {mover} at (0,0) size 150x43
+  RenderMathMLOperator {mo} at (0,1) size 150x42
+RenderBlock (anonymous) at (0,0) size 1x4
+  RenderText {#text} at (0,-3) size 1x0
+text run at (0,-3) width 1: "\x{219C}"
+  RenderMathMLSpace {mspace} at (0,0) size 150x1
+RenderText {#text} at (0,0) size 0x0
Property changes on: trunk/LayoutTests/platform/gtk/mathml/opentype/opentype-stretchy-horizontal-expected.txt
___


Added: svn:eol-style
+LF
\ No newline at end of property




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


[webkit-changes] [225480] trunk/Source

2017-12-04 Thread fred . wang
Title: [225480] trunk/Source








Revision 225480
Author fred.w...@free.fr
Date 2017-12-04 08:45:51 -0800 (Mon, 04 Dec 2017)


Log Message
Make ScrollingTreeNode::enclosingFrameNode return the node itself for frame nodes
https://bugs.webkit.org/show_bug.cgi?id=180353

Patch by Frederic Wang  on 2017-12-04
Reviewed by Antonio Gomes.

This function was introduced in bug 175135 to solve a rendering bug with fixed positioned
nodes in overflow nodes. For a frame node, the reference frame to use for fixed nodes is
actually the frame node itself or otherwise we will get the same rendering bug. This patch
makes enclosingFrameNode return the node itself when it is a frame node and renames it to
clarify this behavior. Currently, enclosingFrameNode is not used for frame nodes so the
behavior is unchanged.

Source/WebCore:

No new tests, behavior is unchanged.

* page/scrolling/ScrollingTreeNode.cpp:
(WebCore::ScrollingTreeNode::enclosingFrameNodeIncludingSelf): Start the search from a frame
scrolling node from the node itself. Renamed to make explicit that this function may include
the node itself.
* page/scrolling/ScrollingTreeNode.h: Renamed.

Source/WebKit:

* UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.mm:
(WebKit::ScrollingTreeScrollingNodeDelegateIOS::updateChildNodesAfterScroll): Use auto* and
the new function name.

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.cpp
trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.h
trunk/Source/WebKit/ChangeLog
trunk/Source/WebKit/UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.mm




Diff

Modified: trunk/Source/WebCore/ChangeLog (225479 => 225480)

--- trunk/Source/WebCore/ChangeLog	2017-12-04 16:41:49 UTC (rev 225479)
+++ trunk/Source/WebCore/ChangeLog	2017-12-04 16:45:51 UTC (rev 225480)
@@ -1,3 +1,25 @@
+2017-12-04  Frederic Wang  
+
+Make ScrollingTreeNode::enclosingFrameNode return the node itself for frame nodes
+https://bugs.webkit.org/show_bug.cgi?id=180353
+
+Reviewed by Antonio Gomes.
+
+This function was introduced in bug 175135 to solve a rendering bug with fixed positioned
+nodes in overflow nodes. For a frame node, the reference frame to use for fixed nodes is
+actually the frame node itself or otherwise we will get the same rendering bug. This patch
+makes enclosingFrameNode return the node itself when it is a frame node and renames it to
+clarify this behavior. Currently, enclosingFrameNode is not used for frame nodes so the
+behavior is unchanged.
+
+No new tests, behavior is unchanged.
+
+* page/scrolling/ScrollingTreeNode.cpp:
+(WebCore::ScrollingTreeNode::enclosingFrameNodeIncludingSelf): Start the search from a frame
+scrolling node from the node itself. Renamed to make explicit that this function may include
+the node itself.
+* page/scrolling/ScrollingTreeNode.h: Renamed.
+
 2017-12-04  Michael Catanzaro  
 
 [WPE][GTK] Implement PAL::SleepDisabler


Modified: trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.cpp (225479 => 225480)

--- trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.cpp	2017-12-04 16:41:49 UTC (rev 225479)
+++ trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.cpp	2017-12-04 16:45:51 UTC (rev 225480)
@@ -77,9 +77,9 @@
 ts.dumpProperty("nodeID", scrollingNodeID());
 }
 
-ScrollingTreeFrameScrollingNode* ScrollingTreeNode::enclosingFrameNode() const
+ScrollingTreeFrameScrollingNode* ScrollingTreeNode::enclosingFrameNodeIncludingSelf()
 {
-auto* node = parent();
+auto* node = this;
 while (node && !node->isFrameScrollingNode())
 node = node->parent();
 


Modified: trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.h (225479 => 225480)

--- trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.h	2017-12-04 16:41:49 UTC (rev 225479)
+++ trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.h	2017-12-04 16:45:51 UTC (rev 225480)
@@ -66,7 +66,7 @@
 void appendChild(Ref&&);
 void removeChild(ScrollingTreeNode&);
 
-WEBCORE_EXPORT ScrollingTreeFrameScrollingNode* enclosingFrameNode() const;
+WEBCORE_EXPORT ScrollingTreeFrameScrollingNode* enclosingFrameNodeIncludingSelf();
 
 WEBCORE_EXPORT void dump(WTF::TextStream&, ScrollingStateTreeAsTextBehavior) const;
 


Modified: trunk/Source/WebKit/ChangeLog (225479 => 225480)

--- trunk/Source/WebKit/ChangeLog	2017-12-04 16:41:49 UTC (rev 225479)
+++ trunk/Source/WebKit/ChangeLog	2017-12-04 16:45:51 UTC (rev 225480)
@@ -1,3 +1,21 @@
+2017-12-04  Frederic Wang  
+
+Make ScrollingTreeNode::enclosingFrameNode return the node itself for frame nodes
+https://bugs.webkit.org/show_bug.cgi?id=180353
+
+Reviewed by Antonio Gomes.
+
+This function was introduced in bug 175135 to solve a rendering bug with 

[webkit-changes] [225475] trunk/Source/WebCore

2017-12-04 Thread fred . wang
Title: [225475] trunk/Source/WebCore








Revision 225475
Author fred.w...@free.fr
Date 2017-12-04 03:30:10 -0800 (Mon, 04 Dec 2017)


Log Message
Bug 161300 - Move RenderMathMLRoot:RootType and RenderMathMLScripts:ScriptsType to element classes
https://bugs.webkit.org/show_bug.cgi?id=161300

Patch by Frederic Wang  on 2017-12-04
Reviewed by Darin Adler.

RenderMathMLRoot::m_kind and RenderMathMLScripts::m_scriptType are initialized in the
constructors of the renderer classes from the tag name of the corresponding elements.
This patch moves them into the corresponding element classes and makes them const members
parsed in the constructors. It also introduces a MathMLRootElement class deriving from
MathMLRowElement to store the new member. Finally, the types are redefined as enum classes.

No new tests, behavior unchanged and already covered by existing tests.

* Sources.txt: Add MathMLRootElement files.
* WebCore.xcodeproj/project.pbxproj: Ditto.
* mathml/MathMLAllInOne.cpp: Ditto.
* mathml/MathMLRootElement.cpp:
(WebCore::element): Override this function to downcast to MathMLRootElement.
(WebCore::rootTypeOf): Helper function to parse the root type, moved from RenderMathMLRoot.
(WebCore::MathMLRootElement::MathMLRootElement): Initialize the root type.
(WebCore::MathMLRootElement::create):
(WebCore::MathMLRootElement::createElementRenderer): Moved from MathMLRowElement.
* mathml/MathMLRootElement.h: New class deriving from MathMLRowElement, with a RootType
member exposed to the renderer class.
* mathml/MathMLRowElement.cpp: Remove header for RenderMathMLRoot.h.
(WebCore::MathMLRowElement::createElementRenderer): Moved to MathMLRootElement.
* mathml/MathMLScriptsElement.cpp: Introduce a script type.
(WebCore::scriptTypeOf): Helper function to parse the script type, moved from
RenerMathMLScripts.
(WebCore::MathMLScriptsElement::MathMLScriptsElement): Initialize the script type.
* mathml/MathMLScriptsElement.h: Add new script type member.
(WebCore::MathMLScriptsElement::scriptType const): Expose the script type to the renderer
class.
* mathml/mathtags.in: Map  and  to MathMLRootElement.
* rendering/mathml/RenderMathMLRoot.cpp:
(WebCore::RenderMathMLRoot::RenderMathMLRoot): Use MathMLRootElement and remove parsing of
the root type.
(WebCore::RenderMathMLRoot::rootType const): Helper function to access the root type from
the element class.
(WebCore::RenderMathMLRoot::isValid const): Use rootType() and add prefix for enum class
values.
(WebCore::RenderMathMLRoot::getBase const): Ditto.
(WebCore::RenderMathMLRoot::getIndex const): Ditto.
(WebCore::RenderMathMLRoot::horizontalParameters): Ditto.
(WebCore::RenderMathMLRoot::verticalParameters): Ditto.
(WebCore::RenderMathMLRoot::computePreferredLogicalWidths): Ditto.
(WebCore::RenderMathMLRoot::layoutBlock): Ditto.
(WebCore::RenderMathMLRoot::paint): Ditto.
* rendering/mathml/RenderMathMLRoot.h: Define root type as an enum class, replace
MathMLRowElement with MathMLRootElement, declare and use new rootType() function and remove
the m_kind member.
* rendering/mathml/RenderMathMLScripts.cpp:
(WebCore::RenderMathMLScripts::RenderMathMLScripts): Remove parsing of script type.
(WebCore::RenderMathMLScripts::scriptType const): Helper function to access the script type
from the element class.
(WebCore::RenderMathMLScripts::validateAndGetReferenceChildren): Use scriptType() and add
prefix for enum class values.
(WebCore::RenderMathMLScripts::computePreferredLogicalWidths): Ditto.
(WebCore::RenderMathMLScripts::verticalMetrics): Ditto.
(WebCore::RenderMathMLScripts::layoutBlock): Ditto.
* rendering/mathml/RenderMathMLScripts.h: Define root type as an enum class, declare the
scriptType() function and remove the m_scriptType member.
* rendering/mathml/RenderMathMLUnderOver.cpp:
(WebCore::RenderMathMLUnderOver::isValid const): Use scriptType() and add prefix for enum
class values.
(WebCore::RenderMathMLUnderOver::under const): Ditto.
(WebCore::RenderMathMLUnderOver::over const): Ditto.
(WebCore::RenderMathMLUnderOver::computePreferredLogicalWidths): Ditto.
(WebCore::RenderMathMLUnderOver::hasAccent const): Ditto.
(WebCore::RenderMathMLUnderOver::layoutBlock): Ditto.

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/Sources.txt
trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj
trunk/Source/WebCore/mathml/MathMLAllInOne.cpp
trunk/Source/WebCore/mathml/MathMLRowElement.cpp
trunk/Source/WebCore/mathml/MathMLScriptsElement.cpp
trunk/Source/WebCore/mathml/MathMLScriptsElement.h
trunk/Source/WebCore/mathml/mathtags.in
trunk/Source/WebCore/rendering/mathml/RenderMathMLRoot.cpp
trunk/Source/WebCore/rendering/mathml/RenderMathMLRoot.h
trunk/Source/WebCore/rendering/mathml/RenderMathMLScripts.cpp
trunk/Source/WebCore/rendering/mathml/RenderMathMLScripts.h
trunk/Source/WebCore/rendering/mathml/RenderMathMLUnderOver.cpp


Added Paths

trunk/Source/WebCore/mathml/MathMLRootElement.cpp
trunk/Source/WebCore/mathml/MathMLRootElement.h




Diff


[webkit-changes] [225094] trunk

2017-11-22 Thread fred . wang
Title: [225094] trunk








Revision 225094
Author fred.w...@free.fr
Date 2017-11-22 00:14:53 -0800 (Wed, 22 Nov 2017)


Log Message
Unreviewed, rolling out r225093.
https://bugs.webkit.org/show_bug.cgi?id=179938

Compilation failed on WinCairo 64-bit Release (Requested by
fredw on #webkit).

Reverted changeset:

"Implement VisualViewport API attributes"
https://bugs.webkit.org/show_bug.cgi?id=179385
https://trac.webkit.org/changeset/225093

Patch by Commit Queue  on 2017-11-22

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/LayoutTests/imported/w3c/ChangeLog
trunk/LayoutTests/imported/w3c/web-platform-tests/viewport/viewport-no-resize-event-on-overflow-recalc-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/viewport/viewport-read-size-causes-layout-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/viewport/viewport-read-size-in-iframe-causes-layout-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/viewport/viewport-resize-event-on-load-overflowing-page-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/viewport/viewport-scrollbars-cause-resize-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/viewport/viewport-type-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/viewport/viewport-unscaled-scale-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/viewport/viewport-unscaled-scale-iframe-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/viewport/viewport-unscaled-scroll-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/viewport/viewport-unscaled-scroll-iframe-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/viewport/viewport-unscaled-size-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/viewport/viewport-unscaled-size-iframe-expected.txt
trunk/LayoutTests/platform/gtk/TestExpectations
trunk/LayoutTests/platform/mac-wk1/TestExpectations
trunk/Source/WebCore/CMakeLists.txt
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/DerivedSources.cpp
trunk/Source/WebCore/DerivedSources.make
trunk/Source/WebCore/Sources.txt
trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj
trunk/Source/WebCore/bindings/js/WebCoreBuiltinNames.h
trunk/Source/WebCore/dom/EventTargetFactory.in
trunk/Source/WebCore/page/DOMWindow.cpp
trunk/Source/WebCore/page/DOMWindow.h
trunk/Source/WebCore/page/DOMWindow.idl
trunk/Source/WebCore/page/Settings.yaml
trunk/Source/WebKit/ChangeLog
trunk/Source/WebKit/Shared/WebPreferences.yaml
trunk/Source/WebKitLegacy/mac/ChangeLog
trunk/Source/WebKitLegacy/mac/WebView/WebPreferenceKeysPrivate.h
trunk/Source/WebKitLegacy/mac/WebView/WebPreferences.mm
trunk/Source/WebKitLegacy/mac/WebView/WebPreferencesPrivate.h
trunk/Source/WebKitLegacy/mac/WebView/WebView.mm
trunk/Source/WebKitLegacy/win/ChangeLog
trunk/Source/WebKitLegacy/win/Interfaces/IWebPreferencesPrivate.idl
trunk/Source/WebKitLegacy/win/WebPreferenceKeysPrivate.h
trunk/Source/WebKitLegacy/win/WebPreferences.cpp
trunk/Source/WebKitLegacy/win/WebPreferences.h
trunk/Source/WebKitLegacy/win/WebView.cpp
trunk/Tools/ChangeLog
trunk/Tools/DumpRenderTree/mac/DumpRenderTree.mm
trunk/Tools/DumpRenderTree/win/DumpRenderTree.cpp


Removed Paths

trunk/LayoutTests/fast/visual-viewport/viewport-dimensions-exclude-custom-scrollbars-expected.txt
trunk/LayoutTests/fast/visual-viewport/viewport-dimensions-exclude-custom-scrollbars.html
trunk/LayoutTests/fast/visual-viewport/viewport-dimensions-exclude-scrollbars-expected.txt
trunk/LayoutTests/fast/visual-viewport/viewport-dimensions-exclude-scrollbars.html
trunk/LayoutTests/fast/visual-viewport/viewport-dimensions-expected.txt
trunk/LayoutTests/fast/visual-viewport/viewport-dimensions-iframe-expected.txt
trunk/LayoutTests/fast/visual-viewport/viewport-dimensions-iframe.html
trunk/LayoutTests/fast/visual-viewport/viewport-dimensions-under-page-zoom-expected.txt
trunk/LayoutTests/fast/visual-viewport/viewport-dimensions-under-page-zoom.html
trunk/LayoutTests/fast/visual-viewport/viewport-dimensions.html
trunk/LayoutTests/platform/ios/fast/visual-viewport/viewport-dimensions-iframe-expected.txt
trunk/LayoutTests/platform/ios/imported/w3c/web-platform-tests/viewport/
trunk/Source/WebCore/page/VisualViewport.cpp
trunk/Source/WebCore/page/VisualViewport.h
trunk/Source/WebCore/page/VisualViewport.idl




Diff

Modified: trunk/LayoutTests/ChangeLog (225093 => 225094)

--- trunk/LayoutTests/ChangeLog	2017-11-22 07:26:16 UTC (rev 225093)
+++ trunk/LayoutTests/ChangeLog	2017-11-22 08:14:53 UTC (rev 225094)
@@ -1,3 +1,17 @@
+2017-11-22  Commit Queue  
+
+Unreviewed, rolling out r225093.
+https://bugs.webkit.org/show_bug.cgi?id=179938
+
+Compilation failed on WinCairo 64-bit Release (Requested by
+fredw on #webkit).
+
+Reverted changeset:
+
+"Implement VisualViewport API attributes"
+https://bugs.webkit.org/show_bug.cgi?id=179385
+

[webkit-changes] [225092] trunk

2017-11-21 Thread fred . wang
Title: [225092] trunk








Revision 225092
Author fred.w...@free.fr
Date 2017-11-21 23:17:09 -0800 (Tue, 21 Nov 2017)


Log Message
Async frame scrolling: handle fixed root backgrounds in frames
https://bugs.webkit.org/show_bug.cgi?id=176261

Source/WebCore:

Based on patch by Simon Fraser 
Patch by Frederic Wang  on 2017-11-21
Reviewed by Antonio Gomes.

For frames with tiled backing, we register a slow-repaint object because we hit
RenderElement::styleWillChange() before we've made a backing for the iframe's RenderView so
view().compositor().supportsFixedRootBackgroundCompositing() returns false. This patch
ensures that this object is removed when setBackgroundLayerPaintsFixedRootBackground is
called. It also removes the opaque background of non-main frames with tiled backing.
This fixes a possible hit of ASSERT(!m_backgroundLayer) after r221615.

Test: compositing/tiling/tiled-drawing-async-frame-scrolling.html

* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::updateGeometry): Do not set opaque contents for frames with
tiled backing. We keep !m_isMainFrameRenderViewLayer for backward compatibility with WK1.
(WebCore::RenderLayerBacking::setBackgroundLayerPaintsFixedRootBackground): Add an early
return when m_backgroundLayerPaintsFixedRootBackground is not changed. Remove the slow
repaint object previously registered for this frame. Also add an ASSERT to ensure that a
fixed root background is only set for frames with async scrolling.
(WebCore::RenderLayerBacking::updateRootLayerConfiguration): Restrict some special handling
of background and opaqueness to the main frame.

LayoutTests:

Patch by Frederic Wang  on 2017-11-21
Reviewed by Antonio Gomes.

Extend tiled-drawing-async-frame-scrolling with new test cases and update expectations.

* compositing/tiling/tiled-drawing-async-frame-scrolling.html: Add two test cases with
non-white and fixed gradient background. The latter exhibits a crash fixed by that commit.
* compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt: Adjust expectation due
to spacing changes.
* platform/ios-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt: Ditto.
Update expectation for the first case to remove the white background and add expectations for
the two new cases.
* platform/mac-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt: Ditto.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt
trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling.html
trunk/LayoutTests/platform/ios-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt
trunk/LayoutTests/platform/mac-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/rendering/RenderLayerBacking.cpp




Diff

Modified: trunk/LayoutTests/ChangeLog (225091 => 225092)

--- trunk/LayoutTests/ChangeLog	2017-11-22 06:54:50 UTC (rev 225091)
+++ trunk/LayoutTests/ChangeLog	2017-11-22 07:17:09 UTC (rev 225092)
@@ -1,3 +1,21 @@
+2017-11-21  Frederic Wang  
+
+Async frame scrolling: handle fixed root backgrounds in frames
+https://bugs.webkit.org/show_bug.cgi?id=176261
+
+Reviewed by Antonio Gomes.
+
+Extend tiled-drawing-async-frame-scrolling with new test cases and update expectations.
+
+* compositing/tiling/tiled-drawing-async-frame-scrolling.html: Add two test cases with
+non-white and fixed gradient background. The latter exhibits a crash fixed by that commit.
+* compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt: Adjust expectation due
+to spacing changes.
+* platform/ios-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt: Ditto.
+Update expectation for the first case to remove the white background and add expectations for
+the two new cases.
+* platform/mac-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt: Ditto.
+
 2017-11-21  Commit Queue  
 
 Unreviewed, rolling out r225089.


Modified: trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt (225091 => 225092)

--- trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt	2017-11-22 06:54:50 UTC (rev 225091)
+++ trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt	2017-11-22 07:17:09 UTC (rev 225092)
@@ -1,2 +1,2 @@
+   
 
-


Modified: trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling.html (225091 => 225092)

--- trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling.html	2017-11-22 06:54:50 UTC (rev 225091)
+++ trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling.html	2017-11-22 07:17:09 UTC (rev 225092)
@@ 

[webkit-changes] [225090] trunk

2017-11-21 Thread fred . wang
Title: [225090] trunk








Revision 225090
Author fred.w...@free.fr
Date 2017-11-21 22:40:24 -0800 (Tue, 21 Nov 2017)


Log Message
Unreviewed, rolling out r225089.
https://bugs.webkit.org/show_bug.cgi?id=179937

This patch caused compilation failures (Requested by fredw on
#webkit).

Reverted changeset:

"Async frame scrolling: handle fixed root backgrounds in
frames"
https://bugs.webkit.org/show_bug.cgi?id=176261
https://trac.webkit.org/changeset/225089

Patch by Commit Queue  on 2017-11-21

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt
trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling.html
trunk/LayoutTests/platform/ios-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt
trunk/LayoutTests/platform/mac-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/rendering/RenderLayerBacking.cpp




Diff

Modified: trunk/LayoutTests/ChangeLog (225089 => 225090)

--- trunk/LayoutTests/ChangeLog	2017-11-22 06:30:21 UTC (rev 225089)
+++ trunk/LayoutTests/ChangeLog	2017-11-22 06:40:24 UTC (rev 225090)
@@ -1,3 +1,18 @@
+2017-11-21  Commit Queue  
+
+Unreviewed, rolling out r225089.
+https://bugs.webkit.org/show_bug.cgi?id=179937
+
+This patch caused compilation failures (Requested by fredw on
+#webkit).
+
+Reverted changeset:
+
+"Async frame scrolling: handle fixed root backgrounds in
+frames"
+https://bugs.webkit.org/show_bug.cgi?id=176261
+https://trac.webkit.org/changeset/225089
+
 2017-11-21  Frederic Wang  
 
 Async frame scrolling: handle fixed root backgrounds in frames


Modified: trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt (225089 => 225090)

--- trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt	2017-11-22 06:30:21 UTC (rev 225089)
+++ trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt	2017-11-22 06:40:24 UTC (rev 225090)
@@ -1,2 +1,2 @@
-   
 
+


Modified: trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling.html (225089 => 225090)

--- trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling.html	2017-11-22 06:30:21 UTC (rev 225089)
+++ trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling.html	2017-11-22 06:40:24 UTC (rev 225090)
@@ -18,32 +18,10 @@
 testRunner.notifyDone();
 }
 }
-
-	var frameToLoadCount = 3;
-	function newFrameLoaded() {
-	frameToLoadCount--;
-	if (frameToLoadCount === 0)
-	doTest();
-}
 
-
-frame {
-width: 200px;
-height: 100px;
-}
-
   
   
-
-
-
-Layer tree goes here
+
+Layer tree goes here
   
 


Modified: trunk/LayoutTests/platform/ios-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt (225089 => 225090)

--- trunk/LayoutTests/platform/ios-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt	2017-11-22 06:30:21 UTC (rev 225089)
+++ trunk/LayoutTests/platform/ios-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt	2017-11-22 06:40:24 UTC (rev 225090)
@@ -1,4 +1,4 @@
-   
+
 (GraphicsLayer
   (anchor 0.00 0.00)
   (bounds 800.00 600.00)
@@ -20,13 +20,13 @@
   (tile size 800 x 600)
   (top left tile 0, 0 tiles grid 1 x 1)
   (in window 1)
-  (children 3
+  (children 1
 (GraphicsLayer
   (position 8.00 8.00)
-  (bounds 304.00 154.00)
+  (bounds 204.00 104.00)
   (drawsContent 1)
   (backingStoreAttached 1)
-  (visible rect 0.00, 0.00 304.00 x 154.00)
+  (visible rect 0.00, 0.00 204.00 x 104.00)
   (coverage rect -8.00, -8.00 800.00 x 600.00)
   (intersects coverage rect 1)
   (contentsScale 2.00)
@@ -41,10 +41,10 @@
   (children 1
 (GraphicsLayer
   (anchor 0.00 0.00)
-  (bounds 300.00 150.00)
+  (bounds 200.00 100.00)
   (backingStoreAttached 1)
-  (visible rect 0.00, 0.00 300.00 x 150.00)
-  (coverage rect 0.00, 0.00 300.00 x 150.00)
+  (visible rect 0.00, 0.00 200.00 x 100.00)
+  (coverage rect 0.00, 0.00 200.00 x 100.00)
   (intersects coverage rect 1)
   (contentsScale 2.00)
   (children 1
@@ -51,28 +51,29 @@
 (GraphicsLayer
   (backingStoreAttached 0)
   (visible rect 0.00, 0.00 0.00 x 0.00)
-  (coverage rect 0.00, 0.00 300.00 x 150.00)
+  (coverage rect 0.00, 0.00 200.00 x 

[webkit-changes] [225089] trunk

2017-11-21 Thread fred . wang
Title: [225089] trunk








Revision 225089
Author fred.w...@free.fr
Date 2017-11-21 22:30:21 -0800 (Tue, 21 Nov 2017)


Log Message
Async frame scrolling: handle fixed root backgrounds in frames
https://bugs.webkit.org/show_bug.cgi?id=176261

Source/WebCore:

Based on patch by Simon Fraser 
Patch by Frederic Wang  on 2017-11-21
Reviewed by Antonio Gomes.

For frames with tiled backing, we register a slow-repaint object because we hit
RenderElement::styleWillChange() before we've made a backing for the iframe's RenderView so
view().compositor().supportsFixedRootBackgroundCompositing() returns false. This patch
ensures that this object is removed when setBackgroundLayerPaintsFixedRootBackground is
called. It also removes the opaque background of non-main frames with tiled backing.
This fixes a possible hit of ASSERT(!m_backgroundLayer) after r221615.

Test: compositing/tiling/tiled-drawing-async-frame-scrolling.html

* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::updateGeometry): Do not set opaque contents for frames with
tiled backing. We keep !m_isMainFrameRenderViewLayer for backward compatibility with WK1.
(WebCore::RenderLayerBacking::setBackgroundLayerPaintsFixedRootBackground): Add an early
return when m_backgroundLayerPaintsFixedRootBackground is not changed. Remove the slow
repaint object previously registered for this frame. Also add an ASSERT to ensure that a
fixed root background is only set for frames with async scrolling.
(WebCore::RenderLayerBacking::updateRootLayerConfiguration): Restrict some special handling
of background and opaqueness to the main frame.

LayoutTests:

Patch by Frederic Wang  on 2017-11-21
Reviewed by Antonio Gomes.

Extend tiled-drawing-async-frame-scrolling with new test cases and update expectations.

* compositing/tiling/tiled-drawing-async-frame-scrolling.html: Add two test cases with
non-white and fixed gradient background. The latter exhibits a crash fixed by that commit.
* compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt: Adjust expectation due
to spacing changes.
* platform/ios-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt: Ditto.
Update expectation for the first case to remove the white background and add expectations for
the two new cases.
* platform/mac-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt: Ditto.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt
trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling.html
trunk/LayoutTests/platform/ios-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt
trunk/LayoutTests/platform/mac-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/rendering/RenderLayerBacking.cpp




Diff

Modified: trunk/LayoutTests/ChangeLog (225088 => 225089)

--- trunk/LayoutTests/ChangeLog	2017-11-22 01:02:24 UTC (rev 225088)
+++ trunk/LayoutTests/ChangeLog	2017-11-22 06:30:21 UTC (rev 225089)
@@ -1,3 +1,21 @@
+2017-11-21  Frederic Wang  
+
+Async frame scrolling: handle fixed root backgrounds in frames
+https://bugs.webkit.org/show_bug.cgi?id=176261
+
+Reviewed by Antonio Gomes.
+
+Extend tiled-drawing-async-frame-scrolling with new test cases and update expectations.
+
+* compositing/tiling/tiled-drawing-async-frame-scrolling.html: Add two test cases with
+non-white and fixed gradient background. The latter exhibits a crash fixed by that commit.
+* compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt: Adjust expectation due
+to spacing changes.
+* platform/ios-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt: Ditto.
+Update expectation for the first case to remove the white background and add expectations for
+the two new cases.
+* platform/mac-wk2/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt: Ditto.
+
 2017-11-21  Ms2ger  
 
 [GTK] Enable imported/w3c/web-platform-tests/url/failure.html


Modified: trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt (225088 => 225089)

--- trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt	2017-11-22 01:02:24 UTC (rev 225088)
+++ trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling-expected.txt	2017-11-22 06:30:21 UTC (rev 225089)
@@ -1,2 +1,2 @@
+   
 
-


Modified: trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling.html (225088 => 225089)

--- trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling.html	2017-11-22 01:02:24 UTC (rev 225088)
+++ trunk/LayoutTests/compositing/tiling/tiled-drawing-async-frame-scrolling.html	2017-11-22 06:30:21 UTC 

[webkit-changes] [225070] trunk/Source/WebCore

2017-11-21 Thread fred . wang
Title: [225070] trunk/Source/WebCore








Revision 225070
Author fred.w...@free.fr
Date 2017-11-21 01:19:17 -0800 (Tue, 21 Nov 2017)


Log Message
Remove unintentionally committed .orig file.
https://bugs.webkit.org/show_bug.cgi?id=174131

Unreviewed, fix previous commit.

Patch by Frederic Wang  on 2017-11-21

* rendering/mathml/RenderMathMLScripts.cpp.orig: Removed.

Modified Paths

trunk/Source/WebCore/ChangeLog


Removed Paths

trunk/Source/WebCore/rendering/mathml/RenderMathMLScripts.cpp.orig




Diff

Modified: trunk/Source/WebCore/ChangeLog (225069 => 225070)

--- trunk/Source/WebCore/ChangeLog	2017-11-21 08:37:59 UTC (rev 225069)
+++ trunk/Source/WebCore/ChangeLog	2017-11-21 09:19:17 UTC (rev 225070)
@@ -1,5 +1,14 @@
 2017-11-21  Frederic Wang  
 
+Remove unintentionally committed .orig file.
+https://bugs.webkit.org/show_bug.cgi?id=174131
+
+Unreviewed, fix previous commit.
+
+* rendering/mathml/RenderMathMLScripts.cpp.orig: Removed.
+
+2017-11-21  Frederic Wang  
+
 ASSERTION FAILED: !needsLayout() in WebCore::RenderMathMLScripts::firstLineBaseline
 https://bugs.webkit.org/show_bug.cgi?id=174131
 


Deleted: trunk/Source/WebCore/rendering/mathml/RenderMathMLScripts.cpp.orig (225069 => 225070)

--- trunk/Source/WebCore/rendering/mathml/RenderMathMLScripts.cpp.orig	2017-11-21 08:37:59 UTC (rev 225069)
+++ trunk/Source/WebCore/rendering/mathml/RenderMathMLScripts.cpp.orig	2017-11-21 09:19:17 UTC (rev 225070)
@@ -1,490 +0,0 @@
-/*
- * Copyright (C) 2010 Alex Milowski (a...@milowski.com). All rights reserved.
- * Copyright (C) 2013 The MathJax Consortium.
- * Copyright (C) 2016 Igalia S.L.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *notice, this list of conditions and the following disclaimer in the
- *documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "RenderMathMLScripts.h"
-
-#if ENABLE(MATHML)
-
-#include "MathMLElement.h"
-#include "MathMLScriptsElement.h"
-#include "RenderMathMLOperator.h"
-#include 
-
-namespace WebCore {
-
-WTF_MAKE_ISO_ALLOCATED_IMPL(RenderMathMLScripts);
-
-static bool isPrescriptDelimiter(const RenderObject& renderObject)
-{
-return renderObject.node() && renderObject.node()->hasTagName(MathMLNames::mprescriptsTag);
-}
-
-RenderMathMLScripts::RenderMathMLScripts(MathMLScriptsElement& element, RenderStyle&& style)
-: RenderMathMLBlock(element, WTFMove(style))
-{
-// Determine what kind of sub/sup _expression_ we have by element name
-if (element.hasTagName(MathMLNames::msubTag))
-m_scriptType = Sub;
-else if (element.hasTagName(MathMLNames::msupTag))
-m_scriptType = Super;
-else if (element.hasTagName(MathMLNames::msubsupTag))
-m_scriptType = SubSup;
-else if (element.hasTagName(MathMLNames::munderTag))
-m_scriptType = Under;
-else if (element.hasTagName(MathMLNames::moverTag))
-m_scriptType = Over;
-else if (element.hasTagName(MathMLNames::munderoverTag))
-m_scriptType = UnderOver;
-else {
-ASSERT(element.hasTagName(MathMLNames::mmultiscriptsTag));
-m_scriptType = Multiscripts;
-}
-}
-
-MathMLScriptsElement& RenderMathMLScripts::element() const
-{
-return static_cast(nodeForNonAnonymous());
-}
-
-RenderMathMLOperator* RenderMathMLScripts::unembellishedOperator()
-{
-auto base = firstChildBox();
-if (!is(base))
-return nullptr;
-return downcast(base)->unembellishedOperator();
-}
-
-std::optional RenderMathMLScripts::validateAndGetReferenceChildren()
-{
-// All scripted elements must have at least one child.
-// The first child is the base.
-auto base = firstChildBox();
-if (!base)
-return std::nullopt;
-
-

[webkit-changes] [225069] trunk

2017-11-21 Thread fred . wang
Title: [225069] trunk








Revision 225069
Author fred.w...@free.fr
Date 2017-11-21 00:37:59 -0800 (Tue, 21 Nov 2017)


Log Message
ASSERTION FAILED: !needsLayout() in WebCore::RenderMathMLScripts::firstLineBaseline
https://bugs.webkit.org/show_bug.cgi?id=174131

Patch by Frederic Wang  on 2017-11-21
Reviewed by Alejandro G. Castro.

Source/WebCore:

RenderMathMLScripts::firstLineBaseline() has an ASSERT at the beginning to ensure that the function
is called after the element was laid out. However, this is not respected by HTML table layout as
RenderBlock::firstLineBaseline() is called for elements in a table cell before they are laid out.
This happens for example for RenderGrid::firstLineBaseline() and probably for other renderers.
Additionally, RenderMathMLScripts::firstLineBaseline() only involves calling firstLineBaseline();
logicalTop() or logicalHeight() on the first child box so it is safe to call it before layout, even
if the return value might be wrong at that time. This patch removes this too restrictive ASSERT for
RenderMathMLScripts, for consistency with other implementations of firstLineBaseline().

Test: mathml/cells-and-scripts-crash.html

* rendering/mathml/RenderMathMLScripts.cpp:
(WebCore::RenderMathMLScripts::firstLineBaseline const): Remove the ASSERT.

LayoutTests:

Add tests for calling RenderMathMLScripts::firstLineBaseline with needsLayout() == true.

* mathml/cells-and-scripts-crash-expected.txt: Added.
* mathml/cells-and-scripts-crash.html: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/rendering/mathml/RenderMathMLScripts.cpp


Added Paths

trunk/LayoutTests/mathml/cells-and-scripts-crash-expected.txt
trunk/LayoutTests/mathml/cells-and-scripts-crash.html
trunk/Source/WebCore/rendering/mathml/RenderMathMLScripts.cpp.orig




Diff

Modified: trunk/LayoutTests/ChangeLog (225068 => 225069)

--- trunk/LayoutTests/ChangeLog	2017-11-21 08:03:52 UTC (rev 225068)
+++ trunk/LayoutTests/ChangeLog	2017-11-21 08:37:59 UTC (rev 225069)
@@ -1,3 +1,15 @@
+2017-11-21  Frederic Wang  
+
+ASSERTION FAILED: !needsLayout() in WebCore::RenderMathMLScripts::firstLineBaseline
+https://bugs.webkit.org/show_bug.cgi?id=174131
+
+Reviewed by Alejandro G. Castro.
+
+Add tests for calling RenderMathMLScripts::firstLineBaseline with needsLayout() == true.
+
+* mathml/cells-and-scripts-crash-expected.txt: Added.
+* mathml/cells-and-scripts-crash.html: Added.
+
 2017-11-20  Michael Catanzaro  
 
 Unreviewed, mark one more GTK test as passing


Added: trunk/LayoutTests/mathml/cells-and-scripts-crash-expected.txt (0 => 225069)

--- trunk/LayoutTests/mathml/cells-and-scripts-crash-expected.txt	(rev 0)
+++ trunk/LayoutTests/mathml/cells-and-scripts-crash-expected.txt	2017-11-21 08:37:59 UTC (rev 225069)
@@ -0,0 +1,5 @@
+This test passes if it does not crash
+
+a
+b
+
Property changes on: trunk/LayoutTests/mathml/cells-and-scripts-crash-expected.txt
___


Added: svn:eol-style
+LF
\ No newline at end of property

Added: trunk/LayoutTests/mathml/cells-and-scripts-crash.html (0 => 225069)

--- trunk/LayoutTests/mathml/cells-and-scripts-crash.html	(rev 0)
+++ trunk/LayoutTests/mathml/cells-and-scripts-crash.html	2017-11-21 08:37:59 UTC (rev 225069)
@@ -0,0 +1,39 @@
+
+
+  
+ASSERTION with cell layout and math scripts
+
+
+  if (window.testRunner)
+  testRunner.dumpAsText();
+
+  
+  
+
+This test passes if it does not crash
+
+
+  
+
+  
+
+  
+a
+b
+  
+
+  
+
+  
+
+
+
+  
+
+  
+
+  
+
+
+  
+
Property changes on: trunk/LayoutTests/mathml/cells-and-scripts-crash.html
___


Added: svn:eol-style
+LF
\ No newline at end of property

Added: svn:mime-type
+text/html
\ No newline at end of property

Modified: trunk/Source/WebCore/ChangeLog (225068 => 225069)

--- trunk/Source/WebCore/ChangeLog	2017-11-21 08:03:52 UTC (rev 225068)
+++ trunk/Source/WebCore/ChangeLog	2017-11-21 08:37:59 UTC (rev 225069)
@@ -1,3 +1,24 @@
+2017-11-21  Frederic Wang  
+
+ASSERTION FAILED: !needsLayout() in WebCore::RenderMathMLScripts::firstLineBaseline
+https://bugs.webkit.org/show_bug.cgi?id=174131
+
+Reviewed by Alejandro G. Castro.
+
+RenderMathMLScripts::firstLineBaseline() has an ASSERT at the beginning to ensure that the function
+is called after the element was laid out. However, this is not respected by HTML table layout as
+RenderBlock::firstLineBaseline() is called for elements in a table cell before they are laid out.
+  

[webkit-changes] [224914] trunk/Source/WebCore

2017-11-16 Thread fred . wang
Title: [224914] trunk/Source/WebCore








Revision 224914
Author fred.w...@free.fr
Date 2017-11-16 05:49:02 -0800 (Thu, 16 Nov 2017)


Log Message
Consider non-main frames for frameViewRootLayerDidChange
https://bugs.webkit.org/show_bug.cgi?id=178508

Patch by Frederic Wang  on 2017-11-16
Reviewed by Antonio Gomes.

No new tests, behavior unchanged.

AsyncScrollingCoordinator::frameViewRootLayerDidChange assumes that frameView is always a
main-frame. It calls ensureRootStateNodeForFrameView, which always attaches a frame node with
null parent ID. It also has an ASSERT to check m_scrollingStateTree->rootStateNode(), instead
of m_scrollingStateTree->stateNodeForID(frameView.scrollLayerID()). This patch makes the
ASSERT more generic. It also adds an early return into ensureRootStateNodeForFrameView when the
node already exists so that the call to attachToStateTree can be skipped. It turns out that that
call is actually only necessary for main frame, so another ASSERT is added to verify it.

* page/scrolling/AsyncScrollingCoordinator.cpp:
(WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange): Modify the ASSERT to
verify the availability of a scrolling node for the frame, not just the root node.
(WebCore::AsyncScrollingCoordinator::ensureRootStateNodeForFrameView): Add an early return to
skip the call to attachToStateTree when the node is actually already available. Add an ASSERT to
ensure that attaching a new node is only necessary for main frames.

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp




Diff

Modified: trunk/Source/WebCore/ChangeLog (224913 => 224914)

--- trunk/Source/WebCore/ChangeLog	2017-11-16 12:48:22 UTC (rev 224913)
+++ trunk/Source/WebCore/ChangeLog	2017-11-16 13:49:02 UTC (rev 224914)
@@ -1,3 +1,27 @@
+2017-11-16  Frederic Wang  
+
+Consider non-main frames for frameViewRootLayerDidChange
+https://bugs.webkit.org/show_bug.cgi?id=178508
+
+Reviewed by Antonio Gomes.
+
+No new tests, behavior unchanged.
+
+AsyncScrollingCoordinator::frameViewRootLayerDidChange assumes that frameView is always a
+main-frame. It calls ensureRootStateNodeForFrameView, which always attaches a frame node with
+null parent ID. It also has an ASSERT to check m_scrollingStateTree->rootStateNode(), instead
+of m_scrollingStateTree->stateNodeForID(frameView.scrollLayerID()). This patch makes the
+ASSERT more generic. It also adds an early return into ensureRootStateNodeForFrameView when the
+node already exists so that the call to attachToStateTree can be skipped. It turns out that that
+call is actually only necessary for main frame, so another ASSERT is added to verify it.
+
+* page/scrolling/AsyncScrollingCoordinator.cpp:
+(WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange): Modify the ASSERT to
+verify the availability of a scrolling node for the frame, not just the root node.
+(WebCore::AsyncScrollingCoordinator::ensureRootStateNodeForFrameView): Add an early return to
+skip the call to attachToStateTree when the node is actually already available. Add an ASSERT to
+ensure that attaching a new node is only necessary for main frames.
+
 2017-11-16  Miguel Gomez  
 
 [TexMap] Remove use of GraphicsContext3D


Modified: trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp (224913 => 224914)

--- trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp	2017-11-16 12:48:22 UTC (rev 224913)
+++ trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp	2017-11-16 13:49:02 UTC (rev 224914)
@@ -220,7 +220,7 @@
 
 // If the root layer does not have a ScrollingStateNode, then we should create one.
 ensureRootStateNodeForFrameView(frameView);
-ASSERT(m_scrollingStateTree->rootStateNode());
+ASSERT(m_scrollingStateTree->stateNodeForID(frameView.scrollLayerID()));
 
 ScrollingCoordinator::frameViewRootLayerDidChange(frameView);
 
@@ -512,6 +512,12 @@
 void AsyncScrollingCoordinator::ensureRootStateNodeForFrameView(FrameView& frameView)
 {
 ASSERT(frameView.scrollLayerID());
+if (m_scrollingStateTree->stateNodeForID(frameView.scrollLayerID()))
+return;
+
+// For non-main frames, it is only possible to arrive in this function from
+// RenderLayerCompositor::updateBacking where the node has already been created.
+ASSERT(frameView.frame().isMainFrame());
 attachToStateTree(FrameScrollingNode, frameView.scrollLayerID(), 0);
 }
 






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


[webkit-changes] [224910] trunk

2017-11-16 Thread fred . wang
Title: [224910] trunk








Revision 224910
Author fred.w...@free.fr
Date 2017-11-16 00:14:33 -0800 (Thu, 16 Nov 2017)


Log Message
ASSERTION FAILED: !isAnonymous() in WebCore::RenderMathMLOperator::updateTokenContent
https://bugs.webkit.org/show_bug.cgi?id=166011

Patch by Frederic Wang  on 2017-11-16
Reviewed by Alejandro G. Castro.

Source/WebCore:

RenderMathMLFencedOperator does not support mathvariant or displaystyle transforms. This is
one of several issues of the mfenced element (see bug 160509). However,
MathMLStyle::updateStyleIfNeeded() still tries to use the implementation of the parent
RenderMathMLOperator class, which only works for non-anonymous operators. This patch skips
the updateTokenContent() calls for anonymous mfenced operators in order to avoid ASSERTION
failures.

Test: mathml/mfenced-displaystyle-and-mathvariant-crash.html

* rendering/mathml/MathMLStyle.cpp:
(WebCore::MathMLStyle::updateStyleIfNeeded): Skip anonymous token elements.

LayoutTests:

Add a crash test checking displaystyle and mathvariant on mfenced operators.

* mathml/mfenced-displaystyle-and-mathvariant-crash-expected.txt: Added.
* mathml/mfenced-displaystyle-and-mathvariant-crash.html: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/rendering/mathml/MathMLStyle.cpp


Added Paths

trunk/LayoutTests/mathml/mfenced-displaystyle-and-mathvariant-crash-expected.txt
trunk/LayoutTests/mathml/mfenced-displaystyle-and-mathvariant-crash.html




Diff

Modified: trunk/LayoutTests/ChangeLog (224909 => 224910)

--- trunk/LayoutTests/ChangeLog	2017-11-16 03:05:02 UTC (rev 224909)
+++ trunk/LayoutTests/ChangeLog	2017-11-16 08:14:33 UTC (rev 224910)
@@ -1,3 +1,15 @@
+2017-11-16  Frederic Wang  
+
+ASSERTION FAILED: !isAnonymous() in WebCore::RenderMathMLOperator::updateTokenContent
+https://bugs.webkit.org/show_bug.cgi?id=166011
+
+Reviewed by Alejandro G. Castro.
+
+Add a crash test checking displaystyle and mathvariant on mfenced operators.
+
+* mathml/mfenced-displaystyle-and-mathvariant-crash-expected.txt: Added.
+* mathml/mfenced-displaystyle-and-mathvariant-crash.html: Added.
+
 2017-11-15  Youenn Fablet  
 
 Service Worker fetch should handle empty responses


Added: trunk/LayoutTests/mathml/mfenced-displaystyle-and-mathvariant-crash-expected.txt (0 => 224910)

--- trunk/LayoutTests/mathml/mfenced-displaystyle-and-mathvariant-crash-expected.txt	(rev 0)
+++ trunk/LayoutTests/mathml/mfenced-displaystyle-and-mathvariant-crash-expected.txt	2017-11-16 08:14:33 UTC (rev 224910)
@@ -0,0 +1,10 @@
+This test passes if it does not crash
+
+0
+1
+2
+ 
+0
+1
+2
+
Property changes on: trunk/LayoutTests/mathml/mfenced-displaystyle-and-mathvariant-crash-expected.txt
___


Added: svn:eol-style
+LF
\ No newline at end of property

Added: trunk/LayoutTests/mathml/mfenced-displaystyle-and-mathvariant-crash.html (0 => 224910)

--- trunk/LayoutTests/mathml/mfenced-displaystyle-and-mathvariant-crash.html	(rev 0)
+++ trunk/LayoutTests/mathml/mfenced-displaystyle-and-mathvariant-crash.html	2017-11-16 08:14:33 UTC (rev 224910)
@@ -0,0 +1,32 @@
+
+
+  
+displaystyle/mathvariant on anonymous mfenced operators
+
+
+if (window.testRunner)
+testRunner.dumpAsText();
+
+  
+  
+
+This test passes if it does not crash
+
+
+  
+0
+1
+2
+  
+
+
+
+  
+0
+1
+2
+  
+
+
+  
+
Property changes on: trunk/LayoutTests/mathml/mfenced-displaystyle-and-mathvariant-crash.html
___


Added: svn:eol-style
+LF
\ No newline at end of property

Added: svn:mime-type
+text/html
\ No newline at end of property

Modified: trunk/Source/WebCore/ChangeLog (224909 => 224910)

--- trunk/Source/WebCore/ChangeLog	2017-11-16 03:05:02 UTC (rev 224909)
+++ trunk/Source/WebCore/ChangeLog	2017-11-16 08:14:33 UTC (rev 224910)
@@ -1,3 +1,22 @@
+2017-11-16  Frederic Wang  
+
+ASSERTION FAILED: !isAnonymous() in WebCore::RenderMathMLOperator::updateTokenContent
+https://bugs.webkit.org/show_bug.cgi?id=166011
+
+Reviewed by Alejandro G. Castro.
+
+RenderMathMLFencedOperator does not support mathvariant or displaystyle transforms. This is
+one of several issues of the mfenced element (see bug 160509). However,
+MathMLStyle::updateStyleIfNeeded() still tries to use the implementation of the parent
+RenderMathMLOperator class, which only works for non-anonymous operators. This patch skips
+the updateTokenContent() calls for anonymous mfenced operators in order to avoid ASSERTION
+failures.
+
+Test: 

[webkit-changes] [224894] trunk

2017-11-15 Thread fred . wang
Title: [224894] trunk








Revision 224894
Author fred.w...@free.fr
Date 2017-11-15 12:07:51 -0800 (Wed, 15 Nov 2017)


Log Message
ASSERTION FAILED: !renderer->needsLayout() in WebCore::RenderBlock::checkPositionedObjectsNeedLayout with MathML
https://bugs.webkit.org/show_bug.cgi?id=178865

Patch by Frederic Wang  on 2017-11-15
Reviewed by Manuel Rego Casasnovas.

Source/WebCore:

MathML token elements can contain HTML elements and hence MathML elements can contain
out-of-flow positioned descendants. Also all MathML elements can be containing block and hence
should position their out-of-flow positioned descendants before calling clearNeedsLayout().
This patch does that in all places in the MathML renderer classes, except a few of them:
- RenderMathMLSpace, which can not have descendants.
- RenderMathMLToken and RenderMathMLOperator, since they will use the layout implementation
  of RenderMathMLBlock when they contain non-text children.
The patch also fixes an ASSERTION failure in WebCore::RenderBlock::checkPositionedObjectsNeedLayout
due to some descendants that are not laid out.

Test: mathml/out-of-flow-in-token-crash.html

* rendering/mathml/RenderMathMLBlock.cpp:
(WebCore::RenderMathMLBlock::layoutBlock): Call layoutPositionedObjects.
(WebCore::RenderMathMLBlock::layoutInvalidMarkup): Ditto and pass the relayoutChildren boolean.
* rendering/mathml/RenderMathMLBlock.h: Add a relayoutChildren boolean to layoutInvalidMarkup.
* rendering/mathml/RenderMathMLFraction.cpp:
(WebCore::RenderMathMLFraction::layoutBlock): Pass the relayoutChildren boolean to layoutInvalidMarkup
and call layoutPositionedObjects.
* rendering/mathml/RenderMathMLRoot.cpp:
(WebCore::RenderMathMLRoot::layoutBlock): Ditto.
* rendering/mathml/RenderMathMLScripts.cpp:
(WebCore::RenderMathMLScripts::layoutBlock): Ditto.
* rendering/mathml/RenderMathMLUnderOver.cpp:
(WebCore::RenderMathMLUnderOver::layoutBlock): Ditto.
* rendering/mathml/RenderMathMLMenclose.cpp:
(WebCore::RenderMathMLMenclose::layoutBlock): Call layoutPositionedObjects.
* rendering/mathml/RenderMathMLPadded.cpp:
(WebCore::RenderMathMLPadded::layoutBlock): Ditto.
* rendering/mathml/RenderMathMLRow.cpp:
(WebCore::RenderMathMLRow::layoutBlock): Ditto.

LayoutTests:

Add a test to trigger various clearNeedsLayout() in a MathML containing block with
out-of-flow positioned descendants.

* mathml/out-of-flow-in-token-crash-expected.txt: Added.
* mathml/out-of-flow-in-token-crash.html: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/rendering/mathml/RenderMathMLBlock.cpp
trunk/Source/WebCore/rendering/mathml/RenderMathMLBlock.h
trunk/Source/WebCore/rendering/mathml/RenderMathMLFraction.cpp
trunk/Source/WebCore/rendering/mathml/RenderMathMLMenclose.cpp
trunk/Source/WebCore/rendering/mathml/RenderMathMLPadded.cpp
trunk/Source/WebCore/rendering/mathml/RenderMathMLRoot.cpp
trunk/Source/WebCore/rendering/mathml/RenderMathMLRow.cpp
trunk/Source/WebCore/rendering/mathml/RenderMathMLScripts.cpp
trunk/Source/WebCore/rendering/mathml/RenderMathMLUnderOver.cpp


Added Paths

trunk/LayoutTests/mathml/out-of-flow-in-token-crash-expected.txt
trunk/LayoutTests/mathml/out-of-flow-in-token-crash.html




Diff

Modified: trunk/LayoutTests/ChangeLog (224893 => 224894)

--- trunk/LayoutTests/ChangeLog	2017-11-15 20:02:04 UTC (rev 224893)
+++ trunk/LayoutTests/ChangeLog	2017-11-15 20:07:51 UTC (rev 224894)
@@ -1,3 +1,16 @@
+2017-11-15  Frederic Wang  
+
+ASSERTION FAILED: !renderer->needsLayout() in WebCore::RenderBlock::checkPositionedObjectsNeedLayout with MathML
+https://bugs.webkit.org/show_bug.cgi?id=178865
+
+Reviewed by Manuel Rego Casasnovas.
+
+Add a test to trigger various clearNeedsLayout() in a MathML containing block with
+out-of-flow positioned descendants.
+
+* mathml/out-of-flow-in-token-crash-expected.txt: Added.
+* mathml/out-of-flow-in-token-crash.html: Added.
+
 2017-11-15  Nan Wang  
 
 [GTK] accessibility/accessibility-object-model.html fails


Added: trunk/LayoutTests/mathml/out-of-flow-in-token-crash-expected.txt (0 => 224894)

--- trunk/LayoutTests/mathml/out-of-flow-in-token-crash-expected.txt	(rev 0)
+++ trunk/LayoutTests/mathml/out-of-flow-in-token-crash-expected.txt	2017-11-15 20:07:51 UTC (rev 224894)
@@ -0,0 +1,25 @@
+This test passes if it does not crash
+
+RenderMathMLFenced
+
+RenderMathMLFraction
+
+RenderMathMLMath
+
+RenderMathMLMenclose
+
+RenderMathMLOperator
+
+RenderMathMLPadded
+
+RenderMathMLRoot
+
+RenderMathMLRow
+RenderMathMLScripts
+
+RenderMathMLToken
+
+RenderMathMLUnderOver
+
+RenderMathMLBlock (invalid markup)
+
Property changes on: trunk/LayoutTests/mathml/out-of-flow-in-token-crash-expected.txt
___


Added: svn:eol-style
+LF
\ No newline at end of property

Added: 

[webkit-changes] [224396] trunk/Source/WebKit

2017-11-03 Thread fred . wang
Title: [224396] trunk/Source/WebKit








Revision 224396
Author fred.w...@free.fr
Date 2017-11-03 08:11:04 -0700 (Fri, 03 Nov 2017)


Log Message
Use WK_IOS_TBA instead of WK_MAC_TBA to indicate availability of private functions on iOS
https://bugs.webkit.org/show_bug.cgi?id=179238

Patch by Frederic Wang  on 2017-11-03
Reviewed by Darin Adler.

* UIProcess/API/Cocoa/WKWebViewPrivate.h:
* UIProcess/API/Cocoa/WKWebsiteDataStorePrivate.h:

Modified Paths

trunk/Source/WebKit/ChangeLog
trunk/Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivate.h
trunk/Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStorePrivate.h




Diff

Modified: trunk/Source/WebKit/ChangeLog (224395 => 224396)

--- trunk/Source/WebKit/ChangeLog	2017-11-03 15:01:44 UTC (rev 224395)
+++ trunk/Source/WebKit/ChangeLog	2017-11-03 15:11:04 UTC (rev 224396)
@@ -1,3 +1,13 @@
+2017-11-03  Frederic Wang  
+
+Use WK_IOS_TBA instead of WK_MAC_TBA to indicate availability of private functions on iOS
+https://bugs.webkit.org/show_bug.cgi?id=179238
+
+Reviewed by Darin Adler.
+
+* UIProcess/API/Cocoa/WKWebViewPrivate.h:
+* UIProcess/API/Cocoa/WKWebsiteDataStorePrivate.h:
+
 2017-11-02  Maciej Stachowiak  
 
 Don't try to guess plugin MIME type from a file extension in a URL (no observable effect)


Modified: trunk/Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivate.h (224395 => 224396)

--- trunk/Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivate.h	2017-11-03 15:01:44 UTC (rev 224395)
+++ trunk/Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivate.h	2017-11-03 15:11:04 UTC (rev 224396)
@@ -436,7 +436,7 @@
 - (void)_setFooterBannerHeight:(int)height WK_API_AVAILABLE(macosx(10.12.3));
 #endif
 
-- (void)_requestActiveNowPlayingSessionInfo:(void(^)(BOOL, NSString*, double, double, NSInteger))callback WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_MAC_TBA));
+- (void)_requestActiveNowPlayingSessionInfo:(void(^)(BOOL, NSString*, double, double, NSInteger))callback WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));
 
 - (void)_setPageScale:(CGFloat)scale withOrigin:(CGPoint)origin WK_API_AVAILABLE(ios(10.3));
 - (CGFloat)_pageScale WK_API_AVAILABLE(ios(10.3));


Modified: trunk/Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStorePrivate.h (224395 => 224396)

--- trunk/Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStorePrivate.h	2017-11-03 15:01:44 UTC (rev 224395)
+++ trunk/Source/WebKit/UIProcess/API/Cocoa/WKWebsiteDataStorePrivate.h	2017-11-03 15:11:04 UTC (rev 224396)
@@ -45,11 +45,11 @@
 - (void)_fetchDataRecordsOfTypes:(NSSet *)dataTypes withOptions:(_WKWebsiteDataStoreFetchOptions)options completionHandler:(void (^)(NSArray *))completionHandler;
 
 @property (nonatomic, setter=_setResourceLoadStatisticsEnabled:) BOOL _resourceLoadStatisticsEnabled WK_API_AVAILABLE(macosx(10.12), ios(10.0));
-@property (nonatomic, setter=_setCacheStoragePerOriginQuota:) NSUInteger _cacheStoragePerOriginQuota WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_MAC_TBA));
-@property (nonatomic, setter=_setCacheStorageDirectory:) NSString* _cacheStorageDirectory WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_MAC_TBA));
+@property (nonatomic, setter=_setCacheStoragePerOriginQuota:) NSUInteger _cacheStoragePerOriginQuota WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));
+@property (nonatomic, setter=_setCacheStorageDirectory:) NSString* _cacheStorageDirectory WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));
 
-@property (nonatomic, setter=_setBoundInterfaceIdentifier:) NSString *_boundInterfaceIdentifier WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_MAC_TBA));
-@property (nonatomic, setter=_setAllowsCellularAccess:) BOOL _allowsCellularAccess WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_MAC_TBA));
+@property (nonatomic, setter=_setBoundInterfaceIdentifier:) NSString *_boundInterfaceIdentifier WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));
+@property (nonatomic, setter=_setAllowsCellularAccess:) BOOL _allowsCellularAccess WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));
 
 // ResourceLoadStatistics SPI for testing.
 - (void)_resourceLoadStatisticsSetLastSeen:(double)seconds forHost:(NSString *)host WK_API_AVAILABLE(macosx(10.13), ios(11.0));






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


[webkit-changes] [224395] trunk/Source/WebCore

2017-11-03 Thread fred . wang
Title: [224395] trunk/Source/WebCore








Revision 224395
Author fred.w...@free.fr
Date 2017-11-03 08:01:44 -0700 (Fri, 03 Nov 2017)


Log Message
Add USE(APPLE_INTERNAL_SDK)-guards around SPI in ResourceHandle code
https://bugs.webkit.org/show_bug.cgi?id=136107

Based on patch by Daniel Bates 
Patch by Frederic Wang  on 2017-11-03
Reviewed by Darin Adler.

No new tests, behavior unchanged.

* platform/network/ResourceHandleClient.h: Replace includes of private headers with CFNetworkSPI.h.
* platform/network/ResourceHandleInternal.h: Ditto.
* platform/network/ios/ResourceHandleIOS.mm: Add USE(APPLE_INTERNAL_SDK)-guard around SPI
headers and forward declare NSURLRequest SPI and constant _kCFStreamSSLTrustedLeafCertificates
for clients that build without the internal SDK. Add BSD license block to file.
(WebCore::ResourceHandle::createSSLPropertiesFromNSURLRequest): Fix code style issues; use
nullptr instead of 0, use reinterpret_cast instead of C-style cast, remove unnecessary
"using namespace WebCore"
and rename variables to improve readability.
* platform/network/mac/ResourceErrorMac.mm: Add USE(APPLE_INTERNAL_SDK)-guard around private
headers and add typedef for CFCachedURLResponseRef for clients that build without the
internal SDK.

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/platform/network/ResourceHandleClient.h
trunk/Source/WebCore/platform/network/ResourceHandleInternal.h
trunk/Source/WebCore/platform/network/ios/ResourceHandleIOS.mm
trunk/Source/WebCore/platform/network/mac/ResourceErrorMac.mm




Diff

Modified: trunk/Source/WebCore/ChangeLog (224394 => 224395)

--- trunk/Source/WebCore/ChangeLog	2017-11-03 14:46:17 UTC (rev 224394)
+++ trunk/Source/WebCore/ChangeLog	2017-11-03 15:01:44 UTC (rev 224395)
@@ -1,3 +1,26 @@
+2017-11-03  Frederic Wang  
+
+Add USE(APPLE_INTERNAL_SDK)-guards around SPI in ResourceHandle code
+https://bugs.webkit.org/show_bug.cgi?id=136107
+
+Based on patch by Daniel Bates 
+Reviewed by Darin Adler.
+
+No new tests, behavior unchanged.
+
+* platform/network/ResourceHandleClient.h: Replace includes of private headers with CFNetworkSPI.h.
+* platform/network/ResourceHandleInternal.h: Ditto.
+* platform/network/ios/ResourceHandleIOS.mm: Add USE(APPLE_INTERNAL_SDK)-guard around SPI
+headers and forward declare NSURLRequest SPI and constant _kCFStreamSSLTrustedLeafCertificates
+for clients that build without the internal SDK. Add BSD license block to file.
+(WebCore::ResourceHandle::createSSLPropertiesFromNSURLRequest): Fix code style issues; use
+nullptr instead of 0, use reinterpret_cast instead of C-style cast, remove unnecessary
+"using namespace WebCore"
+and rename variables to improve readability.
+* platform/network/mac/ResourceErrorMac.mm: Add USE(APPLE_INTERNAL_SDK)-guard around private
+headers and add typedef for CFCachedURLResponseRef for clients that build without the
+internal SDK.
+
 2017-11-03  Antti Koivisto  
 
 Crash in WebCore::RenderStyle::overflowX with display:contents


Modified: trunk/Source/WebCore/platform/network/ResourceHandleClient.h (224394 => 224395)

--- trunk/Source/WebCore/platform/network/ResourceHandleClient.h	2017-11-03 14:46:17 UTC (rev 224394)
+++ trunk/Source/WebCore/platform/network/ResourceHandleClient.h	2017-11-03 15:01:44 UTC (rev 224395)
@@ -30,8 +30,7 @@
 #include 
 
 #if USE(CFURLCONNECTION)
-#include 
-#include 
+#include 
 #endif
 
 #if PLATFORM(IOS) || USE(CFURLCONNECTION)


Modified: trunk/Source/WebCore/platform/network/ResourceHandleInternal.h (224394 => 224395)

--- trunk/Source/WebCore/platform/network/ResourceHandleInternal.h	2017-11-03 14:46:17 UTC (rev 224394)
+++ trunk/Source/WebCore/platform/network/ResourceHandleInternal.h	2017-11-03 15:01:44 UTC (rev 224395)
@@ -34,7 +34,7 @@
 
 #if USE(CFURLCONNECTION)
 #include "ResourceHandleCFURLConnectionDelegate.h"
-#include 
+#include 
 #endif
 
 #if USE(CURL) && PLATFORM(WIN)


Modified: trunk/Source/WebCore/platform/network/ios/ResourceHandleIOS.mm (224394 => 224395)

--- trunk/Source/WebCore/platform/network/ios/ResourceHandleIOS.mm	2017-11-03 14:46:17 UTC (rev 224394)
+++ trunk/Source/WebCore/platform/network/ios/ResourceHandleIOS.mm	2017-11-03 15:01:44 UTC (rev 224395)
@@ -1,9 +1,27 @@
-//
-//  ResourceHandleIPhone.mm
-//  WebCore
-//
-//  Copyright 2011 Apple Inc. All rights reserved.
-//
+/*
+ * Copyright (C) 2011-2017 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above 

[webkit-changes] [224330] trunk

2017-11-02 Thread fred . wang
Title: [224330] trunk








Revision 224330
Author fred.w...@free.fr
Date 2017-11-02 06:56:48 -0700 (Thu, 02 Nov 2017)


Log Message
Add references to bug 179167 in FIXME comments
https://bugs.webkit.org/show_bug.cgi?id=179168

Patch by Frederic Wang  on 2017-11-02
Reviewed by Daniel Bates.

Source/_javascript_Core:

* Configurations/FeatureDefines.xcconfig:

Source/WebCore:

* Configurations/FeatureDefines.xcconfig:

Source/WebCore/PAL:

* Configurations/FeatureDefines.xcconfig:

Source/WebKit:

* Configurations/FeatureDefines.xcconfig:

Source/WebKitLegacy/mac:

* Configurations/FeatureDefines.xcconfig:

Source/WTF:

* wtf/FeatureDefines.h:

Tools:

* TestWebKitAPI/Configurations/FeatureDefines.xcconfig:

Modified Paths

trunk/Source/_javascript_Core/ChangeLog
trunk/Source/_javascript_Core/Configurations/FeatureDefines.xcconfig
trunk/Source/WTF/ChangeLog
trunk/Source/WTF/wtf/FeatureDefines.h
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/Configurations/FeatureDefines.xcconfig
trunk/Source/WebCore/PAL/ChangeLog
trunk/Source/WebCore/PAL/Configurations/FeatureDefines.xcconfig
trunk/Source/WebKit/ChangeLog
trunk/Source/WebKit/Configurations/FeatureDefines.xcconfig
trunk/Source/WebKitLegacy/mac/ChangeLog
trunk/Source/WebKitLegacy/mac/Configurations/FeatureDefines.xcconfig
trunk/Tools/ChangeLog
trunk/Tools/TestWebKitAPI/Configurations/FeatureDefines.xcconfig




Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (224329 => 224330)

--- trunk/Source/_javascript_Core/ChangeLog	2017-11-02 13:41:16 UTC (rev 224329)
+++ trunk/Source/_javascript_Core/ChangeLog	2017-11-02 13:56:48 UTC (rev 224330)
@@ -1,3 +1,12 @@
+2017-11-02  Frederic Wang  
+
+Add references to bug 179167 in FIXME comments
+https://bugs.webkit.org/show_bug.cgi?id=179168
+
+Reviewed by Daniel Bates.
+
+* Configurations/FeatureDefines.xcconfig:
+
 2017-11-01  Jeremy Jones  
 
 Implement WKFullscreenWindowController for iOS.


Modified: trunk/Source/_javascript_Core/Configurations/FeatureDefines.xcconfig (224329 => 224330)

--- trunk/Source/_javascript_Core/Configurations/FeatureDefines.xcconfig	2017-11-02 13:41:16 UTC (rev 224329)
+++ trunk/Source/_javascript_Core/Configurations/FeatureDefines.xcconfig	2017-11-02 13:56:48 UTC (rev 224330)
@@ -189,7 +189,7 @@
 ENABLE_USER_MESSAGE_HANDLERS = ENABLE_USER_MESSAGE_HANDLERS;
 
 // FIXME: Remove the USE_INTERNAL_SDK condition once we support touch events when building for iOS with
-// the public SDK. We will also need to update FeatureDefines.h.
+// the public SDK. See .
 ENABLE_TOUCH_EVENTS[sdk=iphone*] = $(ENABLE_TOUCH_EVENTS_ios_WITH_INTERNAL_SDK_$(USE_INTERNAL_SDK));
 ENABLE_TOUCH_EVENTS_ios_WITH_INTERNAL_SDK_YES = ENABLE_TOUCH_EVENTS;
 


Modified: trunk/Source/WTF/ChangeLog (224329 => 224330)

--- trunk/Source/WTF/ChangeLog	2017-11-02 13:41:16 UTC (rev 224329)
+++ trunk/Source/WTF/ChangeLog	2017-11-02 13:56:48 UTC (rev 224330)
@@ -1,3 +1,12 @@
+2017-11-02  Frederic Wang  
+
+Add references to bug 179167 in FIXME comments
+https://bugs.webkit.org/show_bug.cgi?id=179168
+
+Reviewed by Daniel Bates.
+
+* wtf/FeatureDefines.h:
+
 2017-11-01  Jiewen Tan  
 
 Let is() accept RefPtrs


Modified: trunk/Source/WTF/wtf/FeatureDefines.h (224329 => 224330)

--- trunk/Source/WTF/wtf/FeatureDefines.h	2017-11-02 13:41:16 UTC (rev 224329)
+++ trunk/Source/WTF/wtf/FeatureDefines.h	2017-11-02 13:56:48 UTC (rev 224330)
@@ -139,7 +139,7 @@
 #endif
 
 /* FIXME: Remove the USE(APPLE_INTERNAL_SDK) conjunct once we support touch events when building against
-the public iOS SDK. We will also need to update the FeatureDefines.xcconfig files. */
+the public iOS SDK. See . */
 #if !defined(ENABLE_TOUCH_EVENTS) && USE(APPLE_INTERNAL_SDK)
 #define ENABLE_TOUCH_EVENTS 1
 #endif


Modified: trunk/Source/WebCore/ChangeLog (224329 => 224330)

--- trunk/Source/WebCore/ChangeLog	2017-11-02 13:41:16 UTC (rev 224329)
+++ trunk/Source/WebCore/ChangeLog	2017-11-02 13:56:48 UTC (rev 224330)
@@ -1,3 +1,12 @@
+2017-11-02  Frederic Wang  
+
+Add references to bug 179167 in FIXME comments
+https://bugs.webkit.org/show_bug.cgi?id=179168
+
+Reviewed by Daniel Bates.
+
+* Configurations/FeatureDefines.xcconfig:
+
 2017-11-02  Antti Koivisto  
 
 Remove empty continuations in RenderObject::removeFromParentAndDestroyCleaningUpAnonymousWrappers


Modified: trunk/Source/WebCore/Configurations/FeatureDefines.xcconfig (224329 => 224330)

--- trunk/Source/WebCore/Configurations/FeatureDefines.xcconfig	2017-11-02 13:41:16 UTC (rev 224329)
+++ trunk/Source/WebCore/Configurations/FeatureDefines.xcconfig	2017-11-02 13:56:48 UTC (rev 224330)
@@ -189,7 +189,7 @@
 ENABLE_USER_MESSAGE_HANDLERS = ENABLE_USER_MESSAGE_HANDLERS;
 
 // FIXME: Remove the USE_INTERNAL_SDK condition once we support touch events 

[webkit-changes] [224284] trunk

2017-11-01 Thread fred . wang
Title: [224284] trunk








Revision 224284
Author fred.w...@free.fr
Date 2017-11-01 11:50:36 -0700 (Wed, 01 Nov 2017)


Log Message
Make iOS Find UI reveal matches in scrollable elements
https://bugs.webkit.org/show_bug.cgi?id=178789

Patch by Frederic Wang  on 2017-11-01
Reviewed by Tim Horton.

Source/WebKit:

* WebProcess/WebPage/ios/FindControllerIOS.mm:
(WebKit::FindController::didFindString): Reveal selection up to the main frame. The main frame
is handled by the SmartMagnificationController.

Tools:

This patch exposes WKWebView's findString function in order to test the fix for bug 178789.

* DumpRenderTree/ios/UIScriptControllerIOS.mm:
(WTR::UIScriptController::findString): Dummy implementation of findString.
* DumpRenderTree/mac/UIScriptControllerMac.mm:
(WTR::UIScriptController::findString): Ditto.
* TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl: Declare findString.
* TestRunnerShared/UIScriptContext/UIScriptController.cpp:
(WTR::UIScriptController::findString): Dummy implementation of findString.
* TestRunnerShared/UIScriptContext/UIScriptController.h: Declare findString.
* WebKitTestRunner/ios/UIScriptControllerIOS.mm:
(WTR::UIScriptController::findString): Implement findString by forwarding the call to the
web view.
* WebKitTestRunner/mac/UIScriptControllerMac.mm:
(WTR::UIScriptController::findString): Dummy implementation of findString.

LayoutTests:

Adds a test to verify that an overflow node is scrolled to reveal results it contains when
iOS's Find UI is used.

* platform/ios/fast/scrolling/find-text-in-overflow-node-expected.txt: Added.
* platform/ios/fast/scrolling/find-text-in-overflow-node.html: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/Source/WebKit/ChangeLog
trunk/Source/WebKit/WebProcess/WebPage/ios/FindControllerIOS.mm
trunk/Tools/ChangeLog
trunk/Tools/DumpRenderTree/ios/UIScriptControllerIOS.mm
trunk/Tools/DumpRenderTree/mac/UIScriptControllerMac.mm
trunk/Tools/TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl
trunk/Tools/TestRunnerShared/UIScriptContext/UIScriptController.cpp
trunk/Tools/TestRunnerShared/UIScriptContext/UIScriptController.h
trunk/Tools/WebKitTestRunner/ios/UIScriptControllerIOS.mm
trunk/Tools/WebKitTestRunner/mac/UIScriptControllerMac.mm


Added Paths

trunk/LayoutTests/platform/ios/fast/scrolling/find-text-in-overflow-node-expected.txt
trunk/LayoutTests/platform/ios/fast/scrolling/find-text-in-overflow-node.html




Diff

Modified: trunk/LayoutTests/ChangeLog (224283 => 224284)

--- trunk/LayoutTests/ChangeLog	2017-11-01 18:43:57 UTC (rev 224283)
+++ trunk/LayoutTests/ChangeLog	2017-11-01 18:50:36 UTC (rev 224284)
@@ -1,3 +1,16 @@
+2017-11-01  Frederic Wang  
+
+Make iOS Find UI reveal matches in scrollable elements
+https://bugs.webkit.org/show_bug.cgi?id=178789
+
+Reviewed by Tim Horton.
+
+Adds a test to verify that an overflow node is scrolled to reveal results it contains when
+iOS's Find UI is used.
+
+* platform/ios/fast/scrolling/find-text-in-overflow-node-expected.txt: Added.
+* platform/ios/fast/scrolling/find-text-in-overflow-node.html: Added.
+
 2017-11-01  Per Arne Vollan  
 
 Mark fast/dom/Window/window-resize-update-scrollbars.html as a timeout on Windows.


Added: trunk/LayoutTests/platform/ios/fast/scrolling/find-text-in-overflow-node-expected.txt (0 => 224284)

--- trunk/LayoutTests/platform/ios/fast/scrolling/find-text-in-overflow-node-expected.txt	(rev 0)
+++ trunk/LayoutTests/platform/ios/fast/scrolling/find-text-in-overflow-node-expected.txt	2017-11-01 18:50:36 UTC (rev 224284)
@@ -0,0 +1,13 @@
+Use iOS Find UI to search for the text "match". The following overflow node should scroll to show the fourth result.
+
+match 2
+
+match 3
+
+match 4
+
+
+PASS Initial position of overflow node 
+PASS Position of overflow node after the three first results 
+PASS Position of overflow node after the fourth result 
+
Property changes on: trunk/LayoutTests/platform/ios/fast/scrolling/find-text-in-overflow-node-expected.txt
___


Added: svn:eol-style
+LF
\ No newline at end of property

Added: trunk/LayoutTests/platform/ios/fast/scrolling/find-text-in-overflow-node.html (0 => 224284)

--- trunk/LayoutTests/platform/ios/fast/scrolling/find-text-in-overflow-node.html	(rev 0)
+++ trunk/LayoutTests/platform/ios/fast/scrolling/find-text-in-overflow-node.html	2017-11-01 18:50:36 UTC (rev 224284)
@@ -0,0 +1,58 @@
+
+
+  
+Find text in overflow node
+
+
+  setup({ "explicit_done": true });
+  function run() {
+if (!window.testRunner || !testRunner.runUIScript)
+  return;
+
+var node = document.getElementById("scrollable");
+test(function() {
+  assert_equals(node.scrollTop, 0);
+}, "Initial position of overflow 

[webkit-changes] [224180] trunk/Tools

2017-10-30 Thread fred . wang
Title: [224180] trunk/Tools








Revision 224180
Author fred.w...@free.fr
Date 2017-10-30 07:44:25 -0700 (Mon, 30 Oct 2017)


Log Message
Remove support for running safari on the iOS simulator with Xcode < 9.0
https://bugs.webkit.org/show_bug.cgi?id=178203

Patch by Frederic Wang  on 2017-10-12
Reviewed by Alexey Proskuryakov.

This is a follow-up of r223234. We no longer support iOS WebKit development for Xcode < 9.0
and do not have any iOS simulator builders in our infrastructure. Hence we can remove the
special case to calculate the iOS simulator applications path for these old versions.

* Scripts/webkitdirs.pm:
(iosSimulatorApplicationsPath): Remove special case for XCode < 9.0

Modified Paths

trunk/Tools/ChangeLog
trunk/Tools/Scripts/webkitdirs.pm




Diff

Modified: trunk/Tools/ChangeLog (224179 => 224180)

--- trunk/Tools/ChangeLog	2017-10-30 14:20:47 UTC (rev 224179)
+++ trunk/Tools/ChangeLog	2017-10-30 14:44:25 UTC (rev 224180)
@@ -1,3 +1,17 @@
+2017-10-12  Frederic Wang  
+
+Remove support for running safari on the iOS simulator with Xcode < 9.0
+https://bugs.webkit.org/show_bug.cgi?id=178203
+
+Reviewed by Alexey Proskuryakov.
+
+This is a follow-up of r223234. We no longer support iOS WebKit development for Xcode < 9.0
+and do not have any iOS simulator builders in our infrastructure. Hence we can remove the
+special case to calculate the iOS simulator applications path for these old versions.
+
+* Scripts/webkitdirs.pm:
+(iosSimulatorApplicationsPath): Remove special case for XCode < 9.0
+
 2017-10-30  Michael Catanzaro  
 
 [WPE][GTK] Expose availability of certain editing commands in WebKitEditorState


Modified: trunk/Tools/Scripts/webkitdirs.pm (224179 => 224180)

--- trunk/Tools/Scripts/webkitdirs.pm	2017-10-30 14:20:47 UTC (rev 224179)
+++ trunk/Tools/Scripts/webkitdirs.pm	2017-10-30 14:44:25 UTC (rev 224180)
@@ -2460,11 +2460,6 @@
 
 sub iosSimulatorApplicationsPath()
 {
-determineXcodeVersion();
-if (eval "v$xcodeVersion" lt v9.0) {
-return File::Spec->catdir(XcodeSDKPath(), "Applications");
-}
-
 my $iphoneOSPlatformPath = sdkPlatformDirectory("iphoneos");
 return File::Spec->catdir($iphoneOSPlatformPath, "Developer", "Library", "CoreSimulator", "Profiles", "Runtimes", "iOS.simruntime", "Contents", "Resources", "RuntimeRoot", "Applications");
 }






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


[webkit-changes] [224110] trunk/Source/WebCore

2017-10-27 Thread fred . wang
Title: [224110] trunk/Source/WebCore








Revision 224110
Author fred.w...@free.fr
Date 2017-10-27 07:38:41 -0700 (Fri, 27 Oct 2017)


Log Message
Use auto for some variables in RenderLayerCompositor/Backing
https://bugs.webkit.org/show_bug.cgi?id=178570

Patch by Frederic Wang  on 2017-10-27
Reviewed by Darin Adler.

No new tests, behavior unchanged.

* rendering/RenderLayerBacking.cpp:
(WebCore::canvasCompositingStrategy):
(WebCore::RenderLayerBacking::RenderLayerBacking):
(WebCore::computePageTiledBackingCoverage):
(WebCore::RenderLayerBacking::layerWillBeDestroyed):
(WebCore::RenderLayerBacking::updateBackdropFiltersGeometry):
(WebCore::layerOrAncestorIsTransformedOrUsingCompositedScrolling):
(WebCore::RenderLayerBacking::updateCompositedBounds):
(WebCore::RenderLayerBacking::updateAfterWidgetResize):
(WebCore::RenderLayerBacking::updateAfterLayout):
(WebCore::RenderLayerBacking::updateConfiguration):
(WebCore::ComputedOffsets::fromAncestorGraphicsLayer):
(WebCore::RenderLayerBacking::updateGeometry):
(WebCore::RenderLayerBacking::updateInternalHierarchy):
(WebCore::RenderLayerBacking::positionOverflowControlsLayers):
(WebCore::RenderLayerBacking::hasUnpositionedOverflowControlsLayers const):
(WebCore::RenderLayerBacking::compositingOpacity const):
(WebCore::isRestartedPlugin):
(WebCore::RenderLayerBacking::isDirectlyCompositedImage const):
(WebCore::RenderLayerBacking::updateImageContents):
(WebCore::RenderLayerBacking::setContentsNeedDisplay):
(WebCore::RenderLayerBacking::setContentsNeedDisplayInRect):
(WebCore::RenderLayerBacking::getCurrentTransform const):
(WebCore::RenderLayerBacking::logFilledVisibleFreshTile):
(WebCore::RenderLayerBacking::startAnimation):
(WebCore::RenderLayerBacking::compositedBoundsIncludingMargin const):
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::flushPendingLayerChanges):
(WebCore::RenderLayerCompositor::updateScrollCoordinatedLayersAfterFlushIncludingSubframes):
(WebCore::updateScrollingLayerWithClient):
(WebCore::RenderLayerCompositor::didFlushChangesForLayer):
(WebCore::RenderLayerCompositor::didPaintBacking):
(WebCore::RenderLayerCompositor::didChangeVisibleRect):
(WebCore::RenderLayerCompositor::enclosingCompositorFlushingLayers const):
(WebCore::RenderLayerCompositor::updateCompositingLayers):
(WebCore::RenderLayerCompositor::appendDocumentOverlayLayers):
(WebCore::RenderLayerCompositor::logLayerInfo):
(WebCore::checkIfDescendantClippingContextNeedsUpdate):
(WebCore::styleChangeRequiresLayerRebuild):
(WebCore::RenderLayerCompositor::canCompositeClipPath):
(WebCore::rendererForCompositingTests):
(WebCore::RenderLayerCompositor::updateBacking):
(WebCore::RenderLayerCompositor::repaintOnCompositingChange):
(WebCore::RenderLayerCompositor::repaintInCompositedAncestor):
(WebCore::RenderLayerCompositor::enclosingNonStackingClippingLayer const):
(WebCore::RenderLayerCompositor::setCompositingParent):
(WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
(WebCore::RenderLayerCompositor::hasCoordinatedScrolling const):
(WebCore::RenderLayerCompositor::updateScrollLayerPosition):
(WebCore::RenderLayerCompositor::positionForClipLayer const):
(WebCore::RenderLayerCompositor::frameViewDidLayout):
(WebCore::RenderLayerCompositor::rootFixedBackgroundsChanged):
(WebCore::RenderLayerCompositor::scrollingLayerDidChange):
(WebCore::RenderLayerCompositor::frameContentsCompositor):
(WebCore::RenderLayerCompositor::parentFrameContentLayers):
(WebCore::RenderLayerCompositor::updateLayerTreeGeometry):
(WebCore::RenderLayerCompositor::updateCompositingDescendantGeometry):
(WebCore::RenderLayerCompositor::setIsInWindow):
(WebCore::RenderLayerCompositor::clearBackingForLayerIncludingDescendants):
(WebCore::RenderLayerCompositor::clippedByAncestor const):
(WebCore::RenderLayerCompositor::requiresCompositingForBackfaceVisibility const):
(WebCore::RenderLayerCompositor::requiresCompositingForCanvas const):
(WebCore::RenderLayerCompositor::requiresCompositingForPlugin const):
(WebCore::RenderLayerCompositor::requiresCompositingForAnimation const):
(WebCore::RenderLayerCompositor::requiresCompositingForIndirectReason const):
(WebCore::RenderLayerCompositor::isAsyncScrollableStickyLayer const):
(WebCore::RenderLayerCompositor::isViewportConstrainedFixedOrStickyLayer const):
(WebCore::RenderLayerCompositor::requiresScrollLayer const):
(WebCore::RenderLayerCompositor::supportsFixedRootBackgroundCompositing const):
(WebCore::RenderLayerCompositor::fixedRootBackgroundLayer const):
(WebCore::RenderLayerCompositor::resetTrackedRepaintRects):
(WebCore::RenderLayerCompositor::contentsScaleMultiplierForNewTiles const):
(WebCore::RenderLayerCompositor::documentUsesTiledBacking const):
(WebCore::RenderLayerCompositor::shouldCompositeOverflowControls const):
(WebCore::RenderLayerCompositor::updateLayerForHeader):
(WebCore::RenderLayerCompositor::updateLayerForFooter):
(WebCore::RenderLayerCompositor::updateOverflowControlsLayers):

[webkit-changes] [223339] trunk/Source/WebCore

2017-10-16 Thread fred . wang
Title: [223339] trunk/Source/WebCore








Revision 223339
Author fred.w...@free.fr
Date 2017-10-16 00:58:15 -0700 (Mon, 16 Oct 2017)


Log Message
Use auto/nullptr in scrolling code
https://bugs.webkit.org/show_bug.cgi?id=178306

Patch by Frederic Wang  on 2017-10-16
Reviewed by Carlos Garcia Campos.

This patch modifies the scrolling code to use the auto keyword when
possible. It also replaces '0' with 'nullptr' for the return value of
ScrollingStateTree::stateNodeForID.

No new tests, behavior unchanged.

* page/scrolling/AsyncScrollingCoordinator.cpp:
(WebCore::AsyncScrollingCoordinator::frameViewLayoutUpdated):
(WebCore::AsyncScrollingCoordinator::frameViewRootLayerDidChange):
(WebCore::AsyncScrollingCoordinator::requestScrollPositionUpdate):
(WebCore::AsyncScrollingCoordinator::frameViewForScrollingNode const):
(WebCore::AsyncScrollingCoordinator::updateScrollPositionAfterAsyncScroll):
(WebCore::AsyncScrollingCoordinator::reconcileScrollingState):
(WebCore::AsyncScrollingCoordinator::updateFrameScrollingNode):
(WebCore::AsyncScrollingCoordinator::updateOverflowScrollingNode):
(WebCore::AsyncScrollingCoordinator::updateNodeLayer):
(WebCore::AsyncScrollingCoordinator::updateNodeViewportConstraints):
(WebCore::AsyncScrollingCoordinator::setSynchronousScrollingReasons):
(WebCore::AsyncScrollingCoordinator::updateScrollLayerPosition):
(WebCore::AsyncScrollingCoordinator::setActiveScrollSnapIndices):
* page/scrolling/ScrollingCoordinator.cpp:
(WebCore::ScrollingCoordinator::coordinatesScrollingForFrameView const):
(WebCore::ScrollingCoordinator::absoluteEventTrackingRegionsForFrame const):
(WebCore::ScrollingCoordinator::scrollLayerForFrameView):
(WebCore::ScrollingCoordinator::headerLayerForFrameView):
(WebCore::ScrollingCoordinator::footerLayerForFrameView):
(WebCore::ScrollingCoordinator::counterScrollingLayerForFrameView):
(WebCore::ScrollingCoordinator::insetClipLayerForFrameView):
(WebCore::ScrollingCoordinator::contentShadowLayerForFrameView):
(WebCore::ScrollingCoordinator::rootContentLayerForFrameView):
(WebCore::ScrollingCoordinator::handleWheelEventPhase):
(WebCore::ScrollingCoordinator::hasVisibleSlowRepaintViewportConstrainedObjects const):
(WebCore::ScrollingCoordinator::updateSynchronousScrollingReasonsForAllFrames):
(WebCore::ScrollingCoordinator::synchronousScrollingReasonsAsText const):
* page/scrolling/ScrollingStateFixedNode.cpp:
(WebCore::ScrollingStateFixedNode::reconcileLayerPositionForViewportRect):
* page/scrolling/ScrollingStateStickyNode.cpp:
(WebCore::ScrollingStateStickyNode::reconcileLayerPositionForViewportRect):
* page/scrolling/ScrollingStateTree.cpp:
(WebCore::ScrollingStateTree::nodeTypeAndParentMatch const):
(WebCore::ScrollingStateTree::attachNode):
(WebCore::ScrollingStateTree::detachNode):
(WebCore::ScrollingStateTree::removeNodeAndAllDescendants):
(WebCore::ScrollingStateTree::stateNodeForID const):
* page/scrolling/ScrollingTree.cpp:
(WebCore::ScrollingTree::shouldHandleWheelEventSynchronously):
(WebCore::ScrollingTree::viewportChangedViaDelegatedScrolling):
(WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling):
(WebCore::ScrollingTree::commitTreeState):
(WebCore::ScrollingTree::updateTreeFromStateNode):
* page/scrolling/ScrollingTreeNode.cpp:
(WebCore::ScrollingTreeNode::enclosingFrameNode const):
* page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp:
(WebCore::ScrollingCoordinatorCoordinatedGraphics::detachFromStateTree):
(WebCore::ScrollingCoordinatorCoordinatedGraphics::updateNodeLayer):
(WebCore::ScrollingCoordinatorCoordinatedGraphics::updateNodeViewportConstraints):
(WebCore::ScrollingCoordinatorCoordinatedGraphics::scrollableAreaScrollLayerDidChange):
(WebCore::ScrollingCoordinatorCoordinatedGraphics::willDestroyScrollableArea):

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp
trunk/Source/WebCore/page/scrolling/ScrollingCoordinator.cpp
trunk/Source/WebCore/page/scrolling/ScrollingStateFixedNode.cpp
trunk/Source/WebCore/page/scrolling/ScrollingStateStickyNode.cpp
trunk/Source/WebCore/page/scrolling/ScrollingStateTree.cpp
trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp
trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.cpp
trunk/Source/WebCore/page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp




Diff

Modified: trunk/Source/WebCore/ChangeLog (223338 => 223339)

--- trunk/Source/WebCore/ChangeLog	2017-10-16 07:48:05 UTC (rev 223338)
+++ trunk/Source/WebCore/ChangeLog	2017-10-16 07:58:15 UTC (rev 223339)
@@ -1,3 +1,69 @@
+2017-10-16  Frederic Wang  
+
+Use auto/nullptr in scrolling code
+https://bugs.webkit.org/show_bug.cgi?id=178306
+
+Reviewed by Carlos Garcia Campos.
+
+This patch modifies the scrolling code to use the auto keyword when
+possible. It also replaces '0' with 'nullptr' for the return value of
+

[webkit-changes] [223337] trunk/Source/WebCore

2017-10-16 Thread fred . wang
Title: [223337] trunk/Source/WebCore








Revision 223337
Author fred.w...@free.fr
Date 2017-10-16 00:04:48 -0700 (Mon, 16 Oct 2017)


Log Message
Replace some ScrollingTreeNode::nodeType() calls with is*Node()
https://bugs.webkit.org/show_bug.cgi?id=178259

Patch by Frederic Wang  on 2017-10-16
Reviewed by Darin Adler.

No new tests, behavior unchanged.

* page/scrolling/AsyncScrollingCoordinator.cpp:
(WebCore::AsyncScrollingCoordinator::frameViewForScrollingNode const):
* page/scrolling/ScrollingStateNode.h:
(WebCore::ScrollingStateNode::isScrollingNode const):
* page/scrolling/ScrollingTree.cpp:
(WebCore::ScrollingTree::updateTreeFromStateNode):
* page/scrolling/ScrollingTreeNode.cpp:
(WebCore::ScrollingTreeNode::enclosingFrameNode const):
* page/scrolling/ScrollingTreeNode.h:
(WebCore::ScrollingTreeNode::isScrollingNode const):

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp
trunk/Source/WebCore/page/scrolling/ScrollingStateNode.h
trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp
trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.cpp
trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.h




Diff

Modified: trunk/Source/WebCore/ChangeLog (223336 => 223337)

--- trunk/Source/WebCore/ChangeLog	2017-10-16 06:25:54 UTC (rev 223336)
+++ trunk/Source/WebCore/ChangeLog	2017-10-16 07:04:48 UTC (rev 223337)
@@ -1,3 +1,23 @@
+2017-10-16  Frederic Wang  
+
+Replace some ScrollingTreeNode::nodeType() calls with is*Node()
+https://bugs.webkit.org/show_bug.cgi?id=178259
+
+Reviewed by Darin Adler.
+
+No new tests, behavior unchanged.
+
+* page/scrolling/AsyncScrollingCoordinator.cpp:
+(WebCore::AsyncScrollingCoordinator::frameViewForScrollingNode const):
+* page/scrolling/ScrollingStateNode.h:
+(WebCore::ScrollingStateNode::isScrollingNode const):
+* page/scrolling/ScrollingTree.cpp:
+(WebCore::ScrollingTree::updateTreeFromStateNode):
+* page/scrolling/ScrollingTreeNode.cpp:
+(WebCore::ScrollingTreeNode::enclosingFrameNode const):
+* page/scrolling/ScrollingTreeNode.h:
+(WebCore::ScrollingTreeNode::isScrollingNode const):
+
 2017-10-16  Tomas Popela  
 
 DataTransfer.cpp triggers -Wunused-but-set-variable


Modified: trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp (223336 => 223337)

--- trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp	2017-10-16 06:25:54 UTC (rev 223336)
+++ trunk/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp	2017-10-16 07:04:48 UTC (rev 223337)
@@ -307,7 +307,7 @@
 
 // Find the enclosing frame scrolling node.
 ScrollingStateNode* parentNode = stateNode;
-while (parentNode && parentNode->nodeType() != FrameScrollingNode)
+while (parentNode && !parentNode->isFrameScrollingNode())
 parentNode = parentNode->parent();
 
 if (!parentNode)


Modified: trunk/Source/WebCore/page/scrolling/ScrollingStateNode.h (223336 => 223337)

--- trunk/Source/WebCore/page/scrolling/ScrollingStateNode.h	2017-10-16 06:25:54 UTC (rev 223336)
+++ trunk/Source/WebCore/page/scrolling/ScrollingStateNode.h	2017-10-16 07:04:48 UTC (rev 223337)
@@ -196,7 +196,7 @@
 
 bool isFixedNode() const { return m_nodeType == FixedNode; }
 bool isStickyNode() const { return m_nodeType == StickyNode; }
-bool isScrollingNode() const { return m_nodeType == FrameScrollingNode || m_nodeType == OverflowScrollingNode; }
+bool isScrollingNode() const { return isFrameScrollingNode() || isOverflowScrollingNode(); }
 bool isFrameScrollingNode() const { return m_nodeType == FrameScrollingNode; }
 bool isOverflowScrollingNode() const { return m_nodeType == OverflowScrollingNode; }
 


Modified: trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp (223336 => 223337)

--- trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp	2017-10-16 06:25:54 UTC (rev 223336)
+++ trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp	2017-10-16 07:04:48 UTC (rev 223337)
@@ -167,7 +167,7 @@
 node = createScrollingTreeNode(stateNode->nodeType(), nodeID);
 if (!parentNodeID) {
 // This is the root node. Clear the node map.
-ASSERT(stateNode->nodeType() == FrameScrollingNode);
+ASSERT(stateNode->isFrameScrollingNode());
 m_rootNode = node;
 m_nodeMap.clear();
 } 


Modified: trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.cpp (223336 => 223337)

--- trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.cpp	2017-10-16 06:25:54 UTC (rev 223336)
+++ trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.cpp	2017-10-16 07:04:48 UTC (rev 223337)
@@ -82,7 +82,7 @@
 ScrollingTreeFrameScrollingNode* ScrollingTreeNode::enclosingFrameNode() const
 {
 ScrollingTreeNode* node = parent();
-while (node && node->nodeType() != 

[webkit-changes] [223240] trunk/Source/WebCore

2017-10-12 Thread fred . wang
Title: [223240] trunk/Source/WebCore








Revision 223240
Author fred.w...@free.fr
Date 2017-10-12 10:42:12 -0700 (Thu, 12 Oct 2017)


Log Message
Use less specific cast in ScrollingTree::scrollPositionChangedViaDelegatedScrolling
https://bugs.webkit.org/show_bug.cgi?id=178211

Patch by Frederic Wang  on 2017-10-12
Reviewed by Simon Fraser.

No new tests, behavior is not changed.

ScrollingTree::scrollPositionChangedViaDelegatedScrolling is a generic function that applies
to scrolling nodes. Casting to more specific ScrollingTreeOverflowScrollingNodes is however
not necessary to implement it. This patch moves to the least specific cast necessary so that
this function will be usable for async scrolling of non-main frames in the future. Note that
the function is currently only called from ScrollingTreeScrollingNodeDelegateIOS which in
turn is only used by the ScrollingTreeScrollingOverflowNodeIOS class and so code behavior is
not changed.

* page/scrolling/ScrollingTree.cpp:
(WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling): Only cast the node to
ScrollingTreeScrollingNode.

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp




Diff

Modified: trunk/Source/WebCore/ChangeLog (223239 => 223240)

--- trunk/Source/WebCore/ChangeLog	2017-10-12 16:02:45 UTC (rev 223239)
+++ trunk/Source/WebCore/ChangeLog	2017-10-12 17:42:12 UTC (rev 223240)
@@ -1,3 +1,24 @@
+2017-10-12  Frederic Wang  
+
+Use less specific cast in ScrollingTree::scrollPositionChangedViaDelegatedScrolling
+https://bugs.webkit.org/show_bug.cgi?id=178211
+
+Reviewed by Simon Fraser.
+
+No new tests, behavior is not changed.
+
+ScrollingTree::scrollPositionChangedViaDelegatedScrolling is a generic function that applies
+to scrolling nodes. Casting to more specific ScrollingTreeOverflowScrollingNodes is however
+not necessary to implement it. This patch moves to the least specific cast necessary so that
+this function will be usable for async scrolling of non-main frames in the future. Note that
+the function is currently only called from ScrollingTreeScrollingNodeDelegateIOS which in
+turn is only used by the ScrollingTreeScrollingOverflowNodeIOS class and so code behavior is
+not changed.
+
+* page/scrolling/ScrollingTree.cpp:
+(WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling): Only cast the node to
+ScrollingTreeScrollingNode.
+
 2017-10-11  Sam Weinig  
 
 Remove out-parameter variants of copyToVector


Modified: trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp (223239 => 223240)

--- trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp	2017-10-12 16:02:45 UTC (rev 223239)
+++ trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp	2017-10-12 17:42:12 UTC (rev 223240)
@@ -34,7 +34,6 @@
 #include "ScrollingStateTree.h"
 #include "ScrollingTreeFrameScrollingNode.h"
 #include "ScrollingTreeNode.h"
-#include "ScrollingTreeOverflowScrollingNode.h"
 #include "ScrollingTreeScrollingNode.h"
 #include 
 #include 
@@ -105,11 +104,11 @@
 void ScrollingTree::scrollPositionChangedViaDelegatedScrolling(ScrollingNodeID nodeID, const WebCore::FloatPoint& scrollPosition, bool inUserInteraction)
 {
 ScrollingTreeNode* node = nodeForID(nodeID);
-if (!is(node))
+if (!is(node))
 return;
 
 // Update descendant nodes
-downcast(*node).updateLayersAfterDelegatedScroll(scrollPosition);
+downcast(*node).updateLayersAfterDelegatedScroll(scrollPosition);
 
 // Update GraphicsLayers and scroll state.
 scrollingTreeNodeDidScroll(nodeID, scrollPosition, std::nullopt, inUserInteraction ? ScrollingLayerPositionAction::Sync : ScrollingLayerPositionAction::Set);






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


[webkit-changes] [223234] trunk/Tools

2017-10-12 Thread fred . wang
Title: [223234] trunk/Tools








Revision 223234
Author fred.w...@free.fr
Date 2017-10-12 01:37:53 -0700 (Thu, 12 Oct 2017)


Log Message
run-safari --ios-simulator is no longer working with Xcode 9
https://bugs.webkit.org/show_bug.cgi?id=177595

Patch by Frederic Wang  on 2017-10-11
Reviewed by Daniel Bates.

In Xcode 9, the path of the simulator application is now in a new CoreSimulator subdirectory
of the iphoneOS SDK platform. This patch updates webkitdirs.pm to use the new path in
Xcode 9 or higher so that it is possible to run Safari on the iOS simulator again. It also
does some minor code refactoring to improve code reuse.

* Scripts/configure-xcode-for-ios-development: Move sdkDirectory() and sdkPlatformDirectory()
into webkitdirs.
(sdkDirectory): Deleted.
(sdkPlatformDirectory): Deleted.
* Scripts/webkitdirs.pm: Expose new sdkDirectory() and sdkPlatformDirectory().
(sdkDirectory): Moved from configure-xcode-for-ios-development.
(sdkPlatformDirectory): Ditto.
(XcodeSDKPath): Rely on sdkDirectory() to implement this function.
(iosSimulatorApplicationsPath): In Xcode 9 or higher use the new path. It is calculated
by relying on sdkPlatformDirectory().

Modified Paths

trunk/Tools/ChangeLog
trunk/Tools/Scripts/configure-xcode-for-ios-development
trunk/Tools/Scripts/webkitdirs.pm




Diff

Modified: trunk/Tools/ChangeLog (223233 => 223234)

--- trunk/Tools/ChangeLog	2017-10-12 06:46:24 UTC (rev 223233)
+++ trunk/Tools/ChangeLog	2017-10-12 08:37:53 UTC (rev 223234)
@@ -1,3 +1,26 @@
+2017-10-11  Frederic Wang  
+
+run-safari --ios-simulator is no longer working with Xcode 9
+https://bugs.webkit.org/show_bug.cgi?id=177595
+
+Reviewed by Daniel Bates.
+
+In Xcode 9, the path of the simulator application is now in a new CoreSimulator subdirectory
+of the iphoneOS SDK platform. This patch updates webkitdirs.pm to use the new path in
+Xcode 9 or higher so that it is possible to run Safari on the iOS simulator again. It also
+does some minor code refactoring to improve code reuse.
+
+* Scripts/configure-xcode-for-ios-development: Move sdkDirectory() and sdkPlatformDirectory()
+into webkitdirs.
+(sdkDirectory): Deleted.
+(sdkPlatformDirectory): Deleted.
+* Scripts/webkitdirs.pm: Expose new sdkDirectory() and sdkPlatformDirectory().
+(sdkDirectory): Moved from configure-xcode-for-ios-development.
+(sdkPlatformDirectory): Ditto.
+(XcodeSDKPath): Rely on sdkDirectory() to implement this function.
+(iosSimulatorApplicationsPath): In Xcode 9 or higher use the new path. It is calculated
+by relying on sdkPlatformDirectory().
+
 2017-10-11  Dewei Zhu  
 
 run-benchmark script should set '__XPC_DYLD_FRAMEWORK_PATH' while launching local-built Safari on Mac.


Modified: trunk/Tools/Scripts/configure-xcode-for-ios-development (223233 => 223234)

--- trunk/Tools/Scripts/configure-xcode-for-ios-development	2017-10-12 06:46:24 UTC (rev 223233)
+++ trunk/Tools/Scripts/configure-xcode-for-ios-development	2017-10-12 08:37:53 UTC (rev 223234)
@@ -45,8 +45,6 @@
 sub createLegacyXcodeSpecificationFilesForSDKIfNeeded($);
 sub mergeXcodeSpecificationWithSpecificationAndId($$$);
 sub readXcodeSpecificationById($$);
-sub sdkDirectory($);
-sub sdkPlatformDirectory($);
 sub updateXcode7SpecificationFile($);
 sub updateXcodeSpecificationFilesForSDKIfNeeded($);
 sub xcodeSDKSpecificationsPath($);
@@ -212,22 +210,6 @@
 }
 }
 
-sub sdkDirectory($)
-{
-my ($sdkName) = @_;
-chomp(my $sdkDirectory = `xcrun --sdk '$sdkName' --show-sdk-path`);
-die "Failed to get SDK path from xcrun: $!" if exitStatus($?);
-return $sdkDirectory;
-}
-
-sub sdkPlatformDirectory($)
-{
-my ($sdkName) = @_;
-chomp(my $sdkPlatformDirectory = `xcrun --sdk '$sdkName' --show-sdk-platform-path`);
-die "Failed to get SDK platform path from xcrun: $!" if exitStatus($?);
-return $sdkPlatformDirectory;
-}
-
 sub writeXcodeSpecification($$)
 {
 my ($xcodeSpecificationFile, $specification) = @_;


Modified: trunk/Tools/Scripts/webkitdirs.pm (223233 => 223234)

--- trunk/Tools/Scripts/webkitdirs.pm	2017-10-12 06:46:24 UTC (rev 223233)
+++ trunk/Tools/Scripts/webkitdirs.pm	2017-10-12 08:37:53 UTC (rev 223234)
@@ -71,6 +71,7 @@



+   



@@ -82,7 +83,8 @@



-   
+   
+   



@@ -165,6 +167,22 @@
 sub findMatchingArguments($$);
 sub hasArgument($$);
 
+sub sdkDirectory($)
+{
+my ($sdkName) = @_;
+chomp(my $sdkDirectory = `xcrun --sdk '$sdkName' --show-sdk-path`);
+die "Failed to get SDK path from xcrun: $!" if exitStatus($?);
+return $sdkDirectory;
+}
+
+sub sdkPlatformDirectory($)
+{
+my ($sdkName) = @_;
+chomp(my $sdkPlatformDirectory = `xcrun --sdk '$sdkName' --show-sdk-platform-path`);
+die "Failed 

[webkit-changes] [223169] trunk

2017-10-11 Thread fred . wang
Title: [223169] trunk








Revision 223169
Author fred.w...@free.fr
Date 2017-10-11 00:54:37 -0700 (Wed, 11 Oct 2017)


Log Message
[iOS] Do not flatten frames when async frame scrolling is enabled
https://bugs.webkit.org/show_bug.cgi?id=173704

Patch by Frederic Wang  on 2017-09-27
Reviewed by Simon Fraser.

Source/WebCore:

This patch disables frame flattening when async frame scrolling is enabled on iOS, as
otherwise you can not scroll them. Once iframe scrolling is implemented in iOS (bug 149264),
developers and beta testers will be able to check it by enabling "Async Frame Scrolling"
in the "Experimental WebKit Features" menu of Safari iOS.

Test: platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling.html

* page/FrameView.cpp:
(WebCore::FrameView::frameFlatteningEnabled): Use effectiveFrameFlattening()
* page/Settings.cpp:
(WebCore::Settings::effectiveFrameFlattening): New function to return frameFlattening() or do
some exceptions on iOS.
* page/Settings.h: Declare effectiveFrameFlattening.
* rendering/RenderFrameSet.cpp:
(WebCore::RenderFrameSet::flattenFrameSet): Use effectiveFrameFlattening()
* rendering/RenderIFrame.cpp:
(WebCore::RenderIFrame::flattenFrame): Ditto.
* rendering/RenderView.cpp:
(WebCore::FrameFlatteningLayoutDisallower::FrameFlatteningLayoutDisallower): Ditto.

Source/WebKit:

This patch disables frame flattening when async frame scrolling is enabled on iOS, as
otherwise you can not scroll them. Once iframe scrolling is implemented in iOS (bug 149264),
developers and beta testers will be able to check it by enabling "Async Frame Scrolling"
in the "Experimental WebKit Features" menu of Safari iOS.

Test: platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling.html

* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::contentsSizeChanged): Use effectiveFrameFlattening() introduced in
Source/WebCore.

LayoutTests:

Add an iOS test to verify that frame flattening is disabled when async frame scrolling is enabled.

* platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling-expected.txt: Added.
* platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling.html: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/page/FrameView.cpp
trunk/Source/WebCore/page/Settings.cpp
trunk/Source/WebCore/page/Settings.h
trunk/Source/WebCore/rendering/RenderFrameSet.cpp
trunk/Source/WebCore/rendering/RenderIFrame.cpp
trunk/Source/WebCore/rendering/RenderView.cpp
trunk/Source/WebKit/ChangeLog
trunk/Source/WebKit/WebProcess/WebCoreSupport/WebChromeClient.cpp


Added Paths

trunk/LayoutTests/platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling-expected.txt
trunk/LayoutTests/platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling.html




Diff

Modified: trunk/LayoutTests/ChangeLog (223168 => 223169)

--- trunk/LayoutTests/ChangeLog	2017-10-11 05:48:47 UTC (rev 223168)
+++ trunk/LayoutTests/ChangeLog	2017-10-11 07:54:37 UTC (rev 223169)
@@ -1,3 +1,15 @@
+2017-09-27  Frederic Wang  
+
+[iOS] Do not flatten frames when async frame scrolling is enabled
+https://bugs.webkit.org/show_bug.cgi?id=173704
+
+Reviewed by Simon Fraser.
+
+Add an iOS test to verify that frame flattening is disabled when async frame scrolling is enabled.
+
+* platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling-expected.txt: Added.
+* platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling.html: Added.
+
 2017-10-10  Ryosuke Niwa  
 
 Enable custom pasteboard data in DumpRenderTree and WebKitTestRunner


Added: trunk/LayoutTests/platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling-expected.txt (0 => 223169)

--- trunk/LayoutTests/platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling-expected.txt	(rev 0)
+++ trunk/LayoutTests/platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling-expected.txt	2017-10-11 07:54:37 UTC (rev 223169)
@@ -0,0 +1,5 @@
+ 
+
+PASS simple iframe 
+PASS fullscreen iframe 
+
Property changes on: trunk/LayoutTests/platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling-expected.txt
___


Added: svn:eol-style
+LF
\ No newline at end of property

Added: trunk/LayoutTests/platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling.html (0 => 223169)

--- trunk/LayoutTests/platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling.html	(rev 0)
+++ trunk/LayoutTests/platform/ios/fast/frames/flattening/iframe-flattening-with-async-frame-scrolling.html	2017-10-11 07:54:37 UTC (rev 

[webkit-changes] [223042] trunk

2017-10-09 Thread fred . wang
Title: [223042] trunk








Revision 223042
Author fred.w...@free.fr
Date 2017-10-09 02:08:49 -0700 (Mon, 09 Oct 2017)


Log Message
Remove WOFF2 from Source/ThirdParty.
https://bugs.webkit.org/show_bug.cgi?id=177862

Patch by Frederic Wang  on 2017-10-05
Reviewed by Michael Catanzaro.

.:

* Source/CMakeLists.txt: Do not build the woff2 source.
* Source/cmake/FindWOFF2Dec.cmake: Added. New cmake module for woff2.
* Source/cmake/OptionsGTK.cmake: Load the woff2 package.

Source/ThirdParty:

* woff2/CMakeLists.txt: Removed.
* woff2/LICENSE: Removed.
* woff2/README.webkit: Removed.
* woff2/include/woff2/decode.h: Removed.
* woff2/include/woff2/encode.h: Removed.
* woff2/include/woff2/output.h: Removed.
* woff2/src/buffer.h: Removed.
* woff2/src/convert_woff2ttf_*.cc: Removed.
* woff2/src/file.h: Removed.
* woff2/src/font.cc: Removed.
* woff2/src/font.h: Removed.
* woff2/src/glyph.cc: Removed.
* woff2/src/glyph.h: Removed.
* woff2/src/normalize.cc: Removed.
* woff2/src/normalize.h: Removed.
* woff2/src/port.h: Removed.
* woff2/src/round.h: Removed.
* woff2/src/store_bytes.h: Removed.
* woff2/src/table_tags.cc: Removed.
* woff2/src/table_tags.h: Removed.
* woff2/src/transform.cc: Removed.
* woff2/src/transform.h: Removed.
* woff2/src/variable_length.cc: Removed.
* woff2/src/variable_length.h: Removed.
* woff2/src/woff2_common.cc: Removed.
* woff2/src/woff2_common.h: Removed.
* woff2/src/woff2_compress.cc: Removed.
* woff2/src/woff2_dec.cc: Removed.
* woff2/src/woff2_decompress.cc: Removed.
* woff2/src/woff2_enc.cc: Removed.
* woff2/src/woff2_info.cc: Removed.
* woff2/src/woff2_out.cc: Removed.
* woff2/update.sh: Removed.

Source/WebCore:

No new tests, already covered by existing tests.

* CMakeLists.txt: Use the system brotli/woff2 headers/libraries.

Tools:

* Scripts/webkitpy/style/checker.py: Remove woff2.
* gtk/jhbuild.modules: Add new jhbuild module for woff2.

Modified Paths

trunk/ChangeLog
trunk/Source/CMakeLists.txt
trunk/Source/ThirdParty/ChangeLog
trunk/Source/WebCore/CMakeLists.txt
trunk/Source/WebCore/ChangeLog
trunk/Source/cmake/OptionsGTK.cmake
trunk/Tools/ChangeLog
trunk/Tools/Scripts/webkitpy/style/checker.py
trunk/Tools/gtk/jhbuild.modules


Added Paths

trunk/Source/cmake/FindWOFF2Dec.cmake


Removed Paths

trunk/Source/ThirdParty/woff2/




Diff

Modified: trunk/ChangeLog (223041 => 223042)

--- trunk/ChangeLog	2017-10-09 04:08:33 UTC (rev 223041)
+++ trunk/ChangeLog	2017-10-09 09:08:49 UTC (rev 223042)
@@ -1,3 +1,14 @@
+2017-10-05  Frederic Wang  
+
+Remove WOFF2 from Source/ThirdParty.
+https://bugs.webkit.org/show_bug.cgi?id=177862
+
+Reviewed by Michael Catanzaro.
+
+* Source/CMakeLists.txt: Do not build the woff2 source.
+* Source/cmake/FindWOFF2Dec.cmake: Added. New cmake module for woff2.
+* Source/cmake/OptionsGTK.cmake: Load the woff2 package.
+
 2017-10-05  Carlos Alberto Lopez Perez  
 
 Generate a compile error if release is built without compiler optimizations


Modified: trunk/Source/CMakeLists.txt (223041 => 223042)

--- trunk/Source/CMakeLists.txt	2017-10-09 04:08:33 UTC (rev 223041)
+++ trunk/Source/CMakeLists.txt	2017-10-09 09:08:49 UTC (rev 223042)
@@ -17,10 +17,6 @@
 add_subdirectory(ThirdParty/gtest)
 endif ()
 
-if (USE_WOFF2)
-add_subdirectory(ThirdParty/woff2)
-endif ()
-
 if (USE_XDGMIME)
 add_subdirectory(ThirdParty/xdgmime)
 endif ()


Modified: trunk/Source/ThirdParty/ChangeLog (223041 => 223042)

--- trunk/Source/ThirdParty/ChangeLog	2017-10-09 04:08:33 UTC (rev 223041)
+++ trunk/Source/ThirdParty/ChangeLog	2017-10-09 09:08:49 UTC (rev 223042)
@@ -1,5 +1,46 @@
 2017-10-05  Frederic Wang  
 
+Remove WOFF2 from Source/ThirdParty.
+https://bugs.webkit.org/show_bug.cgi?id=177862
+
+Reviewed by Michael Catanzaro.
+
+* woff2/CMakeLists.txt: Removed.
+* woff2/LICENSE: Removed.
+* woff2/README.webkit: Removed.
+* woff2/include/woff2/decode.h: Removed.
+* woff2/include/woff2/encode.h: Removed.
+* woff2/include/woff2/output.h: Removed.
+* woff2/src/buffer.h: Removed.
+* woff2/src/convert_woff2ttf_*.cc: Removed.
+* woff2/src/file.h: Removed.
+* woff2/src/font.cc: Removed.
+* woff2/src/font.h: Removed.
+* woff2/src/glyph.cc: Removed.
+* woff2/src/glyph.h: Removed.
+* woff2/src/normalize.cc: Removed.
+* woff2/src/normalize.h: Removed.
+* woff2/src/port.h: Removed.
+* woff2/src/round.h: Removed.
+* woff2/src/store_bytes.h: Removed.
+* woff2/src/table_tags.cc: Removed.
+* woff2/src/table_tags.h: Removed.
+* woff2/src/transform.cc: Removed.
+* woff2/src/transform.h: Removed.
+* woff2/src/variable_length.cc: Removed.
+* woff2/src/variable_length.h: Removed.
+* woff2/src/woff2_common.cc: Removed.
+* 

[webkit-changes] [222907] trunk

2017-10-05 Thread fred . wang
Title: [222907] trunk








Revision 222907
Author fred.w...@free.fr
Date 2017-10-05 02:32:58 -0700 (Thu, 05 Oct 2017)


Log Message
Remove Brotli from Source/ThirdParty
https://bugs.webkit.org/show_bug.cgi?id=177804

Patch by Frederic Wang  on 2017-10-03
Reviewed by Michael Catanzaro.

.:

* Source/CMakeLists.txt: Do not build ThirdParty/brotli anymore.
* Source/cmake/FindBrotliDec.cmake: Added. New cmake module to find Brotli via PkgConfig.
* Source/cmake/OptionsGTK.cmake: Expose USE_WOFF2 as a public option and use find_package
to look for brotli.

Source/ThirdParty:

* brotli/CMakeLists.txt: Removed.
* brotli/LICENSE: Removed.
* brotli/README.webkit: Removed.
* brotli/common/constants.h: Removed.
* brotli/common/dictionary.bin: Removed.
* brotli/common/dictionary.c: Removed.
* brotli/common/dictionary.h: Removed.
* brotli/common/version.h: Removed.
* brotli/dec/bit_reader.c: Removed.
* brotli/dec/bit_reader.h: Removed.
* brotli/dec/context.h: Removed.
* brotli/dec/decode.c: Removed.
* brotli/dec/huffman.c: Removed.
* brotli/dec/huffman.h: Removed.
* brotli/dec/port.h: Removed.
* brotli/dec/prefix.h: Removed.
* brotli/dec/state.c: Removed.
* brotli/dec/state.h: Removed.
* brotli/dec/transform.h: Removed.
* brotli/include/brotli/decode.h: Removed.
* brotli/include/brotli/encode.h: Removed.
* brotli/include/brotli/port.h: Removed.
* brotli/include/brotli/types.h: Removed.
* brotli/update.sh: Removed.
* woff2/CMakeLists.txt: Use Brotli's include and library paths found by CMake.

Tools:

* gtk/jhbuild.modules: Build brotli 1.0.1 from the official github repository.
* Scripts/webkitpy/style/checker.py: Remove brotli.

Modified Paths

trunk/ChangeLog
trunk/Source/CMakeLists.txt
trunk/Source/ThirdParty/ChangeLog
trunk/Source/ThirdParty/woff2/CMakeLists.txt
trunk/Source/cmake/OptionsGTK.cmake
trunk/Tools/ChangeLog
trunk/Tools/Scripts/webkitpy/style/checker.py
trunk/Tools/gtk/jhbuild.modules


Added Paths

trunk/Source/cmake/FindBrotliDec.cmake


Removed Paths

trunk/Source/ThirdParty/brotli/




Diff

Modified: trunk/ChangeLog (222906 => 222907)

--- trunk/ChangeLog	2017-10-05 09:28:54 UTC (rev 222906)
+++ trunk/ChangeLog	2017-10-05 09:32:58 UTC (rev 222907)
@@ -1,3 +1,15 @@
+2017-10-03  Frederic Wang  
+
+Remove Brotli from Source/ThirdParty
+https://bugs.webkit.org/show_bug.cgi?id=177804
+
+Reviewed by Michael Catanzaro.
+
+* Source/CMakeLists.txt: Do not build ThirdParty/brotli anymore.
+* Source/cmake/FindBrotliDec.cmake: Added. New cmake module to find Brotli via PkgConfig.
+* Source/cmake/OptionsGTK.cmake: Expose USE_WOFF2 as a public option and use find_package
+to look for brotli.
+
 2017-10-05  Yusuke Suzuki  
 
 [Linux] Port MallocBench


Modified: trunk/Source/CMakeLists.txt (222906 => 222907)

--- trunk/Source/CMakeLists.txt	2017-10-05 09:28:54 UTC (rev 222906)
+++ trunk/Source/CMakeLists.txt	2017-10-05 09:32:58 UTC (rev 222907)
@@ -18,7 +18,6 @@
 endif ()
 
 if (USE_WOFF2)
-add_subdirectory(ThirdParty/brotli)
 add_subdirectory(ThirdParty/woff2)
 endif ()
 


Modified: trunk/Source/ThirdParty/ChangeLog (222906 => 222907)

--- trunk/Source/ThirdParty/ChangeLog	2017-10-05 09:28:54 UTC (rev 222906)
+++ trunk/Source/ThirdParty/ChangeLog	2017-10-05 09:32:58 UTC (rev 222907)
@@ -1,3 +1,36 @@
+2017-10-03  Frederic Wang  
+
+Remove Brotli from Source/ThirdParty
+https://bugs.webkit.org/show_bug.cgi?id=177804
+
+Reviewed by Michael Catanzaro.
+
+* brotli/CMakeLists.txt: Removed.
+* brotli/LICENSE: Removed.
+* brotli/README.webkit: Removed.
+* brotli/common/constants.h: Removed.
+* brotli/common/dictionary.bin: Removed.
+* brotli/common/dictionary.c: Removed.
+* brotli/common/dictionary.h: Removed.
+* brotli/common/version.h: Removed.
+* brotli/dec/bit_reader.c: Removed.
+* brotli/dec/bit_reader.h: Removed.
+* brotli/dec/context.h: Removed.
+* brotli/dec/decode.c: Removed.
+* brotli/dec/huffman.c: Removed.
+* brotli/dec/huffman.h: Removed.
+* brotli/dec/port.h: Removed.
+* brotli/dec/prefix.h: Removed.
+* brotli/dec/state.c: Removed.
+* brotli/dec/state.h: Removed.
+* brotli/dec/transform.h: Removed.
+* brotli/include/brotli/decode.h: Removed.
+* brotli/include/brotli/encode.h: Removed.
+* brotli/include/brotli/port.h: Removed.
+* brotli/include/brotli/types.h: Removed.
+* brotli/update.sh: Removed.
+* woff2/CMakeLists.txt: Use Brotli's include and library paths found by CMake.
+
 2017-10-05  Frederic Wang  
 
 Upgrade Brotli to version 1.0.1 and WOFF2 to latest upstream


Modified: trunk/Source/ThirdParty/woff2/CMakeLists.txt (222906 => 222907)

--- trunk/Source/ThirdParty/woff2/CMakeLists.txt	2017-10-05 09:28:54 

[webkit-changes] [222482] trunk/Tools

2017-09-25 Thread fred . wang
Title: [222482] trunk/Tools








Revision 222482
Author fred.w...@free.fr
Date 2017-09-25 17:48:19 -0700 (Mon, 25 Sep 2017)


Log Message
Change my status to reviewer and reformat with validate-committer-lists

Unreviewed.

Patch by Frederic Wang  on 2017-09-25

* Scripts/webkitpy/common/config/contributors.json:

Modified Paths

trunk/Tools/ChangeLog
trunk/Tools/Scripts/webkitpy/common/config/contributors.json




Diff

Modified: trunk/Tools/ChangeLog (222481 => 222482)

--- trunk/Tools/ChangeLog	2017-09-26 00:23:36 UTC (rev 222481)
+++ trunk/Tools/ChangeLog	2017-09-26 00:48:19 UTC (rev 222482)
@@ -1,3 +1,11 @@
+2017-09-25  Frederic Wang  
+
+Change my status to reviewer and reformat with validate-committer-lists
+
+Unreviewed.
+
+* Scripts/webkitpy/common/config/contributors.json:
+
 2017-09-25  Ryan Haddad  
 
 Add High Sierra bots to buildbot and dashboard.


Modified: trunk/Tools/Scripts/webkitpy/common/config/contributors.json (222481 => 222482)

--- trunk/Tools/Scripts/webkitpy/common/config/contributors.json	2017-09-26 00:23:36 UTC (rev 222481)
+++ trunk/Tools/Scripts/webkitpy/common/config/contributors.json	2017-09-26 00:48:19 UTC (rev 222482)
@@ -816,14 +816,6 @@
   ],
   "status" : "committer"
},
-   "Dean Johnson" : {
-  "emails" : [
- "dean_john...@apple.com"
-  ],
-  "nicks" : [
- "deanj"
-  ]
-   },
"Bem Jones-Bey" : {
   "emails" : [
  "bjone...@adobe.com"
@@ -1573,6 +1565,14 @@
   ],
   "status" : "reviewer"
},
+   "Dean Johnson" : {
+  "emails" : [
+ "dean_john...@apple.com"
+  ],
+  "nicks" : [
+ "deanj"
+  ]
+   },
"Denis Nomiyama" : {
   "emails" : [
  "d.nomiy...@samsung.com"
@@ -2060,7 +2060,7 @@
   "nicks" : [
  "fredw"
   ],
-  "status" : "committer"
+  "status" : "reviewer"
},
"Fujii Hironori" : {
   "emails" : [
@@ -4832,7 +4832,7 @@
   ],
   "status" : "committer"
},
-   "Ross Kirsling": {
+   "Ross Kirsling" : {
   "emails" : [
  "ross.kirsl...@sony.com"
   ],
@@ -5940,4 +5940,4 @@
   ],
   "status" : "reviewer"
}
-}
+}
\ No newline at end of file






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


[webkit-changes] [221958] trunk/Source/WebCore

2017-09-13 Thread fred . wang
Title: [221958] trunk/Source/WebCore








Revision 221958
Author fred.w...@free.fr
Date 2017-09-12 23:44:45 -0700 (Tue, 12 Sep 2017)


Log Message
Rename isRootLayer to isRenderViewLayer
https://bugs.webkit.org/show_bug.cgi?id=176684

Patch by Frederic Wang  on 2017-09-12
Reviewed by Darin Adler.

This patch was generated with the help of do-webcore-rename with some coding style adjustment.

No new tests, behavior unchanged.

* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::RenderLayer):
(WebCore::RenderLayer::enclosingTransformedAncestor const):
(WebCore::RenderLayer::enclosingFilterRepaintLayer const):
(WebCore::RenderLayer::setFilterBackendNeedsRepaintingInRect):
(WebCore::RenderLayer::clippingRootForPainting const):
(WebCore::RenderLayer::beginTransparencyLayers):
(WebCore::shouldSuppressPaintingLayer):
(WebCore::RenderLayer::paintFixedLayersInNamedFlows):
(WebCore::RenderLayer::hitTest):
(WebCore::RenderLayer::hitTestFixedLayersInNamedFlows):
(WebCore::RenderLayer::calculateClipRects const):
* rendering/RenderLayer.h:
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::RenderLayerBacking):
(WebCore::RenderLayerBacking::updateConfiguration):
(WebCore::RenderLayerBacking::updateAfterDescendants):
(WebCore::RenderLayerBacking::paintsIntoWindow const):
(WebCore::RenderLayerBacking::paintIntoLayer):
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::logLayerInfo):
(WebCore::RenderLayerCompositor::needsCompositingUpdateForStyleChangeOnNonCompositedLayer const):
(WebCore::RenderLayerCompositor::updateBacking):
(WebCore::RenderLayerCompositor::repaintInCompositedAncestor):
(WebCore::RenderLayerCompositor::addToOverlapMap):
(WebCore::RenderLayerCompositor::computeCompositingRequirementsForNamedFlowFixed):
(WebCore::RenderLayerCompositor::computeCompositingRequirements):
(WebCore::RenderLayerCompositor::rebuildCompositingLayerTreeForNamedFlowFixed):
(WebCore::RenderLayerCompositor::rebuildCompositingLayerTree):
(WebCore::RenderLayerCompositor::needsToBeComposited const):
(WebCore::RenderLayerCompositor::requiresOwnBackingStore const): Also move the IOS condition
up to avoid that check-webkit-style complains.
(WebCore::RenderLayerCompositor::reasonsForCompositing const):
(WebCore::RenderLayerCompositor::useCoordinatedScrollingForLayer const):
(WebCore::RenderLayerCompositor::needsFixedRootBackgroundLayer const):
(WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/rendering/RenderLayer.cpp
trunk/Source/WebCore/rendering/RenderLayer.h
trunk/Source/WebCore/rendering/RenderLayerBacking.cpp
trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp




Diff

Modified: trunk/Source/WebCore/ChangeLog (221957 => 221958)

--- trunk/Source/WebCore/ChangeLog	2017-09-13 04:39:48 UTC (rev 221957)
+++ trunk/Source/WebCore/ChangeLog	2017-09-13 06:44:45 UTC (rev 221958)
@@ -1,3 +1,51 @@
+2017-09-12  Frederic Wang  
+
+Rename isRootLayer to isRenderViewLayer
+https://bugs.webkit.org/show_bug.cgi?id=176684
+
+Reviewed by Darin Adler.
+
+This patch was generated with the help of do-webcore-rename with some coding style adjustment.
+
+No new tests, behavior unchanged.
+
+* rendering/RenderLayer.cpp:
+(WebCore::RenderLayer::RenderLayer):
+(WebCore::RenderLayer::enclosingTransformedAncestor const):
+(WebCore::RenderLayer::enclosingFilterRepaintLayer const):
+(WebCore::RenderLayer::setFilterBackendNeedsRepaintingInRect):
+(WebCore::RenderLayer::clippingRootForPainting const):
+(WebCore::RenderLayer::beginTransparencyLayers):
+(WebCore::shouldSuppressPaintingLayer):
+(WebCore::RenderLayer::paintFixedLayersInNamedFlows):
+(WebCore::RenderLayer::hitTest):
+(WebCore::RenderLayer::hitTestFixedLayersInNamedFlows):
+(WebCore::RenderLayer::calculateClipRects const):
+* rendering/RenderLayer.h:
+* rendering/RenderLayerBacking.cpp:
+(WebCore::RenderLayerBacking::RenderLayerBacking):
+(WebCore::RenderLayerBacking::updateConfiguration):
+(WebCore::RenderLayerBacking::updateAfterDescendants):
+(WebCore::RenderLayerBacking::paintsIntoWindow const):
+(WebCore::RenderLayerBacking::paintIntoLayer):
+* rendering/RenderLayerCompositor.cpp:
+(WebCore::RenderLayerCompositor::logLayerInfo):
+(WebCore::RenderLayerCompositor::needsCompositingUpdateForStyleChangeOnNonCompositedLayer const):
+(WebCore::RenderLayerCompositor::updateBacking):
+(WebCore::RenderLayerCompositor::repaintInCompositedAncestor):
+(WebCore::RenderLayerCompositor::addToOverlapMap):
+(WebCore::RenderLayerCompositor::computeCompositingRequirementsForNamedFlowFixed):
+(WebCore::RenderLayerCompositor::computeCompositingRequirements):
+

[webkit-changes] [221908] trunk/Source/WebCore

2017-09-12 Thread fred . wang
Title: [221908] trunk/Source/WebCore








Revision 221908
Author fred.w...@free.fr
Date 2017-09-12 00:36:57 -0700 (Tue, 12 Sep 2017)


Log Message
Remove unnecessary virtual keyword from JS test files
https://bugs.webkit.org/show_bug.cgi?id=176683

Patch by Frederic Wang  on 2017-09-12
Reviewed by Simon Fraser.

JS bindings headers do not comply with the WebKit coding style since they use both the
"virtual" and "override" keywords. This patch modifies the generator script to only use
"override" and regenerates the bindings accordingly.

No new tests, behavior unchanged.

* bindings/scripts/CodeGeneratorJS.pm:
* bindings/scripts/test/JS/JSTestCallbackFunction.h:
* bindings/scripts/test/JS/JSTestCallbackFunctionRethrow.h:
* bindings/scripts/test/JS/JSTestCallbackFunctionWithThisObject.h:
* bindings/scripts/test/JS/JSTestCallbackFunctionWithTypedefs.h:
* bindings/scripts/test/JS/JSTestCallbackInterface.h:
* bindings/scripts/test/JS/JSTestVoidCallbackFunction.h:

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm
trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunction.h
trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunctionRethrow.h
trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunctionWithThisObject.h
trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunctionWithTypedefs.h
trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackInterface.h
trunk/Source/WebCore/bindings/scripts/test/JS/JSTestVoidCallbackFunction.h




Diff

Modified: trunk/Source/WebCore/ChangeLog (221907 => 221908)

--- trunk/Source/WebCore/ChangeLog	2017-09-12 06:59:48 UTC (rev 221907)
+++ trunk/Source/WebCore/ChangeLog	2017-09-12 07:36:57 UTC (rev 221908)
@@ -1,3 +1,24 @@
+2017-09-12  Frederic Wang  
+
+Remove unnecessary virtual keyword from JS test files
+https://bugs.webkit.org/show_bug.cgi?id=176683
+
+Reviewed by Simon Fraser.
+
+JS bindings headers do not comply with the WebKit coding style since they use both the
+"virtual" and "override" keywords. This patch modifies the generator script to only use
+"override" and regenerates the bindings accordingly.
+
+No new tests, behavior unchanged.
+
+* bindings/scripts/CodeGeneratorJS.pm:
+* bindings/scripts/test/JS/JSTestCallbackFunction.h:
+* bindings/scripts/test/JS/JSTestCallbackFunctionRethrow.h:
+* bindings/scripts/test/JS/JSTestCallbackFunctionWithThisObject.h:
+* bindings/scripts/test/JS/JSTestCallbackFunctionWithTypedefs.h:
+* bindings/scripts/test/JS/JSTestCallbackInterface.h:
+* bindings/scripts/test/JS/JSTestVoidCallbackFunction.h:
+
 2017-09-11  Wenson Hsieh  
 
 [iOS DnD] Support DataTransfer.setDragImage when starting a drag on iOS


Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm (221907 => 221908)

--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm	2017-09-12 06:59:48 UTC (rev 221907)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm	2017-09-12 07:36:57 UTC (rev 221908)
@@ -5862,7 +5862,7 @@
 # FIXME: Change the default name (used for callback functions) to something other than handleEvent. It makes little sense.
 my $functionName = $operation->name || "handleEvent";
 
-push(@$contentRef, "virtual ${nativeReturnType} ${functionName}(" . join(", ", @arguments) . ") override;\n");
+push(@$contentRef, "${nativeReturnType} ${functionName}(" . join(", ", @arguments) . ") override;\n");
 }
 }
 
@@ -5870,7 +5870,7 @@
 
 push(@$contentRef, "${className}(JSC::JSObject*, JSDOMGlobalObject*);\n\n");
 
-push(@$contentRef, "virtual void visitJSFunction(JSC::SlotVisitor&) override;\n\n") if $interfaceOrCallback->extendedAttributes->{IsWeakCallback};
+push(@$contentRef, "void visitJSFunction(JSC::SlotVisitor&) override;\n\n") if $interfaceOrCallback->extendedAttributes->{IsWeakCallback};
 
 push(@$contentRef, "${callbackDataType}* m_data;\n");
 push(@$contentRef, "};\n\n");


Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunction.h (221907 => 221908)

--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunction.h	2017-09-12 06:59:48 UTC (rev 221907)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunction.h	2017-09-12 07:36:57 UTC (rev 221908)
@@ -40,7 +40,7 @@
 JSCallbackDataStrong* callbackData() { return m_data; }
 
 // Functions
-virtual CallbackResult handleEvent(typename IDLLong::ParameterType argument) override;
+CallbackResult handleEvent(typename IDLLong::ParameterType argument) override;
 
 private:
 JSTestCallbackFunction(JSC::JSObject*, JSDOMGlobalObject*);


Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestCallbackFunctionRethrow.h (221907 => 221908)

--- 

[webkit-changes] [221845] trunk/Source/WebCore

2017-09-10 Thread fred . wang
Title: [221845] trunk/Source/WebCore








Revision 221845
Author fred.w...@free.fr
Date 2017-09-10 22:50:21 -0700 (Sun, 10 Sep 2017)


Log Message
Make RenderLayerCompositor always use isRootLayer()
https://bugs.webkit.org/show_bug.cgi?id=176591

Patch by Frederic Wang  on 2017-09-10
Reviewed by Darin Adler.

RenderLayerCompositor contains a few comparisons of the form  == m_renderView.layer().
This patch replaces them with "layer.isRootLayer()" which simply verifies that "layer" is
associated to the one (and only one) RenderView of the RenderLayerCompositor. It makes things
more readable and more consistent with the rest of the file.

No new tests, behavior unchanged.

* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::repaintInCompositedAncestor):
(WebCore::RenderLayerCompositor::needsFixedRootBackgroundLayer const):
(WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp




Diff

Modified: trunk/Source/WebCore/ChangeLog (221844 => 221845)

--- trunk/Source/WebCore/ChangeLog	2017-09-11 04:49:29 UTC (rev 221844)
+++ trunk/Source/WebCore/ChangeLog	2017-09-11 05:50:21 UTC (rev 221845)
@@ -1,3 +1,22 @@
+2017-09-10  Frederic Wang  
+
+Make RenderLayerCompositor always use isRootLayer()
+https://bugs.webkit.org/show_bug.cgi?id=176591
+
+Reviewed by Darin Adler.
+
+RenderLayerCompositor contains a few comparisons of the form  == m_renderView.layer().
+This patch replaces them with "layer.isRootLayer()" which simply verifies that "layer" is
+associated to the one (and only one) RenderView of the RenderLayerCompositor. It makes things
+more readable and more consistent with the rest of the file.
+
+No new tests, behavior unchanged.
+
+* rendering/RenderLayerCompositor.cpp:
+(WebCore::RenderLayerCompositor::repaintInCompositedAncestor):
+(WebCore::RenderLayerCompositor::needsFixedRootBackgroundLayer const):
+(WebCore::RenderLayerCompositor::updateScrollCoordinatedLayer):
+
 2017-09-09  Sam Weinig  
 
 Finish off the FormData implementation


Modified: trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp (221844 => 221845)

--- trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp	2017-09-11 04:49:29 UTC (rev 221844)
+++ trunk/Source/WebCore/rendering/RenderLayerCompositor.cpp	2017-09-11 05:50:21 UTC (rev 221845)
@@ -1143,16 +1143,17 @@
 void RenderLayerCompositor::repaintInCompositedAncestor(RenderLayer& layer, const LayoutRect& rect)
 {
 RenderLayer* compositedAncestor = layer.enclosingCompositingLayerForRepaint(ExcludeSelf);
-if (compositedAncestor) {
-ASSERT(compositedAncestor->backing());
-LayoutRect repaintRect = rect;
-repaintRect.move(layer.offsetFromAncestor(compositedAncestor));
-compositedAncestor->setBackingNeedsRepaintInRect(repaintRect);
-}
+if (!compositedAncestor)
+return;
 
+ASSERT(compositedAncestor->backing());
+LayoutRect repaintRect = rect;
+repaintRect.move(layer.offsetFromAncestor(compositedAncestor));
+compositedAncestor->setBackingNeedsRepaintInRect(repaintRect);
+
 // The contents of this layer may be moving from a GraphicsLayer to the window,
 // so we need to make sure the window system synchronizes those changes on the screen.
-if (compositedAncestor == m_renderView.layer())
+if (compositedAncestor->isRootLayer())
 m_renderView.frameView().setNeedsOneShotDrawingSynchronization();
 }
 
@@ -2921,7 +2922,7 @@
 
 bool RenderLayerCompositor::needsFixedRootBackgroundLayer(const RenderLayer& layer) const
 {
-if ( != m_renderView.layer())
+if (!layer.isRootLayer())
 return false;
 
 if (m_renderView.settings().fixedBackgroundsPaintRelativeToDocument())
@@ -3892,7 +3893,7 @@
 if (!scrollingCoordinator || !scrollingCoordinator->coordinatesScrollingForFrameView(m_renderView.frameView()))
 return;
 
-bool isRootLayer =  == m_renderView.layer();
+bool isRootLayer = layer.isRootLayer();
 
 if (!layer.parent() && !isRootLayer)
 return;






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


[webkit-changes] [221193] trunk

2017-08-25 Thread fred . wang
Title: [221193] trunk








Revision 221193
Author fred.w...@free.fr
Date 2017-08-25 10:28:53 -0700 (Fri, 25 Aug 2017)


Log Message
Add flag allow-modals to iframe sandbox
https://bugs.webkit.org/show_bug.cgi?id=171321

Source/WebCore:

This patch implements the "allow-modals" value for the iframe sandbox attribute. It changes
the behavior for sandboxed document so that alert, confirm, prompt, print as well as dialogs
generated from a beforeunload event are blocked when allow-modals is not set, as defined in
the specification. For consistency, we do the same for document.execCommand('print', ...).
Users should use the allow-modals flag in order to explictly allow modal dialogs.

See https://html.spec.whatwg.org/multipage/origin.html#sandboxed-modals-flag

Patch by Frederic Wang  on 2017-07-25
Reviewed by Brent Fulgham.

Tests: http/tests/security/sandboxed-iframe-ALLOWED-modals.html
   http/tests/security/sandboxed-iframe-DENIED-modals.html

* dom/SecurityContext.cpp: Implement parsing for allow-modals
(WebCore::SecurityContext::isSupportedSandboxPolicy):
(WebCore::SecurityContext::parseSandboxPolicy):
* dom/SecurityContext.h: Introduce flag for allow-modals
* loader/FrameLoader.cpp:
(WebCore::shouldAskForNavigationConfirmation): Prevent confirm dialog from beforeunload when
allow-modals is not set.
* page/Chrome.h: Change the signature of print, so it may return a failure when the
allow-modals flag is not set.
* page/Chrome.cpp:
(WebCore::Chrome::print): Returns false and print a message error when the allow-modals flag
on the frame's document is not set. Otherwise, execute the command and returns true.
* editing/EditorCommand.cpp:
(WebCore::executePrint): Ensure that document.execCommand for 'print' returns false when the
allow-modals flag is not set.
* page/DOMWindow.cpp: Add early exit when alert, confirm or prompt when the allow-modals flag
for that document is not set. Note that print is handled in Chrome.cpp.
(WebCore::DOMWindow::alert): Add early exit.
(WebCore::DOMWindow::confirm): Add early exit with the return value indicated in the spec.
(WebCore::DOMWindow::prompt): Ditto.

LayoutTests:

Patch by Frederic Wang  on 2017-07-25
Reviewed by Brent Fulgham.

The allow-modals flag is added to tests trying to open modal dialogs in sandboxed frames, now
that the default behavior has changed. New tests are also added to verify that the dialogs
are allowed or blocked according to the value of the allow-modals flag.

* fast/events/popup-blocked-from-sandboxed-frame-via-window-open-named-sibling-frame.html: Add allow-modals.
* fast/events/popup-blocked-from-sandboxed-frame-via-window-open-named-sibling-frame2.html: Ditto.
* fast/forms/autofocus-in-sandbox-with-allow-scripts.html: Ditto.
* fast/frames/sandboxed-iframe-navigation-top-by-name-denied.html: Ditto.
* fast/frames/sandboxed-iframe-parsing-space-characters.html: Ditto.
* fast/frames/sandboxed-iframe-scripting-02.html: Ditto.
* http/tests/security/contentSecurityPolicy/resources/sandboxed-eval.php: Ditto.
* http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header-control.html: Ditto.
* http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header.html: Ditto.
* http/tests/security/contentSecurityPolicy/sandbox-allow-scripts-in-http-header2.php: Ditto.
* http/tests/security/drag-drop-same-unique-origin.html: Ditto.
* http/tests/security/no-indexeddb-from-sandbox.html: Ditto.
* http/tests/security/no-popup-from-sandbox-top.html: Ditto.
* http/tests/security/no-popup-from-sandbox.html: Ditto.
* http/tests/security/popup-allowed-by-sandbox-is-sandboxed-control.html: Ditto.
* http/tests/security/popup-allowed-by-sandbox-when-allowed.html: Ditto.
* http/tests/security/xss-DENIED-window-name-alert.html: Ditto.
* http/tests/security/sandboxed-iframe-ALLOWED-modals.html: Added. Verify that alert,
confirm, prompt and print dialogs are allowed when the allow-modals flag is set.
* http/tests/security/sandboxed-iframe-ALLOWED-modals-expected.txt: Added.
* http/tests/security/sandboxed-iframe-DENIED-modals.html: Added. Verify that alert,
confirm, prompt and print dialogs are denied when the allow-modals flag not set. The returned
values are also verified.
* http/tests/security/sandboxed-iframe-DENIED-modals-expected.txt: Added.
* http/tests/misc/iframe-beforeunload-dialog-allow-modals.html: Added. Verify that the
confirm dialog for beforeunload is displayed when allow-modals is set.
* http/tests/misc/iframe-beforeunload-dialog-allow-modals-expected.txt: Added.
* http/tests/misc/iframe-beforeunload-dialog-block-modals.html: Added. Verify that the
confirm dialog for beforeunload is not displayed when allow-modals is unset.
* http/tests/misc/iframe-beforeunload-dialog-block-modals-expected.txt: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/LayoutTests/fast/events/popup-blocked-from-sandboxed-frame-via-window-open-named-sibling-frame.html

[webkit-changes] [220261] trunk

2017-08-04 Thread fred . wang
Title: [220261] trunk








Revision 220261
Author fred.w...@free.fr
Date 2017-08-04 01:08:17 -0700 (Fri, 04 Aug 2017)


Log Message
ScrollingTreeOverflowScrollingNodeIOS uses the wrong fixed position rectangle
https://bugs.webkit.org/show_bug.cgi?id=175135

Patch by Frederic Wang  on 2017-08-04
Reviewed by Simon Fraser.

Source/WebCore:

This patch modifies ScrollingTreeOverflowScrollingNodeIOS::updateChildNodesAfterScroll so
that it uses the fixed position rectangle relative of the first frame ancestor instead of
the one of the main frame. This makes it consistent with ScrollingTreeFrameScrollingNodeIOS
and RenderLayerCompositor. This fixes some flickering issues on iOS.

Test: fast/scrolling/ios/fixed-inside-overflow-inside-iframe.html

* page/scrolling/ScrollingTreeFrameScrollingNode.h:
(WebCore::ScrollingTreeFrameScrollingNode::fixedPositionRect): Helper function to get the
fixed position rect to use for that frame.
* page/scrolling/ScrollingTreeNode.cpp:
(WebCore::ScrollingTreeNode::enclosingFrameNode const): Helper function to get the enclosing
frame for this scrolling node or null if there is none.
* page/scrolling/ScrollingTreeNode.h: Declare enclosingFrameNode.

Source/WebKit:

This patch modifies ScrollingTreeOverflowScrollingNodeIOS::updateChildNodesAfterScroll so
that it uses the fixed position rectangle relative of the first frame ancestor instead of
the one of the main frame. This makes it consistent with ScrollingTreeFrameScrollingNodeIOS
and RenderLayerCompositor. This fixes some flickering issues on iOS.

* UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm:
(WebKit::ScrollingTreeOverflowScrollingNodeIOS::updateChildNodesAfterScroll): Use the fixed
position rect of a non-main frame if there is one.

LayoutTests:

This patch adds a new test for a position:fixed element inside an overflow node inside an
iframe. When scrolling the overflow node, the position of such an element should remain fixed
relative to the inner frame. Before that change, ScrollingTreeOverflowScrollingNodeIOS used
to take the main frame as a reference instead, causing the element to flicker and even to
disappear when the user scrolls that overflow node. We add a reftest to verify that the
element is visible and positioned at the correct location when the user scrolls.

* fast/scrolling/ios/fixed-inside-overflow-inside-iframe-expected.html: Added.
* fast/scrolling/ios/fixed-inside-overflow-inside-iframe.html: Added.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/page/scrolling/ScrollingTreeFrameScrollingNode.h
trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.cpp
trunk/Source/WebCore/page/scrolling/ScrollingTreeNode.h
trunk/Source/WebKit/ChangeLog
trunk/Source/WebKit/UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm


Added Paths

trunk/LayoutTests/fast/scrolling/ios/fixed-inside-overflow-inside-iframe-expected.html
trunk/LayoutTests/fast/scrolling/ios/fixed-inside-overflow-inside-iframe.html




Diff

Modified: trunk/LayoutTests/ChangeLog (220260 => 220261)

--- trunk/LayoutTests/ChangeLog	2017-08-04 07:56:17 UTC (rev 220260)
+++ trunk/LayoutTests/ChangeLog	2017-08-04 08:08:17 UTC (rev 220261)
@@ -1,3 +1,20 @@
+2017-08-04  Frederic Wang  
+
+ScrollingTreeOverflowScrollingNodeIOS uses the wrong fixed position rectangle
+https://bugs.webkit.org/show_bug.cgi?id=175135
+
+Reviewed by Simon Fraser.
+
+This patch adds a new test for a position:fixed element inside an overflow node inside an
+iframe. When scrolling the overflow node, the position of such an element should remain fixed
+relative to the inner frame. Before that change, ScrollingTreeOverflowScrollingNodeIOS used
+to take the main frame as a reference instead, causing the element to flicker and even to
+disappear when the user scrolls that overflow node. We add a reftest to verify that the
+element is visible and positioned at the correct location when the user scrolls.
+
+* fast/scrolling/ios/fixed-inside-overflow-inside-iframe-expected.html: Added.
+* fast/scrolling/ios/fixed-inside-overflow-inside-iframe.html: Added.
+
 2017-08-04  Zan Dobersek  
 
 Unreviewed WPE gardening. Update test expectations and layout test baselines


Added: trunk/LayoutTests/fast/scrolling/ios/fixed-inside-overflow-inside-iframe-expected.html (0 => 220261)

--- trunk/LayoutTests/fast/scrolling/ios/fixed-inside-overflow-inside-iframe-expected.html	(rev 0)
+++ trunk/LayoutTests/fast/scrolling/ios/fixed-inside-overflow-inside-iframe-expected.html	2017-08-04 08:08:17 UTC (rev 220261)
@@ -0,0 +1,59 @@
+
+
+position:fixed element inside overflow node inside iframe
+
+   iframe {
+   position: absolute;
+   border: none;
+   left: 40px;
+   top: 50px;
+   width: 300px;
+   

[webkit-changes] [220001] trunk/Source

2017-07-28 Thread fred . wang
Title: [220001] trunk/Source








Revision 220001
Author fred.w...@free.fr
Date 2017-07-28 08:38:04 -0700 (Fri, 28 Jul 2017)


Log Message
Fix typo in scrollPositionChangedViaDelegatedScrolling
https://bugs.webkit.org/show_bug.cgi?id=174937

Patch by Frederic Wang  on 2017-07-28
Reviewed by Wenson Hsieh.

Source/WebCore:

No new tests, fix typo in the inUserInteraction parameter.

* page/scrolling/ScrollingTree.cpp:
(WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling):
* page/scrolling/ScrollingTree.h:

Source/WebKit:

* UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.h:
* UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm:
(WebKit::ScrollingTreeOverflowScrollingNodeIOS::scrollViewDidScroll):

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp
trunk/Source/WebCore/page/scrolling/ScrollingTree.h
trunk/Source/WebKit/ChangeLog
trunk/Source/WebKit/UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.h
trunk/Source/WebKit/UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm




Diff

Modified: trunk/Source/WebCore/ChangeLog (22 => 220001)

--- trunk/Source/WebCore/ChangeLog	2017-07-28 10:27:03 UTC (rev 22)
+++ trunk/Source/WebCore/ChangeLog	2017-07-28 15:38:04 UTC (rev 220001)
@@ -1,3 +1,16 @@
+2017-07-28  Frederic Wang  
+
+Fix typo in scrollPositionChangedViaDelegatedScrolling
+https://bugs.webkit.org/show_bug.cgi?id=174937
+
+Reviewed by Wenson Hsieh.
+
+No new tests, fix typo in the inUserInteraction parameter.
+
+* page/scrolling/ScrollingTree.cpp:
+(WebCore::ScrollingTree::scrollPositionChangedViaDelegatedScrolling):
+* page/scrolling/ScrollingTree.h:
+
 2017-07-28  Wenson Hsieh  
 
 [iOS DnD] [WK1] Snapshots generated using -[DOMRange renderImageForcingBlackText:] are upside down


Modified: trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp (22 => 220001)

--- trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp	2017-07-28 10:27:03 UTC (rev 22)
+++ trunk/Source/WebCore/page/scrolling/ScrollingTree.cpp	2017-07-28 15:38:04 UTC (rev 220001)
@@ -102,7 +102,7 @@
 downcast(*node).updateLayersAfterViewportChange(fixedPositionRect, scale);
 }
 
-void ScrollingTree::scrollPositionChangedViaDelegatedScrolling(ScrollingNodeID nodeID, const WebCore::FloatPoint& scrollPosition, bool inUserInteration)
+void ScrollingTree::scrollPositionChangedViaDelegatedScrolling(ScrollingNodeID nodeID, const WebCore::FloatPoint& scrollPosition, bool inUserInteraction)
 {
 ScrollingTreeNode* node = nodeForID(nodeID);
 if (!is(node))
@@ -112,7 +112,7 @@
 downcast(*node).updateLayersAfterDelegatedScroll(scrollPosition);
 
 // Update GraphicsLayers and scroll state.
-scrollingTreeNodeDidScroll(nodeID, scrollPosition, std::nullopt, inUserInteration ? ScrollingLayerPositionAction::Sync : ScrollingLayerPositionAction::Set);
+scrollingTreeNodeDidScroll(nodeID, scrollPosition, std::nullopt, inUserInteraction ? ScrollingLayerPositionAction::Sync : ScrollingLayerPositionAction::Set);
 }
 
 void ScrollingTree::commitTreeState(std::unique_ptr scrollingStateTree)


Modified: trunk/Source/WebCore/page/scrolling/ScrollingTree.h (22 => 220001)

--- trunk/Source/WebCore/page/scrolling/ScrollingTree.h	2017-07-28 10:27:03 UTC (rev 22)
+++ trunk/Source/WebCore/page/scrolling/ScrollingTree.h	2017-07-28 15:38:04 UTC (rev 220001)
@@ -89,7 +89,7 @@
 
 // Delegated scrolling has scrolled a node. Update layer positions on descendant tree nodes,
 // and call scrollingTreeNodeDidScroll().
-WEBCORE_EXPORT virtual void scrollPositionChangedViaDelegatedScrolling(ScrollingNodeID, const WebCore::FloatPoint& scrollPosition, bool inUserInteration);
+WEBCORE_EXPORT virtual void scrollPositionChangedViaDelegatedScrolling(ScrollingNodeID, const WebCore::FloatPoint& scrollPosition, bool inUserInteraction);
 
 WEBCORE_EXPORT virtual void currentSnapPointIndicesDidChange(ScrollingNodeID, unsigned horizontal, unsigned vertical) = 0;
 


Modified: trunk/Source/WebKit/ChangeLog (22 => 220001)

--- trunk/Source/WebKit/ChangeLog	2017-07-28 10:27:03 UTC (rev 22)
+++ trunk/Source/WebKit/ChangeLog	2017-07-28 15:38:04 UTC (rev 220001)
@@ -1,3 +1,14 @@
+2017-07-28  Frederic Wang  
+
+Fix typo in scrollPositionChangedViaDelegatedScrolling
+https://bugs.webkit.org/show_bug.cgi?id=174937
+
+Reviewed by Wenson Hsieh.
+
+* UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.h:
+* UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm:
+(WebKit::ScrollingTreeOverflowScrollingNodeIOS::scrollViewDidScroll):
+
 2017-07-28  Jeremy Jones  
 
 Remove Web prefix from WebVideoFullscreen and WebPlaybackSession classes.


Modified: 

[webkit-changes] [219944] trunk/Websites/webkit.org

2017-07-26 Thread fred . wang
Title: [219944] trunk/Websites/webkit.org








Revision 219944
Author fred.w...@free.fr
Date 2017-07-26 07:23:21 -0700 (Wed, 26 Jul 2017)


Log Message
Unreviewed, minor adjustments to the previous demo.

Patch by Frederic Wang  on 2017-07-26

* demos/frames/index.html: Added. Index page for the list of demos.
* demos/frames/sandboxing/index.html: Minor fixes.

Modified Paths

trunk/Websites/webkit.org/ChangeLog
trunk/Websites/webkit.org/demos/frames/sandboxing/index.html


Added Paths

trunk/Websites/webkit.org/demos/frames/index.html




Diff

Modified: trunk/Websites/webkit.org/ChangeLog (219943 => 219944)

--- trunk/Websites/webkit.org/ChangeLog	2017-07-26 13:52:35 UTC (rev 219943)
+++ trunk/Websites/webkit.org/ChangeLog	2017-07-26 14:23:21 UTC (rev 219944)
@@ -1,5 +1,12 @@
 2017-07-26  Frederic Wang  
 
+Unreviewed, minor adjustments to the previous demo.
+
+* demos/frames/index.html: Added. Index page for the list of demos.
+* demos/frames/sandboxing/index.html: Minor fixes.
+
+2017-07-26  Frederic Wang  
+
 Unreviewed, add demos (frame sandboxing and scrolling) for a blog post.
 
 * demos/frames/sandboxing/am-i-sandboxed.html: Added.


Added: trunk/Websites/webkit.org/demos/frames/index.html (0 => 219944)

--- trunk/Websites/webkit.org/demos/frames/index.html	(rev 0)
+++ trunk/Websites/webkit.org/demos/frames/index.html	2017-07-26 14:23:21 UTC (rev 219944)
@@ -0,0 +1,18 @@
+
+
+  
+Demos for frame sandboxing and scrolling
+
+  
+  
+
+Demos for frame sandboxing and scrolling
+
+
+  
+  
+
+
+  
+
Property changes on: trunk/Websites/webkit.org/demos/frames/index.html
___


Added: svn:eol-style
+LF
\ No newline at end of property

Added: svn:mime-type
+text/html
\ No newline at end of property

Modified: trunk/Websites/webkit.org/demos/frames/sandboxing/index.html (219943 => 219944)

--- trunk/Websites/webkit.org/demos/frames/sandboxing/index.html	2017-07-26 13:52:35 UTC (rev 219943)
+++ trunk/Websites/webkit.org/demos/frames/sandboxing/index.html	2017-07-26 14:23:21 UTC (rev 219944)
@@ -8,8 +8,10 @@
 
 Frame Sandboxing
 
-Note: In order to run these demos, you might need to modify your
-  preference to allow _javascript_s, popups or modal dialogs.
+This page contains some demos for the
+  .
+  In order to run these demos, you might need to modify your
+  preference to allow _javascript_, popups and modal dialogs.
 
 Basic flags
 
@@ -29,13 +31,12 @@
 
 allow-popup-to-escape-sandbox
 
-By default, popups opened from a sandboxed frames has the
+By default, popups opened from a sandboxed frames have the
   same restrictions as the frame.
   This is sometimes not wanted e.g. for the landing page of trusted ads.
   The allow-popup-to-escape-sandbox flag allows the popups
   to be opened in a new unsandboxed context. Click the
-  "Open this page as a popup" links to check the difference to see the
-  effect of that flag:
+  "Open this page as a popup" links to see the effect of that flag:
 
 
   allow-popups: 





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


[webkit-changes] [219942] trunk/Websites/webkit.org

2017-07-26 Thread fred . wang
Title: [219942] trunk/Websites/webkit.org








Revision 219942
Author fred.w...@free.fr
Date 2017-07-26 06:43:25 -0700 (Wed, 26 Jul 2017)


Log Message
Unreviewed, add demos (frame sandboxing and scrolling) for a blog post.

Patch by Frederic Wang  on 2017-07-26

* demos/frames/sandboxing/am-i-sandboxed.html: Added.
* demos/frames/sandboxing/framebusting-success.html: Added.
* demos/frames/sandboxing/framebusting-without-user-activation.html: Added.
* demos/frames/sandboxing/index.html: Added.
* demos/frames/scrollable-iframes.html: Added.
* demos/frames/scrollingElement.html: Added.

Modified Paths

trunk/Websites/webkit.org/ChangeLog


Added Paths

trunk/Websites/webkit.org/demos/frames/
trunk/Websites/webkit.org/demos/frames/sandboxing/
trunk/Websites/webkit.org/demos/frames/sandboxing/am-i-sandboxed.html
trunk/Websites/webkit.org/demos/frames/sandboxing/framebusting-success.html
trunk/Websites/webkit.org/demos/frames/sandboxing/framebusting-without-user-activation.html
trunk/Websites/webkit.org/demos/frames/sandboxing/index.html
trunk/Websites/webkit.org/demos/frames/scrollable-iframes.html
trunk/Websites/webkit.org/demos/frames/scrollingElement.html




Diff

Modified: trunk/Websites/webkit.org/ChangeLog (219941 => 219942)

--- trunk/Websites/webkit.org/ChangeLog	2017-07-26 13:41:37 UTC (rev 219941)
+++ trunk/Websites/webkit.org/ChangeLog	2017-07-26 13:43:25 UTC (rev 219942)
@@ -1,3 +1,14 @@
+2017-07-26  Frederic Wang  
+
+Unreviewed, add demos (frame sandboxing and scrolling) for a blog post.
+
+* demos/frames/sandboxing/am-i-sandboxed.html: Added.
+* demos/frames/sandboxing/framebusting-success.html: Added.
+* demos/frames/sandboxing/framebusting-without-user-activation.html: Added.
+* demos/frames/sandboxing/index.html: Added.
+* demos/frames/scrollable-iframes.html: Added.
+* demos/frames/scrollingElement.html: Added.
+
 2017-07-20  Jiewen Tan  
 
 Unreviewed, add the final demo page for a WebCrypto API blog post


Added: trunk/Websites/webkit.org/demos/frames/sandboxing/am-i-sandboxed.html (0 => 219942)

--- trunk/Websites/webkit.org/demos/frames/sandboxing/am-i-sandboxed.html	(rev 0)
+++ trunk/Websites/webkit.org/demos/frames/sandboxing/am-i-sandboxed.html	2017-07-26 13:43:25 UTC (rev 219942)
@@ -0,0 +1,25 @@
+
+
+  
+Am I sandboxed?
+
+  
+  
+
+I'm NOT allowed to execute _javascript_.
+
+
+  document.querySelector('p').textContent = "I can execute _javascript_.";
+  document.body.style.backgroundColor = "lightgreen";
+
+
+Open this page as a popup
+
+Open an alert dialog
+
+Navigate top frame
+
+Open a popup to test top navigation without user activation
+
+  
+
Property changes on: trunk/Websites/webkit.org/demos/frames/sandboxing/am-i-sandboxed.html
___


Added: svn:eol-style
+LF
\ No newline at end of property

Added: svn:mime-type
+text/html
\ No newline at end of property

Added: trunk/Websites/webkit.org/demos/frames/sandboxing/framebusting-success.html (0 => 219942)

--- trunk/Websites/webkit.org/demos/frames/sandboxing/framebusting-success.html	(rev 0)
+++ trunk/Websites/webkit.org/demos/frames/sandboxing/framebusting-success.html	2017-07-26 13:43:25 UTC (rev 219942)
@@ -0,0 +1,19 @@
+
+
+  
+Framebusting Success
+
+  
+
+  
+
+Framebusting succeeded!
+
+You will be redirected to .
+
+
+setTimeout(function() { location = 'index.html'; }, 3000);
+
+
+  
+
Property changes on: trunk/Websites/webkit.org/demos/frames/sandboxing/framebusting-success.html
___


Added: svn:eol-style
+LF
\ No newline at end of property

Added: svn:mime-type
+text/html
\ No newline at end of property

Added: trunk/Websites/webkit.org/demos/frames/sandboxing/framebusting-without-user-activation.html (0 => 219942)

--- trunk/Websites/webkit.org/demos/frames/sandboxing/framebusting-without-user-activation.html	(rev 0)
+++ trunk/Websites/webkit.org/demos/frames/sandboxing/framebusting-without-user-activation.html	2017-07-26 13:43:25 UTC (rev 219942)
@@ -0,0 +1,11 @@
+
+
+  
+Framebusting without user activation
+
+  
+  
+If you see this message, then framebusting without user activation failed!
+
+  
+
Property changes on: trunk/Websites/webkit.org/demos/frames/sandboxing/framebusting-without-user-activation.html
___


Added: svn:eol-style
+LF
\ No newline at end of property

Added: svn:mime-type
+text/html
\ No newline at end of property

Added: trunk/Websites/webkit.org/demos/frames/sandboxing/index.html (0 => 219942)

--- trunk/Websites/webkit.org/demos/frames/sandboxing/index.html	(rev 0)
+++ 

[webkit-changes] [219797] trunk

2017-07-24 Thread fred . wang
Title: [219797] trunk








Revision 219797
Author fred.w...@free.fr
Date 2017-07-24 01:33:11 -0700 (Mon, 24 Jul 2017)


Log Message
Add attribute allow-top-navigation-by-user-activation to iframe sandbox
https://bugs.webkit.org/show_bug.cgi?id=171327

Patch by Frederic Wang  on 2017-07-11
Reviewed by Chris Dumez.

LayoutTests/imported/w3c:

This commit updates the expectation for the test verifying that a sandboxed iframe without
the allow-top-navigation-by-user-activation flag set can not perform top navigation if it is
not triggered by a user gesture. The navigation is still prohibited but the parsing of the
allow-top-navigation-by-user-activation flag should not raised any error message.
A similar update is done for the test verifying that the combination of the flags
allow-top-navigation-by-user-activation and allow-top-navigation.

* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation_by_user_activation_without_user_gesture-expected.txt: Remove the error message.
* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3-expected.txt: Ditto.

Source/WebCore:

Tests: http/tests/security/frameNavigation/sandbox-ALLOWED-top-navigation-with-user-gesture-1.html
   http/tests/security/frameNavigation/sandbox-ALLOWED-top-navigation-with-user-gesture-2.html
   imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation_by_user_activation_without_user_gesture-expected.txt
   imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3-expected.txt

* dom/Document.cpp:
(WebCore::Document::canNavigate): Case 2 of conformance verification is refined to match the
current specification: Top navigation is allowed when it is triggered by user activation and
when allow-top-navigation-by-user-activation is set. Because we have additional "security
origin" rules with respect to the specification we also add some early return to ensure that
navigation is really allowed for this new case.
* dom/SecurityContext.cpp:
(WebCore::SecurityContext::isSupportedSandboxPolicy): Add allow-top-navigation-by-user-activation flag.
(WebCore::SecurityContext::parseSandboxPolicy): Parse the new flag to allow top user
navigation by user activation. Also, make sure that allow-top-navigation allows such
navigation as defined by the specification.
* dom/SecurityContext.h: Declare new sandboxing flag.

LayoutTests:

This patch adds tests to verify that a sandboxed iframe with the flag
'allow-top-navigation-by-user-activation' or 'allow-top-navigation' can navigate the top
level page, if navigation is triggered by a user gesture. This is based on a test from the
Chromium repository.
It also verifies that navigation fails when 'allow-top-navigation-by-user-activation' is
absent, even when it is triggered by a user gesture.

* http/tests/security/frameNavigation/resources/iframe-that-performs-parent-navigation-with-user-activation.html: Added. This is similar to iframe-that-performs-parent-navigation.html but it
performs navigation of its parent using user activation.
* http/tests/security/frameNavigation/sandbox-ALLOWED-top-navigation-with-user-gesture-1.html: Added.
Test top navigation for a sandboxed frame with 'allow-top-navigation-by-user-activation'
* http/tests/security/frameNavigation/sandbox-ALLOWED-top-navigation-with-user-gesture-1-expected.txt: Added.
Add PASS expectation.
* http/tests/security/frameNavigation/sandbox-ALLOWED-top-navigation-with-user-gesture-2.html: Added.
Test top navigation for a sandboxed frame with 'allow-top-navigation'.
* http/tests/security/frameNavigation/sandbox-ALLOWED-top-navigation-with-user-gesture-2-expected.txt: Added.
Add PASS expectation.
* http/tests/security/frameNavigation/sandbox-DENIED-top-navigation-with-user-gesture.html: Added.
Test user-triggered navigation for a sandboxed frame without 'allow-top-navigation-by-user-activation'.
* http/tests/security/frameNavigation/sandbox-DENIED-top-navigation-with-user-gesture-expected.txt: Added.
Add reference with navigation failure.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/LayoutTests/imported/w3c/ChangeLog
trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation_by_user_activation_without_user_gesture-expected.txt
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/dom/Document.cpp
trunk/Source/WebCore/dom/SecurityContext.cpp
trunk/Source/WebCore/dom/SecurityContext.h


Added Paths

trunk/LayoutTests/http/tests/security/frameNavigation/resources/iframe-that-performs-parent-navigation-with-user-activation.html

[webkit-changes] [219395] trunk/LayoutTests/imported/w3c

2017-07-12 Thread fred . wang
Title: [219395] trunk/LayoutTests/imported/w3c








Revision 219395
Author fred.w...@free.fr
Date 2017-07-12 08:47:33 -0700 (Wed, 12 Jul 2017)


Log Message
Import test verifying combination of allow-top-navigation and allow-top-navigation-by-user-activation
https://bugs.webkit.org/show_bug.cgi?id=174351

Patch by Frederic Wang  on 2017-07-12
Reviewed by Youenn Fablet.

This imports a test to verify that the combination of the allow-top-navigation and
allow-top-navigation-by-user-activation flags is just treated as allow-top-navigation.
For now the expectation contains a parsing error message which will be removed when bug
171327 is fixed.

* web-platform-tests/html/semantics/embedded-content/the-iframe-element/w3c-import.log:
Add the new test.
* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3.html: Added.
This is imported from the W3C repository.
* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3-expected.txt: Added.
The test passes, even if for now the 'allow-top-navigation-by-user-activation' triggers a
parsing error message in the console.

Modified Paths

trunk/LayoutTests/imported/w3c/ChangeLog
trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/w3c-import.log


Added Paths

trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3.html




Diff

Modified: trunk/LayoutTests/imported/w3c/ChangeLog (219394 => 219395)

--- trunk/LayoutTests/imported/w3c/ChangeLog	2017-07-12 15:37:52 UTC (rev 219394)
+++ trunk/LayoutTests/imported/w3c/ChangeLog	2017-07-12 15:47:33 UTC (rev 219395)
@@ -1,3 +1,23 @@
+2017-07-12  Frederic Wang  
+
+Import test verifying combination of allow-top-navigation and allow-top-navigation-by-user-activation
+https://bugs.webkit.org/show_bug.cgi?id=174351
+
+Reviewed by Youenn Fablet.
+
+This imports a test to verify that the combination of the allow-top-navigation and
+allow-top-navigation-by-user-activation flags is just treated as allow-top-navigation.
+For now the expectation contains a parsing error message which will be removed when bug
+171327 is fixed.
+
+* web-platform-tests/html/semantics/embedded-content/the-iframe-element/w3c-import.log:
+Add the new test.
+* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3.html: Added.
+This is imported from the W3C repository.
+* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3-expected.txt: Added.
+The test passes, even if for now the 'allow-top-navigation-by-user-activation' triggers a
+parsing error message in the console.
+
 2017-07-10  Javier Fernandez  
 
 [css-align][css-flex][css-grid] 'auto' values of align-self and justify-self must not be resolved


Added: trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3-expected.txt (0 => 219395)

--- trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3-expected.txt	(rev 0)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3-expected.txt	2017-07-12 15:47:33 UTC (rev 219395)
@@ -0,0 +1,6 @@
+CONSOLE MESSAGE: line 15: Error while parsing the 'sandbox' attribute: 'allow-top-navigation-by-user-activation' is an invalid sandbox flag.
+CONSOLE MESSAGE: line 15: Error while parsing the 'sandbox' attribute: 'allow-top-navigation-by-user-activation' is an invalid sandbox flag.
+
+
+PASS Frames with `allow-top-navigation` should be able to navigate the top frame even when `allow-top-navigation-by-user-activation` is set. 
+
Property changes on: trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3-expected.txt
___


Added: svn:eol-style
+LF
\ No newline at end of property

Added: trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3.html (0 => 219395)

--- trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-3.html	(rev 0)
+++ 

[webkit-changes] [219137] trunk/Source

2017-07-05 Thread fred . wang
Title: [219137] trunk/Source








Revision 219137
Author fred.w...@free.fr
Date 2017-07-05 10:56:11 -0700 (Wed, 05 Jul 2017)


Log Message
Move ScrolledContentsLayer property to ScrollingStateScrollingNode
https://bugs.webkit.org/show_bug.cgi?id=174134

Patch by Frederic Wang  on 2017-07-05
Reviewed by Simon Fraser.

Source/WebCore:

ScrollingStateFrameScrollingNode and ScrollingStateOverflowScrollingNode both use a
ScrolledContentsLayer property for the same purpose. This commit moves that property into
their parent class ScrollingStateScrollingNode, so that more code is shared between the two
classes. This will also help the refactoring in bug 174130.

No new tests, only dumped tree may change a bit.

* page/scrolling/ScrollingStateFrameScrollingNode.cpp: Remove scrolled contents layer.
(WebCore::ScrollingStateFrameScrollingNode::ScrollingStateFrameScrollingNode):
(WebCore::ScrollingStateFrameScrollingNode::dumpProperties):
(WebCore::ScrollingStateFrameScrollingNode::setScrolledContentsLayer): Deleted.
* page/scrolling/ScrollingStateFrameScrollingNode.h: Ditto.
* page/scrolling/ScrollingStateOverflowScrollingNode.cpp: Ditto.
(WebCore::ScrollingStateOverflowScrollingNode::ScrollingStateOverflowScrollingNode):
(WebCore::ScrollingStateOverflowScrollingNode::dumpProperties):
(WebCore::ScrollingStateOverflowScrollingNode::setScrolledContentsLayer): Deleted.
* page/scrolling/ScrollingStateOverflowScrollingNode.h: Ditto.
(): Deleted.
(WebCore::ScrollingStateOverflowScrollingNode::scrolledContentsLayer): Deleted.
* page/scrolling/ScrollingStateScrollingNode.cpp: Add scrolled contents layer.
(WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
(WebCore::ScrollingStateScrollingNode::setScrolledContentsLayer):
(WebCore::ScrollingStateScrollingNode::dumpProperties): Use the label from the overflow class
which is different from the frame class. The dumping order may change a bit too.
* page/scrolling/ScrollingStateScrollingNode.h: Add ScrolledContentsLayer to the enum and
scrolled contents layer.
(WebCore::ScrollingStateScrollingNode::scrolledContentsLayer):
* page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
(WebCore::ScrollingTreeFrameScrollingNodeMac::commitStateBeforeChildren): Adjust enum value
to use ScrollingStateScrollingNode::ScrolledContentsLayer.

Source/WebKit2:

* Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp:
(ArgumentCoder::encode): Add encoding for scrolled contents
layer.
(ArgumentCoder::encode): Remove encoding for scrolled
contents layer.
(ArgumentCoder::encode): Ditto.
(ArgumentCoder::decode): Add decoding for scrolled contents
layer.
(ArgumentCoder::decode): Remove decoding for scrolled
contents layer.
(ArgumentCoder::decode): Ditto.
(WebKit::dump): Move dumping of scrolled contents layer from overflow/frame nodes to
scrolling node.
* UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.cpp:
(WebKit::RemoteScrollingCoordinatorProxy::connectStateNodeLayers): Adjust enum value to use
ScrollingStateScrollingNode::ScrolledContentsLayer.
* UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm:
(WebKit::ScrollingTreeOverflowScrollingNodeIOS::commitStateBeforeChildren): Ditto.
* UIProcess/ios/RemoteScrollingCoordinatorProxyIOS.mm:
(WebKit::RemoteScrollingCoordinatorProxy::connectStateNodeLayers): Ditto.

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/page/scrolling/ScrollingStateFrameScrollingNode.cpp
trunk/Source/WebCore/page/scrolling/ScrollingStateFrameScrollingNode.h
trunk/Source/WebCore/page/scrolling/ScrollingStateOverflowScrollingNode.cpp
trunk/Source/WebCore/page/scrolling/ScrollingStateOverflowScrollingNode.h
trunk/Source/WebCore/page/scrolling/ScrollingStateScrollingNode.cpp
trunk/Source/WebCore/page/scrolling/ScrollingStateScrollingNode.h
trunk/Source/WebCore/page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm
trunk/Source/WebKit2/ChangeLog
trunk/Source/WebKit2/Shared/Scrolling/RemoteScrollingCoordinatorTransaction.cpp
trunk/Source/WebKit2/UIProcess/Scrolling/RemoteScrollingCoordinatorProxy.cpp
trunk/Source/WebKit2/UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm
trunk/Source/WebKit2/UIProcess/ios/RemoteScrollingCoordinatorProxyIOS.mm




Diff

Modified: trunk/Source/WebCore/ChangeLog (219136 => 219137)

--- trunk/Source/WebCore/ChangeLog	2017-07-05 17:43:59 UTC (rev 219136)
+++ trunk/Source/WebCore/ChangeLog	2017-07-05 17:56:11 UTC (rev 219137)
@@ -1,3 +1,41 @@
+2017-07-05  Frederic Wang  
+
+Move ScrolledContentsLayer property to ScrollingStateScrollingNode
+https://bugs.webkit.org/show_bug.cgi?id=174134
+
+Reviewed by Simon Fraser.
+
+ScrollingStateFrameScrollingNode and ScrollingStateOverflowScrollingNode both use a
+ScrolledContentsLayer property for the same purpose. This commit moves that property into
+their parent class ScrollingStateScrollingNode, so that more code is shared between the two
+classes. 

[webkit-changes] [218928] trunk/Source/WebCore

2017-06-29 Thread fred . wang
Title: [218928] trunk/Source/WebCore








Revision 218928
Author fred.w...@free.fr
Date 2017-06-29 09:25:55 -0700 (Thu, 29 Jun 2017)


Log Message
Small improvement of calls to RenderLayerBacking members
https://bugs.webkit.org/show_bug.cgi?id=173969

Patch by Frederic Wang  on 2017-06-29
Reviewed by Simon Fraser.

No new tests, behavior unchanged.

* page/FrameView.cpp:
(WebCore::FrameView::tiledBacking): Access the member with RenderLayerBacking::tiledBacking.
(WebCore::FrameView::updateTilesForExtendedBackgroundMode): Ditto.
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::usesCompositedScrolling): Use RenderLayerBacking::hasScrollingLayer as
it better matches the intention of the check here.

Modified Paths

trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/page/FrameView.cpp
trunk/Source/WebCore/rendering/RenderLayer.cpp




Diff

Modified: trunk/Source/WebCore/ChangeLog (218927 => 218928)

--- trunk/Source/WebCore/ChangeLog	2017-06-29 16:24:59 UTC (rev 218927)
+++ trunk/Source/WebCore/ChangeLog	2017-06-29 16:25:55 UTC (rev 218928)
@@ -1,3 +1,19 @@
+2017-06-29  Frederic Wang  
+
+Small improvement of calls to RenderLayerBacking members
+https://bugs.webkit.org/show_bug.cgi?id=173969
+
+Reviewed by Simon Fraser.
+
+No new tests, behavior unchanged.
+
+* page/FrameView.cpp:
+(WebCore::FrameView::tiledBacking): Access the member with RenderLayerBacking::tiledBacking.
+(WebCore::FrameView::updateTilesForExtendedBackgroundMode): Ditto.
+* rendering/RenderLayer.cpp:
+(WebCore::RenderLayer::usesCompositedScrolling): Use RenderLayerBacking::hasScrollingLayer as
+it better matches the intention of the check here.
+
 2017-06-29  Romain Bellessort  
 
 [Readable Streams API] Fix ReadableStream "strategy" argument handling


Modified: trunk/Source/WebCore/page/FrameView.cpp (218927 => 218928)

--- trunk/Source/WebCore/page/FrameView.cpp	2017-06-29 16:24:59 UTC (rev 218927)
+++ trunk/Source/WebCore/page/FrameView.cpp	2017-06-29 16:25:55 UTC (rev 218928)
@@ -945,7 +945,7 @@
 if (!backing)
 return nullptr;
 
-return backing->graphicsLayer()->tiledBacking();
+return backing->tiledBacking();
 }
 
 uint64_t FrameView::scrollLayerID() const
@@ -3335,7 +3335,7 @@
 if (!backing)
 return;
 
-TiledBacking* tiledBacking = backing->graphicsLayer()->tiledBacking();
+TiledBacking* tiledBacking = backing->tiledBacking();
 if (!tiledBacking)
 return;
 


Modified: trunk/Source/WebCore/rendering/RenderLayer.cpp (218927 => 218928)

--- trunk/Source/WebCore/rendering/RenderLayer.cpp	2017-06-29 16:24:59 UTC (rev 218927)
+++ trunk/Source/WebCore/rendering/RenderLayer.cpp	2017-06-29 16:25:55 UTC (rev 218928)
@@ -2219,7 +2219,7 @@
 
 bool RenderLayer::usesCompositedScrolling() const
 {
-return isComposited() && backing()->scrollingLayer();
+return isComposited() && backing()->hasScrollingLayer();
 }
 
 bool RenderLayer::usesAsyncScrolling() const






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


[webkit-changes] [218921] trunk

2017-06-29 Thread fred . wang
Title: [218921] trunk








Revision 218921
Author fred.w...@free.fr
Date 2017-06-29 00:43:07 -0700 (Thu, 29 Jun 2017)


Log Message
Align Document::canNavigate on the HTM5 specification
https://bugs.webkit.org/show_bug.cgi?id=173162

Patch by Frederic Wang  on 2017-06-28
Reviewed by Chris Dumez.

LayoutTests/imported/w3c:

Test expectation for popup navigation are updated now that the following tests pass:
- iframe_sandbox_popups_escaping-3
- iframe_sandbox_popups_nonescaping-3

* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_escaping-3-expected.txt: Update expectation to PASS.
* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3-expected.txt: Update expectation to PASS.

Source/WebCore:

Currently when a frame A with a sandboxed navigation flag tries and navigates another frame B
then Document::canNavigate verifies the cases where we try to navigate A's top frame (in
that case the allow-top-navigation flag is needed) or not (in that case, B must be a
descendant of A). This patch refines that a bit to check the case where B is a popup (in that
case navigation is permitted if A is the opener of B). This change aligns on the HTML5
specification and allows to pass more W3C Web Platform tests.
See https://html.spec.whatwg.org/multipage/browsers.html#allowed-to-navigate

Tests: imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_escaping-3.html
   imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3.html

* dom/Document.cpp:
(WebCore::Document::canNavigate): This refines the case where the document's frame has the
sandbox navigation flag set in order to handle popup navigation. New comments referring to
the HTML5 specification are also added.

Modified Paths

trunk/LayoutTests/imported/w3c/ChangeLog
trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_escaping-3-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3-expected.txt
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/dom/Document.cpp




Diff

Modified: trunk/LayoutTests/imported/w3c/ChangeLog (218920 => 218921)

--- trunk/LayoutTests/imported/w3c/ChangeLog	2017-06-29 06:07:41 UTC (rev 218920)
+++ trunk/LayoutTests/imported/w3c/ChangeLog	2017-06-29 07:43:07 UTC (rev 218921)
@@ -1,3 +1,17 @@
+2017-06-28  Frederic Wang  
+
+Align Document::canNavigate on the HTM5 specification
+https://bugs.webkit.org/show_bug.cgi?id=173162
+
+Reviewed by Chris Dumez.
+
+Test expectation for popup navigation are updated now that the following tests pass:
+- iframe_sandbox_popups_escaping-3
+- iframe_sandbox_popups_nonescaping-3
+
+* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_escaping-3-expected.txt: Update expectation to PASS.
+* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3-expected.txt: Update expectation to PASS.
+
 2017-06-27  Saam Barati  
 
 Function constructor needs to follow the spec and validate parameters and body independently


Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_escaping-3-expected.txt (218920 => 218921)

--- trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_escaping-3-expected.txt	2017-06-29 06:07:41 UTC (rev 218920)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_escaping-3-expected.txt	2017-06-29 07:43:07 UTC (rev 218921)
@@ -1,10 +1,5 @@
-CONSOLE MESSAGE: line 15: Unsafe _javascript_ attempt to initiate navigation for frame with URL 'about:blank' from frame with URL 'http://localhost:8800/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_helper-3.html'. The frame attempting navigation is sandboxed, and is therefore disallowed from navigating its ancestors.
 
-CONSOLE MESSAGE: line 15: SecurityError (DOM Exception 18): The operation is insecure.
 
+PASS Check that popups from a sandboxed iframe escape the sandbox if
+   allow-popups-to-escape-sandbox is used 
 
-Harness Error (TIMEOUT), message = null
-
-TIMEOUT Check that popups from a sandboxed iframe escape the sandbox if
-   allow-popups-to-escape-sandbox is used Test timed out
-


Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3-expected.txt (218920 => 218921)

--- 

[webkit-changes] [218835] trunk

2017-06-27 Thread fred . wang
Title: [218835] trunk








Revision 218835
Author fred.w...@free.fr
Date 2017-06-27 08:59:48 -0700 (Tue, 27 Jun 2017)


Log Message
Some tests to verify forbidden frame navigation time out
https://bugs.webkit.org/show_bug.cgi?id=173657

Patch by Frederic Wang  on 2017-06-27
Reviewed by Chris Dumez.

LayoutTests/imported/w3c:

* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-2-expected.txt: Update the text expectation to PASS.
* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation_by_user_activation_without_user_gesture-expected.txt: Ditto.
* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_navigate_ancestor-1-expected.txt: Ditto.
* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_escaping-3-expected.txt: Add the security error until bug 173162 is fixed.
* web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3-expected.txt: Ditto.

Source/WebCore:

Currently some tests try and perform a forbidden frame navigation and verify the
corresponding console error. However, WebKit does not raise any exception for such error so
the tests have to wait until the timeout limit to complete, which makes execution slow.
This patch modifies the setters of window.location for which such error may happen in order
to raise an exception so the tests behave as expected.

No new tests, already covered by existing tests.

* page/Location.cpp: Adjust Location::setLocation to return a security exception and pass it
to the callers.
(WebCore::Location::setHref): Adjust function to possibly return an exception.
(WebCore::Location::setProtocol): Ditto.
(WebCore::Location::setHost): Ditto.
(WebCore::Location::setHostname): Ditto.
(WebCore::Location::setPort): Ditto.
(WebCore::Location::setPathname): Ditto.
(WebCore::Location::setSearch): Ditto.
(WebCore::Location::setHash): Ditto.
(WebCore::Location::assign): Ditto.
(WebCore::Location::setLocation): FrameLoader::findFrameForNavigation is really only used
to verify whether navigating m_frame is permitted so it is more simple and clearer to do it
directly. When navigation is not permitted, this function now raises a security exception.
* page/Location.h: Modify some setters to return an ExceptionOr.
* page/Location.idl: Allow some setters to raise an exception.

LayoutTests:

* fast/frames/sandboxed-iframe-navigation-top-denied-expected.txt: Add the security error.
* http/tests/security/frameNavigation/inactive-function-in-popup-navigate-child.html: Adjust
the test to catch and dump the exception and complete immediately.
* http/tests/security/frameNavigation/inactive-function-in-popup-navigate-child-expected.txt:
Add the dumped security error exception.

Modified Paths

trunk/LayoutTests/ChangeLog
trunk/LayoutTests/fast/frames/sandboxed-iframe-navigation-top-denied-expected.txt
trunk/LayoutTests/http/tests/security/frameNavigation/inactive-function-in-popup-navigate-child-expected.txt
trunk/LayoutTests/http/tests/security/frameNavigation/inactive-function-in-popup-navigate-child.html
trunk/LayoutTests/imported/w3c/ChangeLog
trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation-2-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_allow_top_navigation_by_user_activation_without_user_gesture-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_navigate_ancestor-1-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_escaping-3-expected.txt
trunk/LayoutTests/imported/w3c/web-platform-tests/html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-3-expected.txt
trunk/Source/WebCore/ChangeLog
trunk/Source/WebCore/page/Location.cpp
trunk/Source/WebCore/page/Location.h
trunk/Source/WebCore/page/Location.idl




Diff

Modified: trunk/LayoutTests/ChangeLog (218834 => 218835)

--- trunk/LayoutTests/ChangeLog	2017-06-27 14:49:20 UTC (rev 218834)
+++ trunk/LayoutTests/ChangeLog	2017-06-27 15:59:48 UTC (rev 218835)
@@ -1,3 +1,16 @@
+2017-06-27  Frederic Wang  
+
+Some tests to verify forbidden frame navigation time out
+https://bugs.webkit.org/show_bug.cgi?id=173657
+
+Reviewed by Chris Dumez.
+
+* fast/frames/sandboxed-iframe-navigation-top-denied-expected.txt: Add the security error.
+* http/tests/security/frameNavigation/inactive-function-in-popup-navigate-child.html: Adjust
+the test to catch and dump the exception and complete immediately.
+* 

[webkit-changes] [218762] trunk/LayoutTests

2017-06-23 Thread fred . wang
Title: [218762] trunk/LayoutTests








Revision 218762
Author fred.w...@free.fr
Date 2017-06-23 13:50:26 -0700 (Fri, 23 Jun 2017)


Log Message
Remove fast/regions/region-leak-js-information-when-disabled-at-runtime.html
https://bugs.webkit.org/show_bug.cgi?id=173784

Patch by Frederic Wang  on 2017-06-23
Reviewed by Simon Fraser.

fast/regions/region-leak-js-information-when-disabled-at-runtime.html is supposed to test
that some JS properties are undefined when CSS regions are disabled at runtime. However, this
part is currently commented out and the test is no longer relevant after r200524. Hence we
just remove it.

* fast/regions/region-leak-js-information-when-disabled-at-runtime-expected.txt: Removed.
* fast/regions/region-leak-js-information-when-disabled-at-runtime.html: Removed.

Modified Paths

trunk/LayoutTests/ChangeLog


Removed Paths

trunk/LayoutTests/fast/regions/region-leak-js-information-when-disabled-at-runtime-expected.txt
trunk/LayoutTests/fast/regions/region-leak-js-information-when-disabled-at-runtime.html




Diff

Modified: trunk/LayoutTests/ChangeLog (218761 => 218762)

--- trunk/LayoutTests/ChangeLog	2017-06-23 20:49:34 UTC (rev 218761)
+++ trunk/LayoutTests/ChangeLog	2017-06-23 20:50:26 UTC (rev 218762)
@@ -1,5 +1,20 @@
 2017-06-23  Frederic Wang  
 
+Remove fast/regions/region-leak-js-information-when-disabled-at-runtime.html
+https://bugs.webkit.org/show_bug.cgi?id=173784
+
+Reviewed by Simon Fraser.
+
+fast/regions/region-leak-js-information-when-disabled-at-runtime.html is supposed to test
+that some JS properties are undefined when CSS regions are disabled at runtime. However, this
+part is currently commented out and the test is no longer relevant after r200524. Hence we
+just remove it.
+
+* fast/regions/region-leak-js-information-when-disabled-at-runtime-expected.txt: Removed.
+* fast/regions/region-leak-js-information-when-disabled-at-runtime.html: Removed.
+
+2017-06-23  Frederic Wang  
+
 Use window.internals instead of overridePreference to set WebCore settings in tests
 https://bugs.webkit.org/show_bug.cgi?id=173714
 


Deleted: trunk/LayoutTests/fast/regions/region-leak-js-information-when-disabled-at-runtime-expected.txt (218761 => 218762)

--- trunk/LayoutTests/fast/regions/region-leak-js-information-when-disabled-at-runtime-expected.txt	2017-06-23 20:49:34 UTC (rev 218761)
+++ trunk/LayoutTests/fast/regions/region-leak-js-information-when-disabled-at-runtime-expected.txt	2017-06-23 20:50:26 UTC (rev 218762)
@@ -1,13 +0,0 @@
-Test for 94070 [CSSRegions] broken feature detection: syntax parsing succeeds when CSS REGIONS is disabled at runtime
-
-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-
-
-PASS typeof(document.webkitGetNamedFlows) is "function"
-PASS typeof(document.body.webkitRegionOverset) is "string"
-PASS typeof(document.body.webkitGetRegionFlowRanges) is "function"
-PASS window.WebKitCSSRegionRule is defined.
-PASS successfullyParsed is true
-
-TEST COMPLETE
-


Deleted: trunk/LayoutTests/fast/regions/region-leak-js-information-when-disabled-at-runtime.html (218761 => 218762)

--- trunk/LayoutTests/fast/regions/region-leak-js-information-when-disabled-at-runtime.html	2017-06-23 20:49:34 UTC (rev 218761)
+++ trunk/LayoutTests/fast/regions/region-leak-js-information-when-disabled-at-runtime.html	2017-06-23 20:50:26 UTC (rev 218762)
@@ -1,41 +0,0 @@
-
-
-
-
-
-
-