gpui: Fix show: false
support on Windows to create an invisible window (#18161)
Release Notes: - N/A - The `show` of WindowOptions is valid on macOS but not on Windows, this changes to fix it to support create an invisible window. ```bash cargo run -p gpui --example window ``` ## Before https://github.com/user-attachments/assets/4157bdaa-39a7-44df-bbdc-30b00e9c61e9 ## After https://github.com/user-attachments/assets/d48fa524-0caa-4f87-932d-01d7a468c488 https://github.com/user-attachments/assets/dd052f15-c8db-4a2a-a6af-a7c0ffecca84
This commit is contained in:
parent
1d2172aba8
commit
39be9e5949
3 changed files with 180 additions and 3 deletions
|
@ -707,7 +707,7 @@ impl MacWindow {
|
|||
}
|
||||
}
|
||||
|
||||
if focus {
|
||||
if focus && show {
|
||||
native_window.makeKeyAndOrderFront_(nil);
|
||||
} else if show {
|
||||
native_window.orderFront_(nil);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue