Fix compile warnings
authorJohn Darrington <john@darrington.wattle.id.au>
Tue, 7 Jul 2009 05:19:18 +0000 (13:19 +0800)
committerJohn Darrington <john@darrington.wattle.id.au>
Tue, 7 Jul 2009 05:19:18 +0000 (13:19 +0800)
src/ui/gui/helper.c
src/ui/gui/helper.h
src/ui/gui/psppire-var-store.c
src/ui/gui/var-display.c
src/ui/gui/variable-info-dialog.c

index b4b3872df3abecf00de49e2e36979a333cb7e2f1..4ec4bb0c1a9601601b0e02b2f1cc2b7a185856f6 100644 (file)
@@ -49,7 +49,7 @@
 /* Formats a value according to FORMAT
    The returned string must be freed when no longer required */
 gchar *
 /* Formats a value according to FORMAT
    The returned string must be freed when no longer required */
 gchar *
-value_to_text (union value v, PsppireDict *dict, struct fmt_spec format)
+value_to_text (union value v, const PsppireDict *dict, struct fmt_spec format)
 {
   gchar *s = 0;
 
 {
   gchar *s = 0;
 
index 6706df20701e39bd9705ffbe17c6579e2c587966..2a7be4aa14266c98ec96adb51326bba1a69eda5e 100644 (file)
@@ -34,7 +34,7 @@ struct fmt_spec;
 
 /* Formats a value according to FORMAT
    The returned string must be freed when no longer required */
 
 /* Formats a value according to FORMAT
    The returned string must be freed when no longer required */
-gchar * value_to_text (union value v, PsppireDict *dict, struct fmt_spec format);
+gchar * value_to_text (union value v, const PsppireDict *dict, struct fmt_spec format);
 
 
 gboolean text_to_value (const gchar *text, union value *v,
 
 
 gboolean text_to_value (const gchar *text, union value *v,
index 991fdf467d5792a1c5ea3f0c4612d83ba95719bb..26c1ee4d34e6cd0d5b13b4f2f89c78e1d5b865c8 100644 (file)
@@ -696,7 +696,7 @@ text_for_column (PsppireVarStore *vs,
            g_assert (vl);
 
            {
            g_assert (vl);
 
            {
-             gchar *const vstr = value_to_text (vl->value, dict->dict, *write_spec);
+             gchar *const vstr = value_to_text (vl->value, dict, *write_spec);
 
              return g_strdup_printf ( "{%s,\"%s\"}_", vstr, val_lab_get_label (vl));
            }
 
              return g_strdup_printf ( "{%s,\"%s\"}_", vstr, val_lab_get_label (vl));
            }
index fcec1e8f827509f97cc3238a156a83a0ccc22a46..7081e9e2c0bde74fc4c9424f729733ba8a74c1c2 100644 (file)
@@ -45,7 +45,7 @@ missing_values_to_string (const PsppireDict *dict, const struct variable *pv, GE
          gint i;
          for (i = 0 ; i < n; ++i )
            {
          gint i;
          for (i = 0 ; i < n; ++i )
            {
-             mv[i] = value_to_text (*mv_get_value (miss, i), dict->dict, *fmt);
+             mv[i] = value_to_text (*mv_get_value (miss, i), dict, *fmt);
              if ( i > 0 )
                g_string_append (gstr, ", ");
              g_string_append (gstr, mv[i]);
              if ( i > 0 )
                g_string_append (gstr, ", ");
              g_string_append (gstr, mv[i]);
@@ -61,8 +61,8 @@ missing_values_to_string (const PsppireDict *dict, const struct variable *pv, GE
          union value low, high;
          mv_get_range (miss, &low.f, &high.f);
 
          union value low, high;
          mv_get_range (miss, &low.f, &high.f);
 
-         l = value_to_text (low, dict->dict, *fmt);
-         h = value_to_text (high, dict->dict,*fmt);
+         l = value_to_text (low, dict, *fmt);
+         h = value_to_text (high, dict,*fmt);
 
          g_string_printf (gstr, "%s - %s", l, h);
          g_free (l);
 
          g_string_printf (gstr, "%s - %s", l, h);
          g_free (l);
@@ -72,7 +72,7 @@ missing_values_to_string (const PsppireDict *dict, const struct variable *pv, GE
            {
              gchar *ss = 0;
 
            {
              gchar *ss = 0;
 
-             ss = value_to_text (*mv_get_value (miss, 0), dict->dict, *fmt);
+             ss = value_to_text (*mv_get_value (miss, 0), dict, *fmt);
 
              g_string_append (gstr, ", ");
              g_string_append (gstr, ss);
 
              g_string_append (gstr, ", ");
              g_string_append (gstr, ss);
index afa96615d5f9a1405c0c4a7c9c9b65e15a0a52f4..178a834c7a0d8357c642997c649f81f9612488b6 100644 (file)
@@ -113,7 +113,7 @@ populate_text (PsppireDictView *treeview, gpointer data)
         {
           const struct val_lab *vl = labels[i];
          gchar *const vstr  =
         {
           const struct val_lab *vl = labels[i];
          gchar *const vstr  =
-           value_to_text (vl->value,  dict->dict, *var_get_print_format (var));
+           value_to_text (vl->value,  dict, *var_get_print_format (var));
 
          g_string_append_printf (gstring, _("%s %s\n"), vstr, val_lab_get_label (vl));
 
 
          g_string_append_printf (gstring, _("%s %s\n"), vstr, val_lab_get_label (vl));