(Implemented deleting folders in the shell. Files changed that aren't

(Implemented deleting folders in the shell.  Files changed that aren't
 noted below were simply small indentation/space changes.  To play
 with deleting folders, right click on a selected folder in the folder
 tree, then choose Delete.)

2001-06-23  Jason Leach  <jleach@ximian.com>

	* e-shell-folder-selection-dialog.c
	(e_shell_folder_selection_dialog_construct): Make the folder tree
	have a similar expanded state as the shell's folder tree.

	* e-local-storage.c (remove_folder): New function that does the
	meat of actual deletion stuff.
	(remove_folder_directory): A helper function that remove_folder()
	uses.
	(component_async_remove_folder_callback): A new callback to do the
	removing stuff from shell (if there weren't errors from the
	component).
	(impl_async_remove_folder): Implemented this.

	* evolution-shell-component-client.c
	(evolution_shell_component_client_async_remove_folder):
	Implemented this.

	* e-shell-view.c (e_shell_view_remove_control_for_uri): New
	function.

svn path=/trunk/; revision=10446
This commit is contained in:
Jason Leach
2001-06-23 18:58:02 +00:00
committed by Jacob Leach
parent 657ab7270a
commit 602fee638e
14 changed files with 404 additions and 51 deletions

View File

@ -655,7 +655,45 @@ evolution_shell_component_client_async_remove_folder (EvolutionShellComponentCli
EvolutionShellComponentClientCallback callback,
void *data)
{
/* FIXME to do. */
EvolutionShellComponentClientPrivate *priv;
GNOME_Evolution_ShellComponent corba_shell_component;
CORBA_Environment ev;
g_return_if_fail (shell_component_client != NULL);
g_return_if_fail (EVOLUTION_IS_SHELL_COMPONENT_CLIENT (shell_component_client));
g_return_if_fail (physical_uri != NULL);
g_return_if_fail (callback != NULL);
priv = shell_component_client->priv;
if (priv->callback != NULL) {
(* callback) (shell_component_client, EVOLUTION_SHELL_COMPONENT_BUSY, data);
return;
}
create_listener_interface (shell_component_client);
CORBA_exception_init (&ev);
corba_shell_component = bonobo_object_corba_objref (BONOBO_OBJECT (shell_component_client));
priv->callback = callback;
priv->callback_data = data;
GNOME_Evolution_ShellComponent_removeFolderAsync (corba_shell_component,
priv->listener_interface,
physical_uri,
&ev);
if (ev._major != CORBA_NO_EXCEPTION && priv->callback != NULL) {
(* callback) (shell_component_client,
shell_component_result_from_corba_exception (&ev),
data);
priv->callback = NULL;
priv->callback_data = NULL;
}
CORBA_exception_free (&ev);
}
void