X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fui%2Fgui%2Fpsppire-dict.c;h=bba515019b4a5b8b97dd7874f24b6bbcca1413cd;hb=ecd26ec19e9f8a58079a1c5fa06b39484787ab7e;hp=9637e3cf9cb2b420fca9de381556b62f3849fe9e;hpb=9cb85c5eb1b0e041f4b7b7f1c5ab9cce55de524f;p=pspp-builds.git diff --git a/src/ui/gui/psppire-dict.c b/src/ui/gui/psppire-dict.c index 9637e3cf..bba51501 100644 --- a/src/ui/gui/psppire-dict.c +++ b/src/ui/gui/psppire-dict.c @@ -221,6 +221,13 @@ psppire_dict_new_from_dict (struct dictionary *d) } +void +psppire_dict_replace_dictionary (PsppireDict *dict, struct dictionary *d) +{ + dict->dict = d; +} + + /* Returns a valid name for a new variable in DICT. The return value is statically allocated */ static gchar * @@ -339,7 +346,6 @@ psppire_dict_lookup_var (const PsppireDict *d, const gchar *name) return dict_lookup_var (d->dict, name); } - /* Clears the contents of D */ void psppire_dict_clear (PsppireDict *d) @@ -348,14 +354,11 @@ psppire_dict_clear (PsppireDict *d) g_return_if_fail (d->dict); { - const gint n_vars = dict_get_var_cnt (d->dict); - dict_clear (d->dict); } } - /* Return true is NAME would be a valid name of a variable to add to the dictionary. False otherwise. If REPORT is true, then invalid names will be reported as such as errors