aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mail/ChangeLog3
-rw-r--r--mail/mail-component.c19
2 files changed, 21 insertions, 1 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 81dfff224a..e7edfcf811 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -3,6 +3,9 @@
* mail-component.c (view_changed_cb): display selected count
instead of unread if we have >1 selected. Also don't do special
case drafts/sent/outbox stuff if folders are inbox or re-used.
+ (view_control_activate_cb): force check of autosaved messages as
+ soon as the mailer starts up (well, after a delay, this seems
+ wrong). #57093.
2004-04-21 Not Zed <NotZed@Ximian.com>
diff --git a/mail/mail-component.c b/mail/mail-component.c
index 0d83da9112..05ca8cfb5a 100644
--- a/mail/mail-component.c
+++ b/mail/mail-component.c
@@ -365,11 +365,20 @@ get_prop(BonoboPropertyBag *bag, BonoboArg *arg, guint arg_id, CORBA_Environment
}
}
+static int
+check_autosave(void *data)
+{
+ e_msg_composer_check_autosave(NULL);
+
+ return FALSE;
+}
+
static void
view_control_activate_cb (BonoboControl *control, gboolean activate, EMFolderView *view)
{
BonoboUIComponent *uic;
-
+ static int recover = 0;
+
uic = bonobo_control_get_ui_component (control);
g_assert (uic != NULL);
@@ -389,6 +398,14 @@ view_control_activate_cb (BonoboControl *control, gboolean activate, EMFolderVie
em_folder_view_activate (view, uic, activate);
bonobo_ui_component_unset_container (uic, NULL);
}
+
+ /* This is a weird place to put it, but createControls does it too early.
+ I also think we should wait to do it until we actually visit the mailer.
+ The delay is arbitrary - without it it shows up before the main window */
+ if (!recover) {
+ recover = 1;
+ g_timeout_add(1000, check_autosave, NULL);
+ }
}
/* GObject methods. */