aboutsummaryrefslogtreecommitdiffstats
path: root/composer
diff options
context:
space:
mode:
Diffstat (limited to 'composer')
-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;