diff src/aim.c @ 4082:4b04ecb3eb97

[gaim-migrate @ 4297] (22:54:38) Robot101: * Make sure prefs are saved before plugins are removed, and not afterwards. (22:54:59) Robot101: * Move do_quit() into aim.c and make sure everything appropriate uses it. (22:55:12) Robot101: * Remove duplicated cancel_login for closing the main window, use do_quit instead. (22:55:49) Robot101: * Remove uncalled code pertaining to closing the about window from when it was called via gaim -v. (22:56:06) LSchiere: what's this in sounds? (22:56:29) Robot101: * Add correct ifdefs to prefs so only compiled-in sound methods are shown. (22:56:34) LSchiere: if you broke my sounds... (22:57:07) Robot101: * Remove unused sound order data, and clarify comments and debug output. (22:57:56) Robot101: * Remove duplicated check which is performed at the start of play_file anyway. (22:58:03) Robot101: that's the lot committer: Tailor Script <tailor@pidgin.im>
author Luke Schierer <lschiere@pidgin.im>
date Mon, 16 Dec 2002 03:58:54 +0000
parents 3ccbdf8e7f8d
children 9c31ddae80a1
line wrap: on
line diff
--- a/src/aim.c	Mon Dec 16 00:19:44 2002 +0000
+++ b/src/aim.c	Mon Dec 16 03:58:54 2002 +0000
@@ -101,22 +101,31 @@
 };
 #endif
 
-
-void cancel_logon(void)
+void do_quit()
 {
-#ifdef GAIM_PLUGINS
-	/* first we tell those who have requested it we're quitting */
+	/* captain's log, stardate... */
+	system_log(log_quit, NULL, NULL, OPT_LOG_BUDDY_SIGNON | OPT_LOG_MY_SIGNON);
+
+	/* the self destruct sequence has been initiated */
 	plugin_event(event_quit);
 
-	/* then we remove everyone in a mass suicide */
+	/* transmission ends */
+	signoff_all();
+
+	/* record what we have before we blow it away... */
+	save_prefs();
+
+#ifdef GAIM_PLUGINS
+	/* jettison cargo */
 	remove_all_plugins();
-#endif /* GAIM_PLUGINS */
+#endif
+
 #ifdef USE_PERL
+	/* yup, perl too */
 	perl_end();
 #endif
 
-	save_prefs();
-
+	/* and end it all... */
 	gtk_main_quit();
 }
 
@@ -271,7 +280,7 @@
 	gdk_window_set_group(mainwindow->window, mainwindow->window);
 	gtk_container_set_border_width(GTK_CONTAINER(mainwindow), 5);
 	gtk_signal_connect(GTK_OBJECT(mainwindow), "delete_event", 
-					GTK_SIGNAL_FUNC(cancel_logon), mainwindow);
+					GTK_SIGNAL_FUNC(do_quit), mainwindow);
 
 
 	icon = gaim_pixbuf(NULL, "gaim.png");