From 0489871e5737cb5452fb1cd95efabe59a1d4989a Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Fri, 03 Nov 2017 14:43:07 -0400 Subject: MqMainMenu: Add (WIP) profile button --- (limited to 'src/toolbars/navigation') diff --git a/src/toolbars/navigation/main-menu.c b/src/toolbars/navigation/main-menu.c index 467d5fc..9fc14bc 100644 --- a/src/toolbars/navigation/main-menu.c +++ b/src/toolbars/navigation/main-menu.c @@ -27,6 +27,7 @@ #include "../../notebook.h" #include "../../tab-page.h" +#include "../../utils/profile-icon.h" #include "../../web-view.h" #include "../find-toolbar.h" @@ -339,6 +340,22 @@ create_main_grid(MqMainMenu *main_menu) #undef NEW_BUTTON #undef CLICKED_CB +static GtkWidget * +create_profile_buttons(MqMainMenu G_GNUC_UNUSED *main_menu) +{ + GtkWidget *profile_button; + + profile_button = gtk_button_new(); + gtk_button_set_image(GTK_BUTTON(profile_button), + gtk_image_new_from_pixbuf( + mq_profile_icon_new_pixbuf("#0000ff"))); + gtk_button_set_label(GTK_BUTTON(profile_button), "Default"); + gtk_button_set_image_position(GTK_BUTTON(profile_button), GTK_POS_LEFT); + gtk_button_set_always_show_image(GTK_BUTTON(profile_button), TRUE); + + return profile_button; +} + static void menu_clicked_cb(MqMainMenu *main_menu) { @@ -352,6 +369,8 @@ menu_clicked_cb(MqMainMenu *main_menu) TRUE, TRUE, 0); gtk_box_pack_start(GTK_BOX(box), create_main_grid(main_menu), TRUE, TRUE, 0); + gtk_box_pack_start(GTK_BOX(box), create_profile_buttons(main_menu), + TRUE, TRUE, 0); gtk_box_pack_start(GTK_BOX(box), create_application_buttons(main_menu), TRUE, TRUE, 0); -- cgit v0.9.1