aboutsummaryrefslogtreecommitdiffstats
path: root/mail/component-factory.c
diff options
context:
space:
mode:
authorDan Winship <danw@src.gnome.org>2001-05-10 06:01:42 +0800
committerDan Winship <danw@src.gnome.org>2001-05-10 06:01:42 +0800
commit72be879a2786d992936b8195b328dfca75b22919 (patch)
treedfe94a8ecaf416ebf13c3c109d9bbd3b4ad389be /mail/component-factory.c
parent630241d74b1a6dede97380c8ed70c74641399e0f (diff)
downloadgsoc2013-evolution-72be879a2786d992936b8195b328dfca75b22919.tar
gsoc2013-evolution-72be879a2786d992936b8195b328dfca75b22919.tar.gz
gsoc2013-evolution-72be879a2786d992936b8195b328dfca75b22919.tar.bz2
gsoc2013-evolution-72be879a2786d992936b8195b328dfca75b22919.tar.lz
gsoc2013-evolution-72be879a2786d992936b8195b328dfca75b22919.tar.xz
gsoc2013-evolution-72be879a2786d992936b8195b328dfca75b22919.tar.zst
gsoc2013-evolution-72be879a2786d992936b8195b328dfca75b22919.zip
New file, started by Ettore, finished by me, to implement the
* mail-offline-handler.c: New file, started by Ettore, finished by me, to implement the GNOME_Evolution_Offline interface. * Makefile.am (evolution_mail_SOURCES): Add mail-offline-handler.[ch] * mail-ops.c (mail_store_set_offline): Set a store online or offline. * mail-send-recv.c (auto_timeout): Don't run auto-check-for-mail while the session is offline. * component-factory.c (component_fn): Set up offline handler. svn path=/trunk/; revision=9739
Diffstat (limited to 'mail/component-factory.c')
-rw-r--r--mail/component-factory.c19
1 files changed, 18 insertions, 1 deletions
diff --git a/mail/component-factory.c b/mail/component-factory.c
index 759d7294f1..26796201a1 100644
--- a/mail/component-factory.c
+++ b/mail/component-factory.c
@@ -40,6 +40,7 @@
#include "mail-config.h"
#include "mail-tools.h"
#include "mail-ops.h"
+#include "mail-offline-handler.h"
#include "mail-local.h"
#include "mail-session.h"
#include "mail-mt.h"
@@ -287,12 +288,13 @@ static BonoboObject *
component_fn (BonoboGenericFactory *factory, void *closure)
{
EvolutionShellComponent *shell_component;
+ MailOfflineHandler *offline_handler;
shell_component = evolution_shell_component_new (folder_types,
create_view,
create_folder,
NULL, /* remove_folder_fn */
- NULL, /* copy_folder_fn */
+ NULL, /* xfer_folder_fn */
NULL, /* populate_folder_context_menu_fn */
NULL, /* get_dnd_selection_fn */
NULL);
@@ -306,6 +308,9 @@ component_fn (BonoboGenericFactory *factory, void *closure)
gtk_signal_connect (GTK_OBJECT (shell_component), "destroy",
GTK_SIGNAL_FUNC (owner_unset_cb), NULL);
+ offline_handler = mail_offline_handler_new ();
+ bonobo_object_add_interface (BONOBO_OBJECT (shell_component), BONOBO_OBJECT (offline_handler));
+
return BONOBO_OBJECT (shell_component);
}
@@ -510,3 +515,15 @@ mail_lookup_storage (CamelStore *store)
return storage;
}
+
+int
+mail_storages_count (void)
+{
+ return g_hash_table_size (storages_hash);
+}
+
+void
+mail_storages_foreach (GHFunc func, gpointer data)
+{
+ g_hash_table_foreach (storages_hash, func, data);
+}