mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-24 20:56:08 +03:00
gtk: handle all close-requests
When compiling in any Release mode, the default gtk close-request handler does not properly fire. We only rely on the default handler if we aren't confirming the close. Replace the default handler with our own in all cases (and just destroy the window if we don't need confirmation). Fixes #458
This commit is contained in:
@ -596,7 +596,10 @@ const Window = struct {
|
||||
if (surface.window == self) {
|
||||
if (surface.core_surface.needsConfirmQuit()) break;
|
||||
}
|
||||
} else return false;
|
||||
} else {
|
||||
c.gtk_window_destroy(self.window);
|
||||
return true;
|
||||
}
|
||||
|
||||
// Setup our basic message
|
||||
const alert = c.gtk_message_dialog_new(
|
||||
|
Reference in New Issue
Block a user