Changeset 280976 in webkit
- Timestamp:
- Aug 12, 2021 12:16:04 PM (11 months ago)
- Location:
- trunk/Source
- Files:
-
- 5 edited
-
WebCore/ChangeLog (modified) (1 diff)
-
WebCore/platform/PlatformScreen.h (modified) (2 diffs)
-
WebCore/platform/mac/PlatformScreenMac.mm (modified) (2 diffs)
-
WebKit/ChangeLog (modified) (1 diff)
-
WebKit/UIProcess/mac/WKFullScreenWindowController.mm (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r280973 r280976 1 2021-08-12 Jer Noble <jer.noble@apple.com> 2 3 [macOS] Enter fullscreen animation interferes with auto-hiding menu bar 4 https://bugs.webkit.org/show_bug.cgi?id=229039 5 <rdar://79150656> 6 7 Reviewed by Eric Carlson. 8 9 Add a new utility method to calculate the available screen rect taking menu bar 10 hiding into account. 11 12 * platform/PlatformScreen.h: 13 * platform/mac/PlatformScreenMac.mm: 14 (WebCore::screenRectAvoidingMenuBar): 15 1 16 2021-08-12 Devin Rousso <drousso@apple.com> 2 17 -
trunk/Source/WebCore/platform/PlatformScreen.h
r278340 r280976 118 118 FloatRect screenRectForDisplay(PlatformDisplayID); 119 119 WEBCORE_EXPORT FloatRect screenRectForPrimaryScreen(); 120 WEBCORE_EXPORT FloatRect availableScreenRect(NSScreen *); 120 121 121 122 WEBCORE_EXPORT FloatRect toUserSpace(const NSRect&, NSWindow *destination); … … 133 134 IORegistryGPUID gpuIDForDisplay(PlatformDisplayID); 134 135 IORegistryGPUID gpuIDForDisplayMask(uint32_t); 136 137 WEBCORE_EXPORT FloatRect screenRectAvoidingMenuBar(NSScreen *); 135 138 136 139 #endif // !PLATFORM(MAC) -
trunk/Source/WebCore/platform/mac/PlatformScreenMac.mm
r277986 r280976 45 45 #endif 46 46 47 #if USE(APPLE_INTERNAL_SDK) && __has_include(<WebKitAdditions/PlatformScreenIOS.mm>) 48 #import <WebKitAdditions/PlatformScreenMac.h> 49 #endif 50 47 51 namespace WebCore { 48 52 … … 416 420 } 417 421 422 #if USE(APPLE_INTERNAL_SDK) && __has_include(<WebKitAdditions/PlatformScreenIOS.mm>) 423 #import <WebKitAdditions/PlatformScreenMac.mm> 424 #else 425 FloatRect screenRectAvoidingMenuBar(NSScreen* screen) 426 { 427 return screen.frame; 428 } 429 #endif 430 431 418 432 } // namespace WebCore 419 433 -
trunk/Source/WebKit/ChangeLog
r280973 r280976 1 2021-08-12 Jer Noble <jer.noble@apple.com> 2 3 [macOS] Enter fullscreen animation interferes with auto-hiding menu bar 4 https://bugs.webkit.org/show_bug.cgi?id=229039 5 <rdar://79150656> 6 7 Reviewed by Eric Carlson. 8 9 When entering fullscreen, if a user has unchecked the "auto-hide menu bar in fullscreen" 10 setting, the fullscreen animation will enter to the full screen frame, then snap down once 11 the animation completes to reveal the menu bar. Instead, use a WebCore utility method to 12 calculate the screen's frame taking that menu bar into account, and use it for the initial 13 enter fullscreen animation. 14 15 * UIProcess/mac/WKFullScreenWindowController.mm: 16 (-[WKFullScreenWindowController enterFullScreen:]): 17 1 18 2021-08-12 Devin Rousso <drousso@apple.com> 2 19 -
trunk/Source/WebKit/UIProcess/mac/WKFullScreenWindowController.mm
r280670 r280976 228 228 if (!screen) 229 229 screen = [NSScreen mainScreen]; 230 NSRect screenFrame = [screen frame]; 231 230 231 NSRect screenFrame = WebCore::screenRectAvoidingMenuBar(screen); 232 232 NSRect webViewFrame = convertRectToScreen([_webView window], [_webView convertRect:[_webView frame] toView:nil]); 233 233
Note: See TracChangeset
for help on using the changeset viewer.