Commit 6ecca1fe authored by Serge A. Zaitsev's avatar Serge A. Zaitsev

added disabled/enabled flags for gtk implementation

parent 1a4a1446
......@@ -59,7 +59,9 @@ static void tray_update(struct tray *tray) {
if (strcmp(m->text, "-") == 0) {
item = gtk_separator_menu_item_new();
} else {
item = gtk_menu_item_new_with_label(m->text);
item = gtk_check_menu_item_new_with_label(m->text);
gtk_widget_set_sensitive(item, !m->disabled);
gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(item), !!m->checked);
}
gtk_widget_show(item);
gtk_menu_shell_append(GTK_MENU_SHELL(gtk_menu), item);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment