Mercurial > hg > xmms-sid
diff src/xmms-sid.h @ 612:32fc27395220
About window wasn't handling delete_event properly, fixed; Cleaned up event handling a bit.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Sun, 02 Sep 2007 00:03:05 +0000 |
parents | 88bc61a2914f |
children | 6f9c5bb127e6 |
line wrap: on
line diff
--- a/src/xmms-sid.h Sat Sep 01 14:43:05 2007 +0000 +++ b/src/xmms-sid.h Sun Sep 02 00:03:05 2007 +0000 @@ -216,6 +216,27 @@ # endif #endif + +/* And even some Gtk+ macro crap here, yay. + */ +#define XS_DEF_WINDOW_DELETE(ME, MV) \ +gboolean xs_ ## ME ## _delete(GtkWidget *w, GdkEvent *e, gpointer d) { \ + (void) w; (void) e; (void) d; \ + if (xs_ ## MV ) { \ + gtk_widget_destroy(xs_ ## MV ); \ + xs_ ## MV = NULL; \ + } \ + return FALSE; \ +} + +#define XS_DEF_WINDOW_CLOSE(ME, MV) \ +void xs_ ## ME (GtkButton *b, gpointer d) { \ + (void) b; (void) d; \ + gtk_widget_destroy(xs_ ## MV ); \ + xs_ ## MV = NULL; \ +} + + #ifdef __cplusplus } #endif