Improve the resizing experience of frameless windows
Minor
提交哈希:
0780bb2fc737e8061acd3af2441ed19aacc2fc95
提交时间: 2025-03-28 16:26:47+00:00
影响等级: Minor
生成工具: webview2-upstream-sentry
上游审核链接:
查看上游审核 🔗
📋 摘要
This submission primarily targets the NativeWidgetMacNSWindow of remote_cocoa on macOS, optimizing the border dragging experience for non-titled resizable windows (such as glic windows). By overriding the private NSWindow method _getExteriorResizeEdgeThicknesses:forStyleMask:, non-titled resizable windows now adopt the same exterior drag border thickness as titled windows, thereby improving the usability of window resizing via dragging. This change only affects the hit area of the window border and does not involve core logic such as window management, lifecycle, or Mojo interfaces.
🎯 影响分析
This change only affects the window drag-to-resize experience on macOS, enhancing the user interaction friendliness of frameless resizable windows. For WebView2Mac, if its downstream window implementation inherits from NativeWidgetMacNSWindow and adopts the frameless resizable style, it will directly benefit from a larger drag area, improving the window usability of the host application. This change does not affect core functionalities such as window lifecycle management, Mojo communication, NSView embedding, or window event dispatching, and has no negative impact on the functionality or performance of WebView2Mac. If WebView2Mac does not use frameless resizable windows, there is no actual impact.
受影响的类:
NativeWidgetMacNSWindow
NSWindow (NSWindowResizing category)