Changeset 171329 in webkit
- Timestamp:
- Jul 21, 2014 5:58:40 PM (10 years ago)
- Location:
- trunk/Source/WebKit2
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit2/ChangeLog
r171326 r171329 1 2014-07-21 Simon Fraser <simon.fraser@apple.com> 2 3 REGRESSION (r170361): In landscape with UI hidden, fixed position elements at top of screen are too low 4 https://bugs.webkit.org/show_bug.cgi?id=135141 5 <rdar://problem/17627525> 6 7 Reviewed by Benjamin Poulain. 8 9 We can't use the WKWebView's UIScrollView contentInsets to determine the unobscured rect 10 in MobileSafari, because contentInsets can't be changed dynamically while scrolling. 11 To get around this, MobileSafari sets obscured insets instead (but also sets a fixed 12 contentInset). 13 14 So if the client calls _setObscuredInsets:, always use _obscuredInsets to compute the 15 content insets. 16 17 * UIProcess/API/Cocoa/WKWebView.mm: 18 (-[WKWebView _computedContentInset]): 19 (-[WKWebView _setObscuredInsets:]): 20 1 21 2014-07-21 Oliver Hunt <oliver@apple.com> 2 22 -
trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm
r171219 r171329 169 169 170 170 UIEdgeInsets _obscuredInsets; 171 bool _isChangingObscuredInsetsInteractively; 171 BOOL _haveSetObscuredInsets; 172 BOOL _isChangingObscuredInsetsInteractively; 172 173 173 174 UIInterfaceOrientation _interfaceOrientationOverride; … … 741 742 - (UIEdgeInsets)_computedContentInset 742 743 { 743 if ( !UIEdgeInsetsEqualToEdgeInsets(_obscuredInsets, UIEdgeInsetsZero))744 if (_haveSetObscuredInsets) 744 745 return _obscuredInsets; 745 746 … … 2077 2078 ASSERT(obscuredInsets.bottom >= 0); 2078 2079 ASSERT(obscuredInsets.right >= 0); 2080 2081 _haveSetObscuredInsets = YES; 2079 2082 2080 2083 if (UIEdgeInsetsEqualToEdgeInsets(_obscuredInsets, obscuredInsets))
Note: See TracChangeset
for help on using the changeset viewer.