aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Winship <danw@src.gnome.org>2002-03-08 03:23:44 +0800
committerDan Winship <danw@src.gnome.org>2002-03-08 03:23:44 +0800
commit17fd352c3b2ccbc9dcfc9d199e7363fe40cd379f (patch)
tree75ef407a74103389c3b8b3546cf5311c55160de3
parentd6f174ad5110ce2b86f5a4eb45d658b13735b26d (diff)
downloadgsoc2013-evolution-17fd352c3b2ccbc9dcfc9d199e7363fe40cd379f.tar
gsoc2013-evolution-17fd352c3b2ccbc9dcfc9d199e7363fe40cd379f.tar.gz
gsoc2013-evolution-17fd352c3b2ccbc9dcfc9d199e7363fe40cd379f.tar.bz2
gsoc2013-evolution-17fd352c3b2ccbc9dcfc9d199e7363fe40cd379f.tar.lz
gsoc2013-evolution-17fd352c3b2ccbc9dcfc9d199e7363fe40cd379f.tar.xz
gsoc2013-evolution-17fd352c3b2ccbc9dcfc9d199e7363fe40cd379f.tar.zst
gsoc2013-evolution-17fd352c3b2ccbc9dcfc9d199e7363fe40cd379f.zip
Addendum to previous commit: Remove "storage_selected" vs
"folder_selected" distinction. * evolution-storage-set-view.c (storage_set_view_widget_storage_selected_cb): Removed. * evolution-storage-set-view-listener.c (impl_GNOME_Evolution_StorageSetViewListener_notifyStorageSelected): Removed. (class_init): Remove STORAGE_SELECTED signal. * e-storage-set-view.c (impl_cursor_activated): Always emit FOLDER_SELECTED, never STORAGE_SELECTED. (class_init): Remove STORAGE_SELECTED signal. * e-shell-view.c (storage_selected_cb): Removed. * e-shell-folder-creation-dialog.c (storage_set_view_storage_selected_cb): Removed. * Evolution-StorageSetView.idl (StorageSetViewListener): Remove notifyStorageSelected. svn path=/trunk/; revision=15968
-rw-r--r--shell/ChangeLog25
-rw-r--r--shell/Evolution-StorageSetView.idl1
-rw-r--r--shell/e-shell-folder-creation-dialog.c15
-rw-r--r--shell/e-shell-view.c19
-rw-r--r--shell/e-storage-set-view.c21
-rw-r--r--shell/e-storage-set-view.h2
-rw-r--r--shell/evolution-storage-set-view-listener.c22
-rw-r--r--shell/evolution-storage-set-view-listener.h2
-rw-r--r--shell/evolution-storage-set-view.c29
9 files changed, 27 insertions, 109 deletions
diff --git a/shell/ChangeLog b/shell/ChangeLog
index 4b4ff3691a..0d47a6fffa 100644
--- a/shell/ChangeLog
+++ b/shell/ChangeLog
@@ -1,5 +1,30 @@
2002-03-07 Dan Winship <danw@ximian.com>
+ Addendum to previous commit: Remove "storage_selected" vs
+ "folder_selected" distinction.
+
+ * evolution-storage-set-view.c
+ (storage_set_view_widget_storage_selected_cb): Removed.
+
+ * evolution-storage-set-view-listener.c
+ (impl_GNOME_Evolution_StorageSetViewListener_notifyStorageSelected):
+ Removed.
+ (class_init): Remove STORAGE_SELECTED signal.
+
+ * e-storage-set-view.c (impl_cursor_activated): Always emit
+ FOLDER_SELECTED, never STORAGE_SELECTED.
+ (class_init): Remove STORAGE_SELECTED signal.
+
+ * e-shell-view.c (storage_selected_cb): Removed.
+
+ * e-shell-folder-creation-dialog.c
+ (storage_set_view_storage_selected_cb): Removed.
+
+ * Evolution-StorageSetView.idl (StorageSetViewListener): Remove
+ notifyStorageSelected.
+
+2002-03-07 Dan Winship <danw@ximian.com>
+
Make storages-with-toplevel-views less of a hack.
* e-folder-tree.c (e_folder_tree_add): Allow the caller to "add" a
diff --git a/shell/Evolution-StorageSetView.idl b/shell/Evolution-StorageSetView.idl
index c9222c3d62..cdf2cbe61c 100644
--- a/shell/Evolution-StorageSetView.idl
+++ b/shell/Evolution-StorageSetView.idl
@@ -14,7 +14,6 @@ module GNOME {
module Evolution {
interface StorageSetViewListener {
void notifyFolderSelected (in string uri);
- void notifyStorageSelected (in string name);
};
/* FIXME: Maybe we should have a generic Bonobo::Listener interface. */
diff --git a/shell/e-shell-folder-creation-dialog.c b/shell/e-shell-folder-creation-dialog.c
index dbbdcdfd74..7b9b5ab4de 100644
--- a/shell/e-shell-folder-creation-dialog.c
+++ b/shell/e-shell-folder-creation-dialog.c
@@ -262,19 +262,6 @@ storage_set_view_folder_selected_cb (EStorageSetView *storage_set_view,
gnome_dialog_set_sensitive (GNOME_DIALOG (dialog_data->dialog), 0, TRUE);
}
-static void
-storage_set_view_storage_selected_cb (EStorageSetView *storage_set_view,
- const char *name,
- void *data)
-{
- DialogData *dialog_data;
-
- dialog_data = (DialogData *) data;
-
- if (GTK_ENTRY (dialog_data->folder_name_entry)->text_length > 0)
- gnome_dialog_set_sensitive (GNOME_DIALOG (dialog_data->dialog), 0, TRUE);
-}
-
/* Shell signal callbacks. */
@@ -549,8 +536,6 @@ e_shell_show_folder_creation_dialog (EShell *shell,
gtk_signal_connect (GTK_OBJECT (dialog_data->storage_set_view), "folder_selected",
storage_set_view_folder_selected_cb, dialog_data);
- gtk_signal_connect (GTK_OBJECT (dialog_data->storage_set_view), "storage_selected",
- storage_set_view_storage_selected_cb, dialog_data);
gtk_signal_connect_while_alive (GTK_OBJECT (shell), "destroy",
GTK_SIGNAL_FUNC (shell_destroy_cb), dialog_data,
diff --git a/shell/e-shell-view.c b/shell/e-shell-view.c
index f822dfc228..cfd3bf6239 100644
--- a/shell/e-shell-view.c
+++ b/shell/e-shell-view.c
@@ -873,23 +873,6 @@ folder_selected_cb (EStorageSetView *storage_set_view,
switch_on_folder_tree_click (shell_view, path);
}
-/* Callback called when a storage in the tree view is clicked. */
-static void
-storage_selected_cb (EStorageSetView *storage_set_view,
- const char *name,
- void *data)
-{
- EShellView *shell_view;
- char *path;
-
- shell_view = E_SHELL_VIEW (data);
-
- path = g_strconcat (G_DIR_SEPARATOR_S, name, NULL);
- switch_on_folder_tree_click (shell_view, path);
-
- g_free (path);
-}
-
/* Callbacks for the folder context menu in the folder bar. */
static void
@@ -1029,8 +1012,6 @@ setup_storage_set_subwindow (EShellView *shell_view)
priv->ui_container);
gtk_signal_connect (GTK_OBJECT (storage_set_view), "folder_selected",
GTK_SIGNAL_FUNC (folder_selected_cb), shell_view);
- gtk_signal_connect (GTK_OBJECT (storage_set_view), "storage_selected",
- GTK_SIGNAL_FUNC (storage_selected_cb), shell_view);
gtk_signal_connect (GTK_OBJECT (storage_set_view), "folder_context_menu_popping_up",
GTK_SIGNAL_FUNC (folder_context_menu_popping_up_cb), shell_view);
gtk_signal_connect (GTK_OBJECT (storage_set_view), "folder_context_menu_popped_down",
diff --git a/shell/e-storage-set-view.c b/shell/e-storage-set-view.c
index 1c91ae6231..f3e8335ef5 100644
--- a/shell/e-storage-set-view.c
+++ b/shell/e-storage-set-view.c
@@ -101,7 +101,6 @@ struct _EStorageSetViewPrivate {
enum {
FOLDER_SELECTED,
- STORAGE_SELECTED,
DND_ACTION,
FOLDER_CONTEXT_MENU_POPPING_UP,
FOLDER_CONTEXT_MENU_POPPED_DOWN,
@@ -1332,15 +1331,8 @@ impl_cursor_activated (ETree *tree,
if (path) {
priv->selected_row_path = g_strdup (e_tree_memory_node_get_data (E_TREE_MEMORY (priv->etree_model), path));
- if (e_tree_model_node_depth (priv->etree_model, path) >= 2) {
- /* it was a folder */
- gtk_signal_emit (GTK_OBJECT (storage_set_view), signals[FOLDER_SELECTED],
- priv->selected_row_path);
- } else {
- /* it was a storage */
- gtk_signal_emit (GTK_OBJECT (storage_set_view), signals[STORAGE_SELECTED],
- priv->selected_row_path + 1);
- }
+ gtk_signal_emit (GTK_OBJECT (storage_set_view), signals[FOLDER_SELECTED],
+ priv->selected_row_path);
}
else
priv->selected_row_path = NULL;
@@ -1738,15 +1730,6 @@ class_init (EStorageSetViewClass *klass)
GTK_TYPE_NONE, 1,
GTK_TYPE_STRING);
- signals[STORAGE_SELECTED]
- = gtk_signal_new ("storage_selected",
- GTK_RUN_FIRST,
- object_class->type,
- GTK_SIGNAL_OFFSET (EStorageSetViewClass, storage_selected),
- gtk_marshal_NONE__STRING,
- GTK_TYPE_NONE, 1,
- GTK_TYPE_STRING);
-
signals[DND_ACTION]
= gtk_signal_new ("dnd_action",
GTK_RUN_FIRST,
diff --git a/shell/e-storage-set-view.h b/shell/e-storage-set-view.h
index 3468feff12..c6152b1bd8 100644
--- a/shell/e-storage-set-view.h
+++ b/shell/e-storage-set-view.h
@@ -56,8 +56,6 @@ struct _EStorageSetViewClass {
void (* folder_selected) (EStorageSetView *storage_set_view,
const char *path);
- void (* storage_selected) (EStorageSetView *storage_set_view,
- const char *name);
void (* dnd_action) (EStorageSetView *storage_set_view,
GdkDragContext *context,
diff --git a/shell/evolution-storage-set-view-listener.c b/shell/evolution-storage-set-view-listener.c
index 69dd778ec5..28841f72d4 100644
--- a/shell/evolution-storage-set-view-listener.c
+++ b/shell/evolution-storage-set-view-listener.c
@@ -41,7 +41,6 @@ struct _EvolutionStorageSetViewListenerPrivate {
enum {
FOLDER_SELECTED,
- STORAGE_SELECTED,
LAST_SIGNAL
};
static guint signals[LAST_SIGNAL] = { 0 };
@@ -72,18 +71,6 @@ impl_GNOME_Evolution_StorageSetViewListener_notifyFolderSelected (PortableServer
gtk_signal_emit (GTK_OBJECT (listener), signals[FOLDER_SELECTED], uri);
}
-static void
-impl_GNOME_Evolution_StorageSetViewListener_notifyStorageSelected (PortableServer_Servant servant,
- const CORBA_char *uri,
- CORBA_Environment *ev)
-{
- EvolutionStorageSetViewListener *listener;
-
- listener = gtk_object_from_servant (servant);
-
- gtk_signal_emit (GTK_OBJECT (listener), signals[STORAGE_SELECTED], uri);
-}
-
static EvolutionStorageSetViewListenerServant *
create_servant (EvolutionStorageSetViewListener *listener)
{
@@ -183,7 +170,6 @@ corba_class_init (void)
epv = g_new0 (POA_GNOME_Evolution_StorageSetViewListener__epv, 1);
epv->notifyFolderSelected = impl_GNOME_Evolution_StorageSetViewListener_notifyFolderSelected;
- epv->notifyStorageSelected = impl_GNOME_Evolution_StorageSetViewListener_notifyStorageSelected;
vepv = & my_GNOME_Evolution_StorageSetViewListener_vepv;
vepv->_base_epv = base_epv;
@@ -208,14 +194,6 @@ class_init (EvolutionStorageSetViewListenerClass *klass)
GTK_TYPE_NONE, 1,
GTK_TYPE_STRING);
- signals[STORAGE_SELECTED] = gtk_signal_new ("storage_selected",
- GTK_RUN_FIRST,
- object_class->type,
- GTK_SIGNAL_OFFSET (EvolutionStorageSetViewListenerClass, storage_selected),
- gtk_marshal_NONE__STRING,
- GTK_TYPE_NONE, 1,
- GTK_TYPE_STRING);
-
gtk_object_class_add_signals (object_class, signals, LAST_SIGNAL);
corba_class_init ();
diff --git a/shell/evolution-storage-set-view-listener.h b/shell/evolution-storage-set-view-listener.h
index 2176a859eb..c95778ee7e 100644
--- a/shell/evolution-storage-set-view-listener.h
+++ b/shell/evolution-storage-set-view-listener.h
@@ -54,8 +54,6 @@ struct _EvolutionStorageSetViewListenerClass {
void (* folder_selected) (EvolutionStorageSetViewListener *listener,
const char *uri);
- void (* storage_selected) (EvolutionStorageSetViewListener *listener,
- const char *uri);
};
diff --git a/shell/evolution-storage-set-view.c b/shell/evolution-storage-set-view.c
index ad5f0101dc..ae644df7cd 100644
--- a/shell/evolution-storage-set-view.c
+++ b/shell/evolution-storage-set-view.c
@@ -66,33 +66,6 @@ storage_set_view_widget_folder_selected_cb (EStorageSetView *storage_set_view_wi
}
}
-static void
-storage_set_view_widget_storage_selected_cb (EStorageSetView *storage_set_view_widget,
- const char *name,
- void *data)
-{
- EvolutionStorageSetView *storage_set_view;
- EvolutionStorageSetViewPrivate *priv;
- GList *p;
-
- storage_set_view = EVOLUTION_STORAGE_SET_VIEW (data);
- priv = storage_set_view->priv;
-
- for (p = priv->listeners; p != NULL; p = p->next) {
- CORBA_Environment ev;
- GNOME_Evolution_StorageSetViewListener listener;
-
- CORBA_exception_init (&ev);
-
- listener = (GNOME_Evolution_StorageSetViewListener) p->data;
- GNOME_Evolution_StorageSetViewListener_notifyStorageSelected (listener, name, &ev);
-
- /* FIXME: What if we fail? */
-
- CORBA_exception_free (&ev);
- }
-}
-
/* Listener handling. */
@@ -371,8 +344,6 @@ evolution_storage_set_view_construct (EvolutionStorageSetView *storage_set_view,
gtk_signal_connect (GTK_OBJECT (priv->storage_set_view_widget), "folder_selected",
GTK_SIGNAL_FUNC (storage_set_view_widget_folder_selected_cb), storage_set_view);
- gtk_signal_connect (GTK_OBJECT (priv->storage_set_view_widget), "storage_selected",
- GTK_SIGNAL_FUNC (storage_set_view_widget_storage_selected_cb), storage_set_view);
}
EvolutionStorageSetView *