# HG changeset patch # User giacomo # Date 1143755265 28800 # Node ID 9eaff2f6cd4bb1e034784f795b7f8cfaf8e0807b # Parent 83a1c839662540729a1909e2e96fb5f6d16be480 [svn] prevent libconsole aboutbox from spawning multiple times diff -r 83a1c8396625 -r 9eaff2f6cd4b Plugins/Input/console/Audacious_Driver.cpp --- a/Plugins/Input/console/Audacious_Driver.cpp Wed Mar 29 23:22:58 2006 -0800 +++ b/Plugins/Input/console/Audacious_Driver.cpp Thu Mar 30 13:47:45 2006 -0800 @@ -667,13 +667,20 @@ extern "C" void console_aboutbox(void) { - xmms_show_message(_("About the Console Music Decoder"), - _("Console music decoder engine based on Game_Music_Emu 0.3.0.\n" - "Audacious implementation by: William Pitcock , \n" - // Please do not put my hotpop.com address in the clear (I hate spam) - " Shay Green "), - _("Ok"), - FALSE, NULL, NULL); + static GtkWidget * aboutbox = NULL; + + if (!aboutbox) + { + aboutbox = xmms_show_message(_("About the Console Music Decoder"), + _("Console music decoder engine based on Game_Music_Emu 0.3.0.\n" + "Audacious implementation by: William Pitcock , \n" + // Please do not put my hotpop.com address in the clear (I hate spam) + " Shay Green "), + _("Ok"), + FALSE, NULL, NULL); + gtk_signal_connect(GTK_OBJECT(aboutbox), "destroy", + (GCallback)gtk_widget_destroyed, &aboutbox); + } } InputPlugin console_ip =