linux: Prompt library fixes (#16850)

This PR fixes two issues:
1. The prompt library window didn't set an `app_id` on Linux, which
caused it to be missing the Zed logo
2. A dangling reference to the window in the Wayland client code, which
caused the prompt library window not to close. See:
https://github.com/zed-industries/zed/pull/13201

Release Notes:

- Linux: Fixed the prompt library not closing on Wayland

---------

Co-authored-by: Junkui Zhang <364772080@qq.com>
This commit is contained in:
apricotbucket28 2024-08-29 00:11:01 -03:00 committed by GitHub
parent 9ad845b40a
commit a68a543d43
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 13 additions and 6 deletions

View file

@ -815,7 +815,8 @@ pub struct TitlebarOptions {
/// The initial title of the window
pub title: Option<SharedString>,
/// Whether the titlebar should appear transparent (macOS only)
/// Should the default system titlebar be hidden to allow for a custom-drawn titlebar? (macOS and Windows only)
/// Refer to [`WindowOptions::window_decorations`] on Linux
pub appears_transparent: bool,
/// The position of the macOS traffic light buttons

View file

@ -982,7 +982,8 @@ impl Dispatch<xdg_toplevel::XdgToplevel, ObjectId> for WaylandClientStatePtr {
let should_close = window.handle_toplevel_event(event);
if should_close {
this.drop_window(surface_id);
// The close logic will be handled in drop_window()
window.close();
}
}
}