From e83d832f3106c0cfdd5bbcff84baecc0395731ae Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Sat, 28 Oct 2017 14:21:19 -0400 Subject: MqMainMenu: Make "Open file" button effective --- (limited to 'src/toolbars/navigation') diff --git a/src/toolbars/navigation/main-menu.c b/src/toolbars/navigation/main-menu.c index 7b5073c..4594f13 100644 --- a/src/toolbars/navigation/main-menu.c +++ b/src/toolbars/navigation/main-menu.c @@ -60,6 +60,13 @@ zoom_out_clicked_cb(GtkButton G_GNUC_UNUSED *button, MqMainMenu *main_menu) } static void +open_clicked_cb(GtkButton G_GNUC_UNUSED *button, MqMainMenu *main_menu) +{ + gtk_widget_hide(main_menu->popover); + mq_tab_page_open(main_menu->tab_page); +} + +static void zoom_reset_clicked_cb(GtkButton G_GNUC_UNUSED *button, MqMainMenu *main_menu) { mq_web_view_zoom_reset(main_menu->web_view); @@ -172,7 +179,7 @@ menu_clicked_cb(MqMainMenu *main_menu) CLICKED_CB(0, 0, zoom_out_clicked_cb); CLICKED_CB(0, 1, zoom_reset_clicked_cb); CLICKED_CB(0, 2, zoom_in_clicked_cb); - /* TODO: 1, 0: Open file */ + CLICKED_CB(1, 0, open_clicked_cb); /* TODO: 1, 1: Save page */ /* TODO: 1, 2: E-mail link */ CLICKED_CB(2, 0, find_clicked_cb); -- cgit v0.9.1