Search
lxdream.org :: lxdream/src/gui/main_win.c :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename src/gui/main_win.c
changeset 457:af605fd32c0b
prev455:3080881d00d4
next480:d28c2992f5ee
author nkeynes
date Sun Oct 21 11:38:02 2007 +0000 (12 years ago)
permissions -rw-r--r--
last change Finish updating debug gui window bits
file annotate diff log raw
1.1 --- a/src/gui/main_win.c Sun Oct 21 05:21:35 2007 +0000
1.2 +++ b/src/gui/main_win.c Sun Oct 21 11:38:02 2007 +0000
1.3 @@ -1,5 +1,5 @@
1.4 /**
1.5 - * $Id: main_win.c,v 1.6 2007-10-21 05:21:35 nkeynes Exp $
1.6 + * $Id: main_win.c,v 1.7 2007-10-21 11:38:02 nkeynes Exp $
1.7 *
1.8 * Define the main (emu) GTK window, along with its menubars,
1.9 * toolbars, etc.
1.10 @@ -38,6 +38,11 @@
1.11 GtkActionGroup *actions;
1.12 };
1.13
1.14 +gboolean on_main_window_deleted( GtkWidget *widget, GdkEvent event, gpointer user_data )
1.15 +{
1.16 + exit(0);
1.17 +}
1.18 +
1.19 main_window_t main_window_new( const gchar *title, GtkWidget *menubar, GtkWidget *toolbar,
1.20 GtkAccelGroup *accel_group )
1.21 {
1.22 @@ -70,6 +75,8 @@
1.23 gtk_widget_grab_focus( win->video );
1.24
1.25 gtk_statusbar_push( GTK_STATUSBAR(win->statusbar), 1, "Stopped" );
1.26 + g_signal_connect( win->window, "delete_event",
1.27 + G_CALLBACK(on_main_window_deleted), win );
1.28 return win;
1.29 }
1.30
.