[Xfce4-commits] <postler:master> Show recipient only if it isn't unique

Christian Dywan noreply at xfce.org
Sat Jan 22 02:38:02 CET 2011


Updating branch refs/heads/master
         to 9ceb220f9b46100a981eb53a78617f6404f05d4b (commit)
       from 98f99e882b0d9306da1247c5b3ea4c625132ff24 (commit)

commit 9ceb220f9b46100a981eb53a78617f6404f05d4b
Author: Christian Dywan <christian at twotoasts.de>
Date:   Sat Jan 22 02:32:11 2011 +0100

    Show recipient only if it isn't unique
    
    Fixes: https://bugs.launchpad.net/postler/+bug/705725

 postler/postler-content.vala |   10 ++++++++--
 1 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/postler/postler-content.vala b/postler/postler-content.vala
index 1fa7a3f..3943b73 100644
--- a/postler/postler-content.vala
+++ b/postler/postler-content.vala
@@ -707,8 +707,14 @@ public class Postler.Content : WebKit.WebView {
             if (chosen_from != null)
                 arguments += "?from=" + html_escape (chosen_from);
             sender = linkify_address (from, arguments);
-            if (recipient != "")
-                recipient = linkify_address (recipient, arguments);
+            if (recipient != "") {
+                /* Show recipient only if isn't unique */
+                if ("," in recipient || "," in selected_account.address
+                                     || !recipient.contains (selected_account.address))
+                    recipient = linkify_address (recipient, arguments);
+                else
+                    recipient = "";
+            }
             if (carbon_copy != "")
                 carbon_copy = linkify_address (carbon_copy, arguments);
             if (reply != "")



More information about the Xfce4-commits mailing list