Can't scroll iframe after toggling it to display:none and back
authorsimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 17 Jan 2018 01:34:42 +0000 (01:34 +0000)
committersimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 17 Jan 2018 01:34:42 +0000 (01:34 +0000)
commit42d605bc0a62f30bc3a956eae1ef133149b223cc
tree08a7a350cb48ddc8a8e87a7344c3a4fa4b5e149a
parent6938fb1243325fe77ae3f88f42d7acdd1deb247b
Can't scroll iframe after toggling it to display:none and back
https://bugs.webkit.org/show_bug.cgi?id=181708
rdar://problem/13234778

Reviewed by Tim Horton.

Source/WebCore:

Nothing updated the FrameView's set of scrollable areas when a subframe came back from display:none.
Mirror the existing virtual removeChild() by making addChild() virtual, and using it to mark
the FrameView's scrollable area set as dirty.

Test: tiled-drawing/scrolling/non-fast-region/non-fast-scrollable-region-hide-show-iframe.html

* page/FrameView.cpp:
(WebCore::FrameView::addChild):
* page/FrameView.h:
* platform/ScrollView.h:

LayoutTests:

* tiled-drawing/scrolling/non-fast-region/non-fast-scrollable-region-hide-show-iframe-expected.txt: Added.
* tiled-drawing/scrolling/non-fast-region/non-fast-scrollable-region-hide-show-iframe.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@227011 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/tiled-drawing/scrolling/non-fast-region/non-fast-scrollable-region-hide-show-iframe-expected.txt [new file with mode: 0644]
LayoutTests/tiled-drawing/scrolling/non-fast-region/non-fast-scrollable-region-hide-show-iframe.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/page/FrameView.cpp
Source/WebCore/page/FrameView.h
Source/WebCore/platform/ScrollView.h