X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fui%2Fgui%2Fvariable-info-dialog.c;h=43a3832c01822dd5829cc42aa317f29700e949a1;hb=df6a0fd4dc5faea7930e6f9093892dfcc8124acc;hp=ba9c043dcd53fb0eaf5cc5a8239f5636327cb838;hpb=7fe9a8e0060736a44164939695e4a6f1eb2af57f;p=pspp diff --git a/src/ui/gui/variable-info-dialog.c b/src/ui/gui/variable-info-dialog.c index ba9c043dcd..43a3832c01 100644 --- a/src/ui/gui/variable-info-dialog.c +++ b/src/ui/gui/variable-info-dialog.c @@ -17,20 +17,19 @@ #include #include #include -#include #include "dict-display.h" #include "var-display.h" #include +#include #include -#include "data-editor.h" +#include "psppire-data-window.h" #include "psppire-dialog.h" #include "psppire-var-store.h" #include "helper.h" -#include #include -#include "syntax-editor.h" +#include "helper.h" #include @@ -165,7 +164,7 @@ static gchar * generate_syntax (GtkTreeView *treeview); void variable_info_dialog (GObject *o, gpointer data) { - struct data_editor *de = data; + PsppireDataWindow *de = PSPPIRE_DATA_WINDOW (data); gint response ; @@ -179,7 +178,7 @@ variable_info_dialog (GObject *o, gpointer data) g_object_get (de->data_editor, "var-store", &vs, NULL); - gtk_window_set_transient_for (GTK_WINDOW (dialog), de->parent.window); + gtk_window_set_transient_for (GTK_WINDOW (dialog), GTK_WINDOW (de)); attach_dictionary_to_treeview (GTK_TREE_VIEW (treeview), vs->dict, @@ -215,11 +214,7 @@ variable_info_dialog (GObject *o, gpointer data) case PSPPIRE_RESPONSE_PASTE: { gchar *syntax = generate_syntax (GTK_TREE_VIEW (treeview)); - - struct syntax_editor *se = - (struct syntax_editor *) window_create (WINDOW_SYNTAX, NULL); - - gtk_text_buffer_insert_at_cursor (se->buffer, syntax, -1); + paste_syntax_in_new_window (syntax); g_free (syntax); }