Commit 9a4ed97e authored by Claes Sjofors's avatar Claes Sjofors

Xtt operator window bugfix, opmenu hierarchies with gave double menu entries

parent cf36004a
...@@ -1522,11 +1522,14 @@ pwr_tStatus CoWowGtk::CreateMenuItem( const char *name, void *menu, int pixmap, ...@@ -1522,11 +1522,14 @@ pwr_tStatus CoWowGtk::CreateMenuItem( const char *name, void *menu, int pixmap,
for( GList *ch = chlist; ch; ch = ch->next) { for( GList *ch = chlist; ch; ch = ch->next) {
GtkWidget *labelw = gtk_bin_get_child( GTK_BIN(ch->data)); GtkWidget *labelw = gtk_bin_get_child( GTK_BIN(ch->data));
strncpy( label, (char *)gtk_label_get_text( GTK_LABEL(labelw)), sizeof(label)); strncpy( label, (char *)gtk_label_get_text( GTK_LABEL(labelw)), sizeof(label));
if ( cdh_NoCaseStrcmp( label, name_array[i]) == 0) { char *label_iso = g_convert( label, -1, "ISO8859-1", "UTF-8", NULL, NULL, NULL);
if ( cdh_NoCaseStrcmp( label_iso, name_array[i]) == 0) {
child = GTK_WIDGET(ch->data); child = GTK_WIDGET(ch->data);
found = 1; found = 1;
g_free( label_iso);
break; break;
} }
g_free( label_iso);
} }
if ( !found) { if ( !found) {
// Create the menu item // Create the 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