aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog11
-rw-r--r--mail/component-factory.c15
-rw-r--r--mail/folder-browser.c4
3 files changed, 14 insertions, 16 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 81f3c104f4..6539dc7221 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,14 @@
+2000-07-10 Ettore Perazzoli <ettore@helixcode.com>
+
+ * component-factory.c: Removed variable `browsers'.
+ (create_view): Don't update it.
+ (owner_unset_cb): Don't sync the folders here anymore, because at
+ this point the folder browser is dead already so we cannot get a
+ valid list of folders from it anymore.
+
+ * folder-browser.c (folder_browser_destroy): Sync the associated
+ mailbox first.
+
2000-07-10 Christopher James Lahey <clahey@helixcode.com>
* message-list.c, message-list.h: Switched from ETable to
diff --git a/mail/component-factory.c b/mail/component-factory.c
index 1237b1f638..b9c0b7d480 100644
--- a/mail/component-factory.c
+++ b/mail/component-factory.c
@@ -61,8 +61,6 @@ static const EvolutionShellComponentFolderType folder_types[] = {
{ NULL, NULL }
};
-static GList *browsers;
-
/* GROSS HACK: for passing to other parts of the program */
EvolutionShellClient *global_shell_client = NULL;
@@ -90,8 +88,6 @@ create_view (EvolutionShellComponent *shell_component,
g_assert (folder_browser_widget != NULL);
g_assert (IS_FOLDER_BROWSER (folder_browser_widget));
- browsers = g_list_prepend (browsers, folder_browser_widget);
-
/* dum de dum, hack to let the folder browser know the storage its in */
gtk_object_set_data (GTK_OBJECT (folder_browser_widget), "e-storage",
gtk_object_get_data(GTK_OBJECT (shell_component), "e-storage"));
@@ -163,17 +159,6 @@ owner_set_cb (EvolutionShellComponent *shell_component,
static void
owner_unset_cb (EvolutionShellComponent *shell_component, gpointer user_data)
{
- FolderBrowser *fb;
-
- /* Sync each open folder. We should do more cleanup than this,
- * but then, we shouldn't be just exiting here either. FIXME.
- */
- while (browsers) {
- fb = browsers->data;
- camel_folder_sync (fb->folder, FALSE, NULL);
- browsers = browsers->next;
- }
-
gtk_main_quit ();
}
diff --git a/mail/folder-browser.c b/mail/folder-browser.c
index f4ec07f9ff..201a7d9252 100644
--- a/mail/folder-browser.c
+++ b/mail/folder-browser.c
@@ -25,7 +25,9 @@ static void
folder_browser_destroy (GtkObject *object)
{
FolderBrowser *folder_browser = FOLDER_BROWSER (object);
-
+
+ camel_folder_sync (folder_browser->folder, FALSE, NULL);
+
if (folder_browser->shell) {
CORBA_Environment ev;