aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog6
-rw-r--r--mail/component-factory.c52
2 files changed, 12 insertions, 46 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 046f5b27c0..4e9b3bfabc 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,9 @@
+2002-07-15 Not Zed <NotZed@Ximian.com>
+
+ * component-factory.c (populate_folder_context_menu): Oops,
+ accidentally checked in some unfinished, unworking code.
+ Reverted.
+
2002-07-10 Not Zed <NotZed@Ximian.com>
** fixes for #10781
diff --git a/mail/component-factory.c b/mail/component-factory.c
index 6c677c1874..7fe2a4e8a1 100644
--- a/mail/component-factory.c
+++ b/mail/component-factory.c
@@ -385,16 +385,11 @@ xfer_folder (EvolutionShellComponent *shell_component,
camel_url_free(dst);
}
-static char *configure_folder_uri;
-static FolderBrowser *configure_folder_browser;
-
static void
configure_folder_popup(BonoboUIComponent *component, void *user_data, const char *cname)
{
char *uri = user_data;
- return;
-
vfolder_edit_rule(uri);
}
@@ -411,55 +406,20 @@ populate_folder_context_menu (EvolutionShellComponent *shell_component,
static char popup_xml[] =
"<menuitem name=\"ChangeFolderPropertiesPopUp\" verb=\"ChangeFolderPropertiesPopUp\""
" _label=\"Properties...\" _tip=\"Change this folder's properties\"/>";
- static int setup = FALSE;
- int add;
-
- if (!setup) {
- setup = TRUE;
- bonobo_ui_component_set_translate (uic, EVOLUTION_SHELL_COMPONENT_POPUP_PLACEHOLDER, popup_xml, NULL);
- bonobo_ui_component_add_verb_full(uic, "ChangeFolderPropertiesPopUp", configure_folder_popup, NULL, NULL);
- }
-
- if (strncmp(physical_uri, "file:", 5) == 0) {
- add = folder_browser_factory_get_browser(physical_uri) != NULL;
- } else if ((strncmp(physical_uri, "vfolder:", 8) == 0
- && strstr(physical_uri, "#" CAMEL_UNMATCHED_NAME) == NULL)) {
- add = TRUE;
- } else {
- add = FALSE;
- }
-
- printf("popup!!! url = '%s' add = %s\n", physical_uri, add?"TRUE":"FALSE");
-
- bonobo_ui_component_set_prop(uic, EVOLUTION_SHELL_COMPONENT_POPUP_PLACEHOLDER "/ChangeFolderPropertiesPopUp", "sensitive", add?"1":"0", NULL);
-#if 0
-
- { static int shit = 0;
- shit++;
- }
+ if (strcmp (type, "mail") != 0)
+ return;
/* FIXME: handle other types */
/* the unmatched test is a bit of a hack but it works */
- if (strncmp(physical_uri, "file:", 5) == 0) {
- FolderBrowser *fb = folder_browser_factory_get_browser(physical_uri);
- if (fb) {
- printf("folderbrowser = %s\n", fb->uri);
- gtk_object_ref((GtkObject *)fb);
- bonobo_ui_component_add_verb_full(uic, "ChangeFolderPropertiesPopUp", configure_folder, fb, gtk_object_unref);
- } else
- return;
- } else if ((strncmp(physical_uri, "vfolder:", 8) == 0
- && strstr(physical_uri, "#" CAMEL_UNMATCHED_NAME) == NULL)) {
- bonobo_ui_component_add_verb_full(uic, "ChangeFolderPropertiesPopUp", configure_folder_popup, g_strdup(physical_uri), g_free);
- } else {
- printf("doing nothing\n");
+ if (strncmp(physical_uri, "vfolder:", 8) != 0
+ || strstr(physical_uri, "#" CAMEL_UNMATCHED_NAME) != NULL)
return;
- }
+
+ bonobo_ui_component_add_verb_full(uic, "ChangeFolderPropertiesPopUp", configure_folder_popup, g_strdup(physical_uri), g_free);
bonobo_ui_component_set_translate (uic, EVOLUTION_SHELL_COMPONENT_POPUP_PLACEHOLDER, popup_xml, NULL);
-#endif
}
static char *