aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2002-08-01 11:54:13 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2002-08-01 11:54:13 +0800
commit70c9d1ce6afba17ffc1ae583ef40656959967b22 (patch)
tree93ab4fac38e432ad5204fcfc2fa4a59c85d25825 /mail
parent99c51c5a8cc66694ca5f65f27ae8d1fc7b067c29 (diff)
downloadgsoc2013-evolution-70c9d1ce6afba17ffc1ae583ef40656959967b22.tar
gsoc2013-evolution-70c9d1ce6afba17ffc1ae583ef40656959967b22.tar.gz
gsoc2013-evolution-70c9d1ce6afba17ffc1ae583ef40656959967b22.tar.bz2
gsoc2013-evolution-70c9d1ce6afba17ffc1ae583ef40656959967b22.tar.lz
gsoc2013-evolution-70c9d1ce6afba17ffc1ae583ef40656959967b22.tar.xz
gsoc2013-evolution-70c9d1ce6afba17ffc1ae583ef40656959967b22.tar.zst
gsoc2013-evolution-70c9d1ce6afba17ffc1ae583ef40656959967b22.zip
Removed folder-browser-window from the build.
2002-07-31 Jeffrey Stedfast <fejj@ximian.com> * Makefile.am: Removed folder-browser-window from the build. * folder-browser-window.[c,h]: Removed. * mail-callbacks.c (view_digest): Removed. * mail-display.c (mail_display_digest_clicked): Removed. (on_link_clicked): Don't handle digest: urls anymore. svn path=/trunk/; revision=17666
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog11
-rw-r--r--mail/Makefile.am2
-rw-r--r--mail/folder-browser-window.c150
-rw-r--r--mail/folder-browser-window.h65
-rw-r--r--mail/mail-callbacks.c60
-rw-r--r--mail/mail-display.c30
6 files changed, 11 insertions, 307 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 160ed5bc1f..5349753c8c 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,14 @@
+2002-07-31 Jeffrey Stedfast <fejj@ximian.com>
+
+ * Makefile.am: Removed folder-browser-window from the build.
+
+ * folder-browser-window.[c,h]: Removed.
+
+ * mail-callbacks.c (view_digest): Removed.
+
+ * mail-display.c (mail_display_digest_clicked): Removed.
+ (on_link_clicked): Don't handle digest: urls anymore.
+
2002-07-31 Ettore Perazzoli <ettore@ximian.com>
* component-factory.c (create_component): Put "New Mail Message"
diff --git a/mail/Makefile.am b/mail/Makefile.am
index 4d480345a1..b6cf8b5c57 100644
--- a/mail/Makefile.am
+++ b/mail/Makefile.am
@@ -63,8 +63,6 @@ evolution_mail_SOURCES = \
folder-browser-factory.h \
folder-browser-ui.c \
folder-browser-ui.h \
- folder-browser-window.c \
- folder-browser-window.h \
folder-info.c \
folder-info.h \
mail-accounts.c \
diff --git a/mail/folder-browser-window.c b/mail/folder-browser-window.c
deleted file mode 100644
index 4de61937f6..0000000000
--- a/mail/folder-browser-window.c
+++ /dev/null
@@ -1,150 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Authors: Jeffrey Stedfast <fejj@ximian.com>
- *
- * Copyright 2002 Ximian, Inc. (www.ximian.com)
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Street #330, Boston, MA 02111-1307, USA.
- *
- */
-
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <bonobo/bonobo-exception.h>
-#include <bonobo/bonobo-ui-component.h>
-#include <bonobo/bonobo-ui-container.h>
-#include <bonobo/bonobo-ui-util.h>
-
-#include <gal/util/e-util.h>
-
-#include "folder-browser-window.h"
-
-#include "folder-browser-ui.h"
-
-
-#define MINIMUM_WIDTH 600
-#define MINIMUM_HEIGHT 400
-
-#define PARENT_TYPE (bonobo_window_get_type ())
-
-static BonoboWindowClass *folder_browser_window_parent_class = NULL;
-
-static GtkAllocation last_allocation = { 0, 0 };
-
-static void
-folder_browser_window_destroy (GtkObject *object)
-{
- FolderBrowserWindow *folder_browser_window;
-
- folder_browser_window = FOLDER_BROWSER_WINDOW (object);
-
- if (folder_browser_window->folder_browser) {
- gtk_widget_destroy (GTK_WIDGET (folder_browser_window->folder_browser));
- folder_browser_window->folder_browser = NULL;
- }
-
- if (GTK_OBJECT_CLASS (folder_browser_window_parent_class)->destroy)
- (GTK_OBJECT_CLASS (folder_browser_window_parent_class)->destroy) (object);
-}
-
-static void
-folder_browser_window_class_init (GtkObjectClass *object_class)
-{
- object_class->destroy = folder_browser_window_destroy;
-
- folder_browser_window_parent_class = gtk_type_class (PARENT_TYPE);
-}
-
-static void
-folder_browser_window_init (GtkObject *object)
-{
- ;
-}
-
-static void
-folder_browser_window_size_allocate_cb (GtkWidget *widget, GtkAllocation *allocation)
-{
- last_allocation = *allocation;
-}
-
-static void
-set_default_size (GtkWidget *widget)
-{
- int width, height;
-
- width = MAX (MINIMUM_WIDTH, last_allocation.width);
- height = MAX (MINIMUM_HEIGHT, last_allocation.height);
-
- gtk_window_set_default_size (GTK_WINDOW (widget), width, height);
-}
-
-static void
-fb_window_close (BonoboUIComponent *uih, gpointer user, const char *path)
-{
- gtk_widget_destroy (GTK_WIDGET (user));
-}
-
-static BonoboUIVerb
-verbs[] = {
- BONOBO_UI_VERB ("MessageBrowserClose", fb_window_close),
- BONOBO_UI_VERB_END
-};
-
-GtkWidget *
-folder_browser_window_new (FolderBrowser *fb)
-{
- FolderBrowserWindow *new;
- BonoboUIContainer *uicont;
- BonoboUIComponent *uic;
-
- g_return_val_if_fail (IS_FOLDER_BROWSER (fb), NULL);
-
- new = gtk_type_new (FOLDER_BROWSER_WINDOW_TYPE);
- new = (FolderBrowserWindow *) bonobo_window_construct (BONOBO_WINDOW (new), "Ximian Evolution", "");
- if (!new)
- return NULL;
-
- set_default_size (GTK_WIDGET (new));
-
- new->folder_browser = fb;
- bonobo_window_set_contents (BONOBO_WINDOW (new), GTK_WIDGET (fb));
-
- uicont = bonobo_ui_container_new ();
- bonobo_ui_container_set_win (uicont, BONOBO_WINDOW (new));
-
- uic = bonobo_ui_component_new_default ();
- bonobo_ui_component_set_container (uic, BONOBO_OBJREF (uicont));
- bonobo_ui_component_add_verb_list_with_data (uic, verbs, new);
-
- folder_browser_set_ui_component (FOLDER_BROWSER (fb), uic);
-
- /* ok, not quite the UI the message display was intended for, but close enough */
- bonobo_ui_util_set_ui (uic, EVOLUTION_DATADIR, "evolution-mail-messagedisplay.xml", "evolution-mail");
-
- folder_browser_ui_add_list (fb);
- folder_browser_ui_add_message (fb);
-
- /*folder_browser_set_shell_view (fb, fb_get_svi (control));*/
-
- gtk_signal_connect (GTK_OBJECT (new), "size_allocate",
- GTK_SIGNAL_FUNC (folder_browser_window_size_allocate_cb), NULL);
-
- return GTK_WIDGET (new);
-}
-
-E_MAKE_TYPE (folder_browser_window, "FolderBrowserWindow", FolderBrowserWindow, folder_browser_window_class_init, folder_browser_window_init, PARENT_TYPE);
diff --git a/mail/folder-browser-window.h b/mail/folder-browser-window.h
deleted file mode 100644
index ee00be2236..0000000000
--- a/mail/folder-browser-window.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
-/*
- * Authors: Jeffrey Stedfast <fejj@ximian.com>
- *
- * Copyright 2002 Ximian, Inc. (www.ximian.com)
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Street #330, Boston, MA 02111-1307, USA.
- *
- */
-
-
-#ifndef __FOLDER_BROWSER_WINDOW_H__
-#define __FOLDER_BROWSER_WINDOW_H__
-
-#ifdef __cplusplus
-extern "C" {
-#pragma }
-#endif /* __cplusplus */
-
-#include <bonobo/bonobo-win.h>
-
-#include "folder-browser.h"
-
-#define FOLDER_BROWSER_WINDOW_TYPE (folder_browser_window_get_type ())
-#define FOLDER_BROWSER_WINDOW(o) (GTK_CHECK_CAST ((o), FOLDER_BROWSER_WINDOW_TYPE, FolderBrowserWindow))
-#define FOLDER_BROWSER_WINDOW_CLASS(k) (GTK_CHECK_CLASS_CAST((k), FOLDER_BROWSER_WINDOW_TYPE, FolderBrowserWindowClass))
-#define IS_FOLDER_BROWSER_WINDOW(o) (GTK_CHECK_TYPE ((o), FOLDER_BROWSER_WINDOW_TYPE))
-#define IS_FOLDER_BROWSER_WINDOW_CLASS(k) (GTK_CHECK_CLASS_TYPE ((k), FOLDER_BROWSER_WINDOW_TYPE))
-
-typedef struct _FolderBrowserWindowClass FolderBrowserWindowClass;
-typedef struct _FolderBrowserWindow FolderBrowserWindow;
-
-struct _FolderBrowserWindow {
- BonoboWindow parent;
-
- GtkWidget *fb_parent;
- FolderBrowser *folder_browser;
-};
-
-struct _FolderBrowserWindowClass {
- BonoboWindowClass parent_class;
-
-};
-
-GtkType folder_browser_window_get_type (void);
-
-GtkWidget *folder_browser_window_new (FolderBrowser *fb);
-
-#ifdef __cplusplus
-}
-#endif /* __cplusplus */
-
-#endif /* __FOLDER_BROWSER_WINDOW_H__ */
diff --git a/mail/mail-callbacks.c b/mail/mail-callbacks.c
index 86f84ea739..ef3660fa43 100644
--- a/mail/mail-callbacks.c
+++ b/mail/mail-callbacks.c
@@ -46,7 +46,6 @@
#include <gtkhtml/gtkhtml.h>
#include "mail.h"
-#include "folder-browser-window.h"
#include "message-browser.h"
#include "mail-callbacks.h"
#include "mail-config.h"
@@ -3143,65 +3142,6 @@ configure_folder (BonoboUIComponent *uih, void *user_data, const char *path)
}
static void
-do_view_digest (CamelFolder *folder, const char *uid, CamelMimeMessage *message, void *data)
-{
- FolderBrowser *folder_browser = FOLDER_BROWSER (data);
-
- if (FOLDER_BROWSER_IS_DESTROYED (folder_browser))
- return;
-
- if (message) {
- CamelFolder *digest;
- CamelStore *store;
- FolderBrowser *fb;
- GtkWidget *window;
-
- store = camel_digest_store_new ("digest:/");
-
- digest = camel_digest_folder_new (store, message);
- camel_object_unref (CAMEL_OBJECT (store));
- if (!digest)
- return;
-
- camel_folder_set_message_flags (folder, uid, CAMEL_MESSAGE_SEEN, CAMEL_MESSAGE_SEEN);
-
- fb = (FolderBrowser *) folder_browser_new (folder_browser->shell, NULL);
- message_list_set_hidedeleted(fb->message_list, 0);
- folder_browser_set_message_preview (fb, TRUE);
- folder_browser_set_folder (fb, digest, "digest:/");
- camel_object_unref (CAMEL_OBJECT (digest));
- gtk_widget_show (GTK_WIDGET (fb));
-
- window = folder_browser_window_new (fb);
- gtk_widget_show (window);
- }
-}
-
-void
-view_digest (GtkWidget *widget, gpointer user_data)
-{
- FolderBrowser *fb = FOLDER_BROWSER (user_data);
- GPtrArray *uids;
- int i;
-
- if (FOLDER_BROWSER_IS_DESTROYED (fb))
- return;
-
- uids = g_ptr_array_new ();
- message_list_foreach (fb->message_list, enumerate_msg, uids);
-
- if (uids->len > 10 && !are_you_sure (_("Are you sure you want to open all %d messages in separate windows?"), uids, fb))
- return;
-
- /* FIXME: use mail_get_messages() */
- for (i = 0; i < uids->len; i++) {
- mail_get_message (fb->folder, uids->pdata [i], do_view_digest, fb, mail_thread_queued);
- g_free (uids->pdata [i]);
- }
- g_ptr_array_free (uids, TRUE);
-}
-
-static void
do_view_message (CamelFolder *folder, const char *uid, CamelMimeMessage *message, void *data)
{
FolderBrowser *fb = FOLDER_BROWSER (data);
diff --git a/mail/mail-display.c b/mail/mail-display.c
index 528bb07fe4..e2aa411744 100644
--- a/mail/mail-display.c
+++ b/mail/mail-display.c
@@ -50,7 +50,6 @@
#include "folder-browser-factory.h"
#include "mail-stream-gtkhtml.h"
#include "message-tag-followup.h"
-#include "folder-browser-window.h"
#include "folder-browser.h"
#include "mail-display.h"
#include "mail-config.h"
@@ -277,41 +276,12 @@ mail_display_jump_to_anchor (MailDisplay *md, const char *url)
}
static void
-mail_display_digest_clicked (MailDisplay *md, const char *url)
-{
- FolderBrowser *fb, *parent_fb;
- CamelFolder *digest;
- CamelStore *store;
- GtkWidget *window;
-
- parent_fb = (FolderBrowser *) gtk_widget_get_ancestor (GTK_WIDGET (md), FOLDER_BROWSER_TYPE);
-
- store = camel_digest_store_new (url);
-
- digest = camel_digest_folder_new (store, md->current_message);
- camel_object_unref (CAMEL_OBJECT (store));
- if (!digest)
- return;
-
- fb = (FolderBrowser *) folder_browser_new (parent_fb->shell, NULL);
- folder_browser_set_message_preview (fb, TRUE);
- folder_browser_set_folder (fb, digest, url);
- camel_object_unref (CAMEL_OBJECT (digest));
- gtk_widget_show (GTK_WIDGET (fb));
-
- window = folder_browser_window_new (fb);
- gtk_widget_show (window);
-}
-
-static void
on_link_clicked (GtkHTML *html, const char *url, MailDisplay *md)
{
if (!g_strncasecmp (url, "news:", 5) || !g_strncasecmp (url, "nntp:", 5)) {
g_warning ("Can't handle news URLs yet.");
} else if (!g_strncasecmp (url, "mailto:", 7)) {
send_to_url (url);
- } else if (!g_strncasecmp (url, "digest:", 7)) {
- mail_display_digest_clicked (md, url);
} else if (*url == '#') {
mail_display_jump_to_anchor (md, url);
} else {