index 32c1ef9b482df739da42d2efa287e85b7606170f..664ffd13d2f0da4c627f7ada5a61e3ab44219781 100644 (file)
gchar* sss = 0;
g_object_get( G_OBJECT(action), "short_label", &sss, NULL );
- if (sss) {
+ // If short_label not defined, g_object_get will return label.
+ // This hack allows a label to be used with a drop-down menu when
+ // no label is used with a set of icons that are self-explanatory.
+ if (sss && strcmp( sss, "NotUsed" ) != 0 ) {
GtkWidget* lbl;
lbl = gtk_label_new(sss);
gtk_box_pack_start( GTK_BOX(holder), lbl, FALSE, FALSE, 4 );
if ( act->private_data->sensitiveColumn >= 0 ) {
gtk_action_set_sensitive( GTK_ACTION(ract), sens );
}
-
+
gtk_radio_action_set_group( ract, group );
group = gtk_radio_action_get_group( ract );
GSList* group = (GSList*)data;
// List is backwards in group as compared to GtkTreeModel, we better do matching.
while ( group ) {
+#if GTK_CHECK_VERSION(2,16,0)
GtkRadioAction* ract = GTK_RADIO_ACTION(group->data);
const gchar* label = gtk_action_get_label( GTK_ACTION( ract ) );
}
gtk_action_set_sensitive( GTK_ACTION(ract), sens );
+#endif
group = g_slist_next(group);
}
} else if ( GTK_IS_MENU_ITEM(proxies->data) ) {
/* Not implemented */
}
-
+
proxies = g_slist_next( proxies );
}