X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;ds=sidebyside;f=src%2Fui%2Fgui%2Fpsppire-syntax-window.c;h=8750e995b22244145101aad24b9f35a9e48d57c8;hb=109eccf01c32b5784f464de2d424fd7a9905123f;hp=fddc005e5fdcd25d5c73cef231d40264dc1d224d;hpb=258cbd9cdf386687122b0854274923acafc786d4;p=pspp diff --git a/src/ui/gui/psppire-syntax-window.c b/src/ui/gui/psppire-syntax-window.c index fddc005e5f..8750e995b2 100644 --- a/src/ui/gui/psppire-syntax-window.c +++ b/src/ui/gui/psppire-syntax-window.c @@ -19,10 +19,7 @@ #include #include -#include -#include -#include -#include +#include #include "language/lexer/lexer.h" #include "libpspp/encoding-guesser.h" @@ -647,13 +644,15 @@ create_syntax_window (void) gtk_widget_show (w); } -void +GtkWindow * open_syntax_window (const char *file_name, const gchar *encoding) { GtkWidget *se = psppire_syntax_window_new (NULL); if ( file_name) load_and_show_syntax_window (se, file_name, encoding); + + return GTK_WINDOW (se); } @@ -798,7 +797,7 @@ psppire_syntax_window_init (PsppireSyntaxWindow *window) gtk_widget_show_all (box); - GApplication *app = g_application_get_default (); + GtkApplication *app = GTK_APPLICATION (g_application_get_default ()); { GSimpleAction *open = g_simple_action_new ("open", NULL); @@ -885,7 +884,7 @@ psppire_syntax_window_init (PsppireSyntaxWindow *window) g_action_map_add_action (G_ACTION_MAP (window), G_ACTION (run_current_line)); - GApplication *app = g_application_get_default (); + GtkApplication *app = GTK_APPLICATION (g_application_get_default ()); const gchar *accels[2] = { "R", NULL}; gtk_application_set_accels_for_action (app, "win.run-current-line",