Refactor common code in dialog implementations
[pspp-builds.git] / src / ui / gui / psppire-syntax-window.c
index 5b3267441dc50140f495ee2883531e555382688f..c8fede093ae7b60144d991f09e3b74a3691775b5 100644 (file)
 #include <libpspp/message.h>
 #include <stdlib.h>
 
-
 #include "psppire-syntax-window.h"
 
 #include "psppire-data-window.h"
+#include "psppire-window-register.h"
 #include "about.h"
 #include "psppire-syntax-window.h"
 #include "syntax-editor-source.h"
 #define _(msgid) gettext (msgid)
 #define N_(msgid) msgid
 
-
-
 static void psppire_syntax_window_base_finalize (PsppireSyntaxWindowClass *, gpointer);
 static void psppire_syntax_window_base_init     (PsppireSyntaxWindowClass *class);
 static void psppire_syntax_window_class_init    (PsppireSyntaxWindowClass *class);
 static void psppire_syntax_window_init          (PsppireSyntaxWindow      *syntax_editor);
 
-
 GType
 psppire_syntax_window_get_type (void)
 {
@@ -73,7 +70,6 @@ psppire_syntax_window_get_type (void)
   return psppire_syntax_window_type;
 }
 
-
 static void
 psppire_syntax_window_finalize (GObject *object)
 {
@@ -474,6 +470,7 @@ open_syntax_window (GtkMenuItem *menuitem, gpointer parent)
 }
 
 
+
 extern struct source_stream *the_source_stream ;
 
 static void
@@ -574,8 +571,9 @@ psppire_syntax_window_init (PsppireSyntaxWindow *window)
 
   g_signal_connect (get_widget_assert (xml,"windows_minimise_all"),
                    "activate",
-                   G_CALLBACK (psppire_window_minimise_all),
-                   NULL);
+                   G_CALLBACK (psppire_window_minimise_all), NULL);
+
+  PSPPIRE_WINDOW (window)->menu = GTK_MENU_SHELL (get_widget_assert (xml,"windows_menu"));
 
   g_object_unref (xml);