From 1646d5ac84f4b31add388d797e8d0a1b1384d4a4 Mon Sep 17 00:00:00 2001 From: crumblingstatue Date: Thu, 24 Nov 2022 01:41:28 +0100 Subject: [PATCH] gtk3/message_dialog: Set window title (#94) If it's not set, it will be an empty string, appearing as such in the user's window manager, etc. --- src/backend/gtk3/message_dialog.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/backend/gtk3/message_dialog.rs b/src/backend/gtk3/message_dialog.rs index 7f40cda..978f369 100644 --- a/src/backend/gtk3/message_dialog.rs +++ b/src/backend/gtk3/message_dialog.rs @@ -59,6 +59,9 @@ impl GtkMessageDialog { title.as_ptr(), ) as *mut gtk_sys::GtkDialog; + // Also set the window title, otherwise it would be empty + gtk_sys::gtk_window_set_title(dialog as _, title.as_ptr()); + for custom_button in custom_buttons { if let Some((custom_button_cstr, response_id)) = custom_button { gtk_sys::gtk_dialog_add_button(