https://bugs.webkit.org/show_bug.cgi?id=200435
rdar://problem/
53942888
Reviewed by Tim Horton.
Source/WebKit:
When we navigate from an overflow:hidden HTML page to a custom view (like PDF), we need
to make sure that the scroll view is scrollable.
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _setHasCustomContentView:loadedMIMEType:]):
Tools:
When we navigate from an overflow:hidden HTML page to a custom view (like PDF), we need
to make sure that the scroll view is scrollable.
* TestWebKitAPI/Tests/ios/ScrollViewScrollabilityTests.mm:
(TestWebKitAPI::TEST):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248281
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2019-08-05 Simon Fraser <simon.fraser@apple.com>
+
+ iOS 13: Overflow:hidden on body prevents PDF scroll
+ https://bugs.webkit.org/show_bug.cgi?id=200435
+ rdar://problem/53942888
+
+ Reviewed by Tim Horton.
+
+ When we navigate from an overflow:hidden HTML page to a custom view (like PDF), we need
+ to make sure that the scroll view is scrollable.
+
+ * UIProcess/API/Cocoa/WKWebView.mm:
+ (-[WKWebView _setHasCustomContentView:loadedMIMEType:]):
+
2019-08-05 John Wilander <wilander@apple.com>
Resource Load Statistics: Re-introduce latch mode for subresource cookie blocking
_scrollViewBackgroundColor = WebCore::Color();
[_scrollView setContentOffset:[self _initialContentOffsetForScrollView]];
+ [_scrollView _setScrollEnabledInternal:YES];
[self _setAvoidsUnsafeArea:NO];
} else if (_customContentView) {
+2019-08-05 Simon Fraser <simon.fraser@apple.com>
+
+ iOS 13: Overflow:hidden on body prevents PDF scroll
+ https://bugs.webkit.org/show_bug.cgi?id=200435
+ rdar://problem/53942888
+
+ Reviewed by Tim Horton.
+
+ When we navigate from an overflow:hidden HTML page to a custom view (like PDF), we need
+ to make sure that the scroll view is scrollable.
+
+ * TestWebKitAPI/Tests/ios/ScrollViewScrollabilityTests.mm:
+ (TestWebKitAPI::TEST):
+
2019-08-05 Aakash Jain <aakash_jain@apple.com>
New EWS:mac-wk2 status-bubble shows waiting to run tests for all recent bugs
#import "PlatformUtilities.h"
#import "TestInputDelegate.h"
+#import "TestNavigationDelegate.h"
#import "TestWKWebView.h"
#import <UIKit/UIKit.h>
#import <WebKit/WKWebViewPrivate.h>
EXPECT_EQ([[webView scrollView] isScrollEnabled], YES);
}
+TEST(ScrollViewScrollabilityTests, ScrollableAfterNavigateToPDF)
+{
+ auto webView = adoptNS([[TestWKWebView alloc] initWithFrame:CGRectMake(0, 0, viewHeight, 414)]);
+
+ [webView synchronouslyLoadHTMLString:nonScrollableDocumentMarkup];
+ [webView waitForNextPresentationUpdate];
+ EXPECT_EQ([[webView scrollView] isScrollEnabled], NO);
+
+ NSURLRequest *request = [NSURLRequest requestWithURL:[[NSBundle mainBundle] URLForResource:@"test" withExtension:@"pdf" subdirectory:@"TestWebKitAPI.resources"]];
+ [webView loadRequest:request];
+
+ [webView _test_waitForDidFinishNavigation];
+
+ EXPECT_EQ([[webView scrollView] isScrollEnabled], YES);
+}
+
} // namespace TestWebKitAPI
#endif // PLATFORM(IOS_FAMILY)