aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2002-05-07 04:41:42 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2002-05-07 04:41:42 +0800
commitbf8e5274dd9eb28db28f7542b838b3c1e46d206f (patch)
tree4f83a705be8e896564c3defd5d8f022a613b6b90 /mail
parent3ba5507ba7793f6a6ecc6fbaaa3f580eede963f5 (diff)
downloadgsoc2013-evolution-bf8e5274dd9eb28db28f7542b838b3c1e46d206f.tar
gsoc2013-evolution-bf8e5274dd9eb28db28f7542b838b3c1e46d206f.tar.gz
gsoc2013-evolution-bf8e5274dd9eb28db28f7542b838b3c1e46d206f.tar.bz2
gsoc2013-evolution-bf8e5274dd9eb28db28f7542b838b3c1e46d206f.tar.lz
gsoc2013-evolution-bf8e5274dd9eb28db28f7542b838b3c1e46d206f.tar.xz
gsoc2013-evolution-bf8e5274dd9eb28db28f7542b838b3c1e46d206f.tar.zst
gsoc2013-evolution-bf8e5274dd9eb28db28f7542b838b3c1e46d206f.zip
If we are in a Sent/Drafts/Outbox folder, don't show the "Add Sender to
2002-05-06 Jeffrey Stedfast <fejj@ximian.com> * folder-browser.c (on_right_click): If we are in a Sent/Drafts/Outbox folder, don't show the "Add Sender to Addressbook" menu item. svn path=/trunk/; revision=16692
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog6
-rw-r--r--mail/folder-browser.c21
2 files changed, 23 insertions, 4 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index de821302a1..a21bd6d22a 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,9 @@
+2002-05-06 Jeffrey Stedfast <fejj@ximian.com>
+
+ * folder-browser.c (on_right_click): If we are in a
+ Sent/Drafts/Outbox folder, don't show the "Add Sender to
+ Addressbook" menu item.
+
2002-05-06 Not Zed <NotZed@Ximian.com>
* component-factory.c (idle_quit): Check all threads are idle as
diff --git a/mail/folder-browser.c b/mail/folder-browser.c
index 3cd965bd77..beae739c3c 100644
--- a/mail/folder-browser.c
+++ b/mail/folder-browser.c
@@ -1570,7 +1570,8 @@ enum {
CAN_MARK_UNIMPORTANT = 1<<9,
CAN_FLAG_FOR_FOLLOWUP = 1<<10,
CAN_FLAG_COMPLETED = 1<<11,
- CAN_CLEAR_FLAG = 1<<12
+ CAN_CLEAR_FLAG = 1<<12,
+ CAN_ADD_SENDER = 1<<13
};
#define MLIST_VFOLDER (3)
@@ -1645,9 +1646,9 @@ static EPopupMenu context_menu[] = {
E_POPUP_SEPARATOR,
- E_POPUP_ITEM (N_("Add Sender to Address_book"), GTK_SIGNAL_FUNC (addrbook_sender), SELECTION_SET),
+ E_POPUP_ITEM (N_("Add Sender to Address_book"), GTK_SIGNAL_FUNC (addrbook_sender), SELECTION_SET | CAN_ADD_SENDER),
- E_POPUP_SEPARATOR,
+ E_POPUP_SEPARATOR,
E_POPUP_ITEM (N_("Appl_y Filters"), GTK_SIGNAL_FUNC (apply_filters), 0),
@@ -1759,7 +1760,6 @@ colour_closures_free (GPtrArray *closures)
static int
on_right_click (ETree *tree, gint row, ETreePath path, gint col, GdkEvent *event, FolderBrowser *fb)
{
- extern CamelFolder *sent_folder;
CamelMessageInfo *info;
GPtrArray *uids, *closures;
int enable_mask = 0;
@@ -1772,6 +1772,19 @@ on_right_click (ETree *tree, gint row, ETreePath path, gint col, GdkEvent *event
if (!folder_browser_is_sent (fb)) {
enable_mask |= CAN_RESEND;
hide_mask |= CAN_RESEND;
+ } else {
+ enable_mask |= CAN_ADD_SENDER;
+ hide_mask |= CAN_ADD_SENDER;
+ }
+
+ if (folder_browser_is_drafts (fb)) {
+ enable_mask |= CAN_ADD_SENDER;
+ hide_mask |= CAN_ADD_SENDER;
+ }
+
+ if (fb->folder == outbox_folder) {
+ enable_mask |= CAN_ADD_SENDER;
+ hide_mask |= CAN_ADD_SENDER;
}
enable_mask |= SELECTION_SET;