From 59583726adaab9559c6cc58b42f5b054bb9b4fdd Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Sat, 07 Oct 2017 19:01:41 -0400 Subject: MqTabChrome: Call mq_tab_quit() on quit button click --- (limited to 'src/tab-chrome.c') diff --git a/src/tab-chrome.c b/src/tab-chrome.c index 9dd376a..b101b16 100644 --- a/src/tab-chrome.c +++ b/src/tab-chrome.c @@ -359,12 +359,12 @@ about_clicked_cb(GtkButton G_GNUC_UNUSED *button, MqTabChrome *chrome) } static void -quit_clicked_cb(GtkButton G_GNUC_UNUSED *button, - MqTabChrome G_GNUC_UNUSED *chrome) +quit_clicked_cb(GtkButton G_GNUC_UNUSED *button, MqTabChrome *chrome) { - /* TODO: Make a function mq_application_quit() that shows a confirmation - * dialog. */ - gtk_main_quit(); + mq_tab_quit(chrome->tab); + /* mq_tab_quit() just calls mq_window_quit(), which just calls + * mq_application_quit(), which is asynchronous. So close the menu. */ + gtk_widget_hide(chrome->menu_popover); } #define BUTTON_ROWS 6 -- cgit v0.9.1