[prev in list] [next in list] [prev in thread] [next in thread] 

List:       sylpheed
Subject:    [sylpheed:25806] Re: Sent from and sorting questions
From:       Sebastian =?ISO-8859-15?Q?K=E4rgel?= <mailing () wodkahexe ! de>
Date:       2005-09-27 7:30:38
Message-ID: 20050927113040.cdd10607.mailing () wodkahexe ! de
[Download RAW message or body]

On Tue, 27 Sep 2005 14:10:53 +0900
Hiroyuki Yamamoto <hiro-y@kcn.ne.jp> wrote:

> Hello,
> 
> On Mon, 26 Sep 2005 12:05:30 -0400
> Bill <Bill@explosivo.com> wrote:
> 
> >  1) Sent mail will not show who I sent it too...  Well, in some cases
> > it will.  I have four different accounts and the "show recipients name
> > if from is my name" only seems to work on the first one in my list.
> > So most the mail I cannot see who it was too.
> 
> It will be solved in the future.
> 

Hello,

attached is a patch, which walks trough all accounts and prepends '-->' if the account-email is the same as the sender.

["sylpheed-2.1.2-send-from-1.patch" (application/octet-stream)]

--- sylpheed-2.1.2/src/summaryview.c	2005-09-14 11:45:28.000000000 +0200
+++ sylpheed-2.1.2-patched/src/summaryview.c	2005-09-27 11:25:06.000000000 +0200
@@ -1811,14 +1811,17 @@
 	const gchar *date_s;
 	gchar *sw_from_s = NULL;
 	gchar *subject_s = NULL;
-	GdkPixbuf *mark_pix = NULL;
+	GdkPixbuf *mark_pix = NULL;    
 	GdkPixbuf *unread_pix = NULL;
 	GdkPixbuf *mime_pix = NULL;
 	GdkColor *foreground = NULL;
 	gboolean use_bold = FALSE;
 	MsgFlags flags;
 	GdkColor color;
-	gint color_val;
+    	gint color_val;
+	GList *cur = NULL;
+	PrefsAccount *ac = NULL;
+	GList *al = NULL;
 
 	if (!msginfo) {
 		GET_MSG_INFO(msginfo, iter);
@@ -1833,14 +1836,23 @@
 		date_s = msginfo->date;
 	else
 		date_s = _("(No Date)");
-	if (prefs_common.swap_from && msginfo->from && msginfo->to &&
-	    cur_account && cur_account->address) {
-		gchar *from;
-
-		Xstrdup_a(from, msginfo->from, return);
-		extract_address(from);
-		if (!strcmp(from, cur_account->address))
-			sw_from_s = g_strconcat("-->", msginfo->to, NULL);
+	if (prefs_common.swap_from && msginfo->from && msginfo->to) {
+        gchar *from;
+
+        Xstrdup_a(from, msginfo->from, return);
+        extract_address(from);
+
+        al = account_get_list();
+
+        for (cur = al; cur != NULL; cur = cur->next) {
+            ac = (PrefsAccount *)cur->data;
+            if (ac->address) {
+                if (!strcmp(from, ac->address)) {
+                    sw_from_s = g_strconcat("-->", msginfo->to, NULL);
+                    break;
+                }
+            }
+        }        
 	}
 
 	if (msginfo->subject) {


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic