/[xlog]/xlog/src/callbacks.c
ViewVC logotype

Diff of /xlog/src/callbacks.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.13 by pa4tu, Mon Dec 9 20:32:09 2002 UTC revision 1.14 by pa4tu, Tue Dec 10 14:53:56 2002 UTC
# Line 2465  on_dialogsdialog_delete_event(GtkWidget Line 2465  on_dialogsdialog_delete_event(GtkWidget
2465  void  void
2466  on_dialogsokbutton_clicked(GtkButton * button, gpointer user_data)  on_dialogsokbutton_clicked(GtkButton * button, gpointer user_data)
2467  {  {
2468    GtkWidget *dialogsdialog, *checkbutton;    GtkWidget *dialogsdialog, *checkbutton, *b4clist;
2469    gchar *widgetname, **states;    gchar *widgetname, **states;
2470    gboolean check;    gboolean check;
2471    gint i;    gint i;
2472    
2473    states = g_new0 (gchar *, 20);    states = g_new0 (gchar *, 20);
2474    dialogsdialog = gtk_widget_get_toplevel (GTK_WIDGET (button));    dialogsdialog = gtk_widget_get_toplevel (GTK_WIDGET (button));
2475      b4clist = lookup_widget(b4dialog, "b4clist");
2476    for (i = 0; i < 19; i++)    for (i = 0; i < 19; i++)
2477    { /* look up name of the  button and get it's togglestate */    { /* look up name of the  button and get it's togglestate */
2478      widgetname = g_strdup_printf("b4%d", i);      widgetname = g_strdup_printf("b4%d", i);
2479      checkbutton = lookup_widget(dialogsdialog, widgetname);      checkbutton = lookup_widget(dialogsdialog, widgetname);
2480      check = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (checkbutton));      check = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (checkbutton));
2481        if (GTK_WIDGET_VISIBLE (b4dialog))
2482          gtk_clist_set_column_visibility (GTK_CLIST (b4clist), i, check);
2483      states[i] = g_strdup(check ? "1" : "0");      states[i] = g_strdup(check ? "1" : "0");
2484      g_free(widgetname);      g_free(widgetname);
2485    }    }
# Line 2488  on_dialogsokbutton_clicked(GtkButton * b Line 2491  on_dialogsokbutton_clicked(GtkButton * b
2491    g_free(states);    g_free(states);
2492    
2493    gtk_widget_destroy (dialogsdialog);    gtk_widget_destroy (dialogsdialog);
2494      if (GTK_WIDGET_VISIBLE (b4dialog))
2495        gtk_widget_set_sensitive (b4dialog, 1);
2496    gtk_widget_set_sensitive (mainwindow, 1);    gtk_widget_set_sensitive (mainwindow, 1);
2497  }  }
2498    

Legend:
Removed from v.1.13  
changed lines
  Added in v.1.14

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26