gui: Remove write-only variable 'new_type' from on_var_type_ok_clicked().
[pspp-builds.git] / src / ui / gui / var-type-dialog.c
index 05ba5d3c9e748c61662bc8ee48914a521938490f..5ba028d49e5887e6a3f95621e18c88789fcb9211 100644 (file)
@@ -1,5 +1,5 @@
 /* PSPPIRE - a graphical user interface for PSPP.
-    Copyright (C) 2005, 2006  Free Software Foundation
+    Copyright (C) 2005, 2006, 2010  Free Software Foundation
 
    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -445,7 +445,7 @@ var_type_dialog_create (GtkWindow *toplevel)
   g_object_unref (list_store);
 
   g_signal_connect (dialog->date_format_treeview, "cursor-changed",
-                  GTK_SIGNAL_FUNC (set_format_from_treeview), dialog);
+                  G_CALLBACK (set_format_from_treeview), dialog);
 
 
   /* populate the dollar treeview */
@@ -483,11 +483,11 @@ var_type_dialog_create (GtkWindow *toplevel)
 
   g_signal_connect (dialog->dollar_treeview,
                   "cursor-changed",
-                  GTK_SIGNAL_FUNC (set_format_from_treeview), dialog);
+                  G_CALLBACK (set_format_from_treeview), dialog);
 
   g_signal_connect_swapped (dialog->dollar_treeview,
                   "cursor-changed",
-                  GTK_SIGNAL_FUNC (update_width_decimals), dialog);
+                  G_CALLBACK (update_width_decimals), dialog);
 
 
   /* populate the custom treeview */
@@ -527,22 +527,22 @@ var_type_dialog_create (GtkWindow *toplevel)
 
   g_signal_connect (dialog->custom_treeview,
                   "cursor-changed",
-                  GTK_SIGNAL_FUNC (set_format_type_from_treeview), dialog);
+                  G_CALLBACK (set_format_type_from_treeview), dialog);
 
 
   g_signal_connect (dialog->custom_treeview,
                   "cursor-changed",
-                  GTK_SIGNAL_FUNC (preview_custom), dialog);
+                  G_CALLBACK (preview_custom), dialog);
 
 
   g_signal_connect (dialog->entry_width,
                   "changed",
-                  GTK_SIGNAL_FUNC (preview_custom), dialog);
+                  G_CALLBACK (preview_custom), dialog);
 
 
   g_signal_connect (dialog->entry_decimals,
                   "changed",
-                  GTK_SIGNAL_FUNC (preview_custom), dialog);
+                  G_CALLBACK (preview_custom), dialog);
 
 
   /* Connect to the OK button */
@@ -790,14 +790,12 @@ on_var_type_ok_clicked (GtkWidget *w, gpointer data)
     gint decimals = atoi (gtk_entry_get_text
                         (GTK_ENTRY (dialog->entry_decimals)));
 
-    gint new_type = VAL_NUMERIC;
     gint new_width = 0;
     bool result = false;
     struct fmt_spec spec;
     switch (dialog->active_button)
       {
       case BUTTON_STRING:
-       new_type = VAL_STRING;
        new_width = width;
        result = make_output_format_try (&spec, FMT_A, width, 0);
        break;