Title: [209624] trunk/Source/WebKit2
- Revision
- 209624
- Author
- commit-qu...@webkit.org
- Date
- 2016-12-09 12:54:16 -0800 (Fri, 09 Dec 2016)
Log Message
WebView doesn't become first responder in element fullscreen.
https://bugs.webkit.org/show_bug.cgi?id=165664
rdar://problem/28927252
Patch by Jeremy Jones <jere...@apple.com> on 2016-12-09
Reviewed by Tim Horton.
WebView was being set as the first responder while the contentView was still hidden.
A view can not become first responder while it or its ancestor is hidden.
This change waits until after the contentView is visible to make the web view the first responder.
* UIProcess/mac/WKFullScreenWindowController.mm:
(-[WKFullScreenWindowController enterFullScreen:]):
(-[WKFullScreenWindowController _startEnterFullScreenAnimationWithDuration:]):
Modified Paths
Diff
Modified: trunk/Source/WebKit2/ChangeLog (209623 => 209624)
--- trunk/Source/WebKit2/ChangeLog 2016-12-09 19:49:50 UTC (rev 209623)
+++ trunk/Source/WebKit2/ChangeLog 2016-12-09 20:54:16 UTC (rev 209624)
@@ -1,3 +1,20 @@
+2016-12-09 Jeremy Jones <jere...@apple.com>
+
+ WebView doesn't become first responder in element fullscreen.
+ https://bugs.webkit.org/show_bug.cgi?id=165664
+ rdar://problem/28927252
+
+ Reviewed by Tim Horton.
+
+ WebView was being set as the first responder while the contentView was still hidden.
+ A view can not become first responder while it or its ancestor is hidden.
+
+ This change waits until after the contentView is visible to make the web view the first responder.
+
+ * UIProcess/mac/WKFullScreenWindowController.mm:
+ (-[WKFullScreenWindowController enterFullScreen:]):
+ (-[WKFullScreenWindowController _startEnterFullScreenAnimationWithDuration:]):
+
2016-12-09 Gustavo Noronha Silva <gustavo.noro...@collabora.co.uk>
Unreviewed build fix. Thanks to Konstantin Tokarev and Csaba Osztrogonác
Modified: trunk/Source/WebKit2/UIProcess/mac/WKFullScreenWindowController.mm (209623 => 209624)
--- trunk/Source/WebKit2/UIProcess/mac/WKFullScreenWindowController.mm 2016-12-09 19:49:50 UTC (rev 209623)
+++ trunk/Source/WebKit2/UIProcess/mac/WKFullScreenWindowController.mm 2016-12-09 20:54:16 UTC (rev 209624)
@@ -229,7 +229,6 @@
NSDisableScreenUpdates();
[[self window] setAutodisplay:NO];
- NSResponder *webWindowFirstResponder = [[_webView window] firstResponder];
[self _manager]->saveScrollPosition();
_savedTopContentInset = _page->topContentInset();
_page->setTopContentInset(0);
@@ -256,8 +255,6 @@
[_clipView addSubview:_webView positioned:NSWindowBelow relativeTo:nil];
_webView.frame = NSInsetRect(contentView.bounds, 0, -_page->topContentInset());
- makeResponderFirstResponderIfDescendantOfView(self.window, webWindowFirstResponder, _webView);
-
_savedScale = _page->pageScaleFactor();
_page->scalePage(1, IntPoint());
[self _manager]->setAnimatingFullScreen(true);
@@ -619,6 +616,7 @@
[window setCollectionBehavior:(behavior | NSWindowCollectionBehaviorCanJoinAllSpaces)];
[window makeKeyAndOrderFront:self];
[window setCollectionBehavior:behavior];
+ [window makeFirstResponder:_webView];
_page->setSuppressVisibilityUpdates(false);
[[self window] setAutodisplay:YES];
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes