aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Winship <danw@src.gnome.org>2001-07-09 23:22:24 +0800
committerDan Winship <danw@src.gnome.org>2001-07-09 23:22:24 +0800
commitfcda5ec759395e2a9d658ebcf3616943793a7a28 (patch)
treeeb97ec770c34f541cc3e60722e5ad2381d33916f
parent7fa7518bd69dab32b11b7fa53b8b4055873cc5bb (diff)
downloadgsoc2013-evolution-fcda5ec759395e2a9d658ebcf3616943793a7a28.tar.gz
gsoc2013-evolution-fcda5ec759395e2a9d658ebcf3616943793a7a28.tar.zst
gsoc2013-evolution-fcda5ec759395e2a9d658ebcf3616943793a7a28.zip
Do the autosave_manager_unregister at shutdown time instead of destroy
* e-msg-composer.c (composer_shutdown): Do the autosave_manager_unregister at shutdown time instead of destroy time (by which point the contents of the window, including the remote editor control, will have already been destroyed). svn path=/trunk/; revision=10913
-rw-r--r--composer/ChangeLog7
-rw-r--r--composer/e-msg-composer.c15
2 files changed, 20 insertions, 2 deletions
diff --git a/composer/ChangeLog b/composer/ChangeLog
index 754996d15a..b04027bf62 100644
--- a/composer/ChangeLog
+++ b/composer/ChangeLog
@@ -1,3 +1,10 @@
+2001-07-09 Dan Winship <danw@ximian.com>
+
+ * e-msg-composer.c (composer_shutdown): Do the
+ autosave_manager_unregister at shutdown time instead of destroy
+ time (by which point the contents of the window, including the
+ remote editor control, will have already been destroyed).
+
2001-07-09 Zbigniew Chyla <cyba@gnome.pl>
* e-msg-composer-select-file.c: Added missing #include <config.h> to
diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c
index 7447f9db0e..f84d237fc2 100644
--- a/composer/e-msg-composer.c
+++ b/composer/e-msg-composer.c
@@ -1881,6 +1881,18 @@ from_changed_cb (EMsgComposerHdrs *hdrs,
/* GtkObject methods. */
static void
+composer_shutdown (GtkObject *object)
+{
+ /* When destroy() is called, the contents of the window
+ * (including the remote editor control) will already have
+ * been destroyed, so we have to do this here.
+ */
+ autosave_manager_unregister (am, E_MSG_COMPOSER (object));
+ if (GTK_OBJECT_CLASS (parent_class)->shutdown != NULL)
+ (* GTK_OBJECT_CLASS (parent_class)->shutdown) (object);
+}
+
+static void
destroy (GtkObject *object)
{
EMsgComposer *composer;
@@ -1888,8 +1900,6 @@ destroy (GtkObject *object)
composer = E_MSG_COMPOSER (object);
- autosave_manager_unregister (am, composer);
-
CORBA_exception_init (&ev);
if (composer->config_db) {
@@ -2055,6 +2065,7 @@ class_init (EMsgComposerClass *klass)
object_class = GTK_OBJECT_CLASS (klass);
widget_class = GTK_WIDGET_CLASS (klass);
+ object_class->shutdown = composer_shutdown;
object_class->destroy = destroy;
widget_class->delete_event = delete_event;