aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--shell/ChangeLog16
-rw-r--r--shell/Evolution-Storage.idl5
-rw-r--r--shell/e-storage.c30
-rw-r--r--shell/e-storage.h53
-rw-r--r--shell/evolution-storage.c12
5 files changed, 99 insertions, 17 deletions
diff --git a/shell/ChangeLog b/shell/ChangeLog
index aa64a3df09..978a6c211e 100644
--- a/shell/ChangeLog
+++ b/shell/ChangeLog
@@ -1,5 +1,21 @@
2001-03-22 Ettore Perazzoli <ettore@ximian.com>
+ * e-storage.c (e_storage_async_xfer_folder): New.
+ (impl_async_xfer_folder): New, default implementation for the
+ `async_xfer_folder' method.
+ (class_init): Install it.
+
+ * e-storage.h: New virtual method `async_xfer_folder'.
+
+ * evolution-storage.c (impl_Storage_async_xfer_folder): New. Just
+ a stub for now.
+ (evolution_storage_get_epv): Install it as the implementation for
+ the `asyncXferFolder' method.
+
+ * Evolution-Storage.idl: New method `asyncXferFolder'.
+
+2001-03-22 Ettore Perazzoli <ettore@ximian.com>
+
* e-storage-set-view.c: Removed `source_drag_types',
`num_source_drag_types', `destination_drag_types',
`num_destination_drag_types', `target_list'.
diff --git a/shell/Evolution-Storage.idl b/shell/Evolution-Storage.idl
index c0216e3ddd..9681d32be1 100644
--- a/shell/Evolution-Storage.idl
+++ b/shell/Evolution-Storage.idl
@@ -57,6 +57,11 @@ module Evolution {
in string physical_uri,
in Bonobo::Listener listener);
+ void asyncXferFolder (in string source_path,
+ in string destination_path,
+ in boolean remove_source,
+ in Bonobo::Listener listener);
+
void addListener (in StorageListener listener)
raises (AlreadyListening);
diff --git a/shell/e-storage.c b/shell/e-storage.c
index e38c5e3fbf..f3c48fa97a 100644
--- a/shell/e-storage.c
+++ b/shell/e-storage.c
@@ -198,6 +198,17 @@ impl_async_remove_folder (EStorage *storage,
(* callback) (storage, E_STORAGE_NOTIMPLEMENTED, data);
}
+static void
+impl_async_xfer_folder (EStorage *storage,
+ const char *source_path,
+ const char *destination_path,
+ gboolean remove_source,
+ EStorageResultCallback callback,
+ void *data)
+{
+ (* callback) (storage, E_STORAGE_NOTIMPLEMENTED, data);
+}
+
/* Initialization. */
@@ -216,6 +227,7 @@ class_init (EStorageClass *class)
class->get_name = impl_get_name;
class->async_create_folder = impl_async_create_folder;
class->async_remove_folder = impl_async_remove_folder;
+ class->async_xfer_folder = impl_async_xfer_folder;
signals[NEW_FOLDER] =
gtk_signal_new ("new_folder",
@@ -420,6 +432,24 @@ e_storage_async_remove_folder (EStorage *storage,
(* ES_CLASS (storage)->async_remove_folder) (storage, path, callback, data);
}
+void
+e_storage_async_xfer_folder (EStorage *storage,
+ const char *source_path,
+ const char *destination_path,
+ const gboolean remove_source,
+ EStorageResultCallback callback,
+ void *data)
+{
+ g_return_if_fail (storage != NULL);
+ g_return_if_fail (E_IS_STORAGE (storage));
+ g_return_if_fail (source_path != NULL);
+ g_return_if_fail (g_path_is_absolute (source_path));
+ g_return_if_fail (destination_path != NULL);
+ g_return_if_fail (g_path_is_absolute (destination_path));
+
+ (* ES_CLASS (storage)->async_xfer_folder) (storage, source_path, destination_path, remove_source, callback, data);
+}
+
const char *
e_storage_result_to_string (EStorageResult result)
diff --git a/shell/e-storage.h b/shell/e-storage.h
index a6716d7262..5a986a5b1a 100644
--- a/shell/e-storage.h
+++ b/shell/e-storage.h
@@ -84,11 +84,24 @@ struct _EStorageClass {
EFolder * (* get_folder) (EStorage *storage, const char *path);
const char * (* get_name) (EStorage *storage);
- void (* async_create_folder) (EStorage *storage, const char *path,
- const char *type, const char *description,
- EStorageResultCallback callback, void *data);
- void (* async_remove_folder) (EStorage *storage, const char *path,
- EStorageResultCallback callback, void *data);
+ void (* async_create_folder) (EStorage *storage,
+ const char *path,
+ const char *type,
+ const char *description,
+ EStorageResultCallback callback,
+ void *data);
+
+ void (* async_remove_folder) (EStorage *storage,
+ const char *path,
+ EStorageResultCallback callback,
+ void *data);
+
+ void (* async_xfer_folder) (EStorage *storage,
+ const char *source_path,
+ const char *destination_path,
+ const gboolean remove_source,
+ EStorageResultCallback callback,
+ void *data);
};
@@ -113,18 +126,24 @@ const char *e_storage_get_toplevel_node_type (EStorage *storage);
/* Folder operations. */
-void e_storage_async_create_folder (EStorage *storage,
- const char *path,
- const char *type,
- const char *description,
- EStorageResultCallback callback,
- void *data);
-void e_storage_async_remove_folder (EStorage *storage,
- const char *path,
- EStorageResultCallback callback,
- void *data);
-
-const char *e_storage_result_to_string (EStorageResult result);
+void e_storage_async_create_folder (EStorage *storage,
+ const char *path,
+ const char *type,
+ const char *description,
+ EStorageResultCallback callback,
+ void *data);
+void e_storage_async_remove_folder (EStorage *storage,
+ const char *path,
+ EStorageResultCallback callback,
+ void *data);
+void e_storage_async_xfer_folder (EStorage *storage,
+ const char *source_path,
+ const char *destination_path,
+ const gboolean remove_source,
+ EStorageResultCallback callback,
+ void *data);
+
+const char *e_storage_result_to_string (EStorageResult result);
/* Utility functions. */
diff --git a/shell/evolution-storage.c b/shell/evolution-storage.c
index c3ffad319c..fd9bbc11d0 100644
--- a/shell/evolution-storage.c
+++ b/shell/evolution-storage.c
@@ -323,6 +323,17 @@ impl_Storage_async_remove_folder (PortableServer_Servant servant,
}
static void
+impl_Storage_async_xfer_folder (PortableServer_Servant servant,
+ const CORBA_char *source_path,
+ const CORBA_char *destination_path,
+ const CORBA_boolean remove_source,
+ const Bonobo_Listener listener,
+ CORBA_Environment *ev)
+{
+ g_print ("FIXME: impl_Storage_async_xfer_folder -- implement me!\n");
+}
+
+static void
impl_Storage_add_listener (PortableServer_Servant servant,
const GNOME_Evolution_StorageListener listener,
CORBA_Environment *ev)
@@ -510,6 +521,7 @@ evolution_storage_get_epv (void)
epv->_get_name = impl_Storage__get_name;
epv->asyncCreateFolder = impl_Storage_async_create_folder;
epv->asyncRemoveFolder = impl_Storage_async_remove_folder;
+ epv->asyncXferFolder = impl_Storage_async_xfer_folder;
epv->addListener = impl_Storage_add_listener;
epv->removeListener = impl_Storage_remove_listener;