summaryrefslogtreecommitdiff
authoreilers <eilers>2002-12-09 15:08:30 (UTC)
committer eilers <eilers>2002-12-09 15:08:30 (UTC)
commite487238141c57df63252e41a47b409cbb1f9ae83 (patch) (side-by-side diff)
tree6b98869056d5444d65432f3ba313a46273387118
parent9aa7570be3c5417314f5c865344b948a90450b48 (diff)
downloadopie-e487238141c57df63252e41a47b409cbb1f9ae83.zip
opie-e487238141c57df63252e41a47b409cbb1f9ae83.tar.gz
opie-e487238141c57df63252e41a47b409cbb1f9ae83.tar.bz2
Added preview for default email and all email
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--libopie/pim/ocontact.cpp8
-rw-r--r--libopie2/opiepim/ocontact.cpp8
2 files changed, 12 insertions, 4 deletions
diff --git a/libopie/pim/ocontact.cpp b/libopie/pim/ocontact.cpp
index efa2777..6aec62e 100644
--- a/libopie/pim/ocontact.cpp
+++ b/libopie/pim/ocontact.cpp
@@ -501,11 +501,15 @@ QString OContact::toRichText() const
text += Qtopia::escapeString(value) + "<br>";
// the others...
QString str;
+ QString defEmail = defaultEmail();
+ if ( !defEmail.isEmpty() )
+ text += "<b>" + QObject::tr("Default Email: ") + "</b>"
+ + Qtopia::escapeString(defEmail) + "<br>";
str = emails();
- if ( !str.isEmpty() )
- text += "<b>" + QObject::tr("Email Addresses: ") + "</b>"
+ if ( !str.isEmpty() && ( str != defEmail ) )
+ text += "<b>" + QObject::tr("All Emails: ") + "</b>"
+ Qtopia::escapeString(str) + "<br>";
str = homePhone();
if ( !str.isEmpty() )
text += "<b>" + QObject::tr("Home Phone: ") + "</b>"
diff --git a/libopie2/opiepim/ocontact.cpp b/libopie2/opiepim/ocontact.cpp
index efa2777..6aec62e 100644
--- a/libopie2/opiepim/ocontact.cpp
+++ b/libopie2/opiepim/ocontact.cpp
@@ -501,11 +501,15 @@ QString OContact::toRichText() const
text += Qtopia::escapeString(value) + "<br>";
// the others...
QString str;
+ QString defEmail = defaultEmail();
+ if ( !defEmail.isEmpty() )
+ text += "<b>" + QObject::tr("Default Email: ") + "</b>"
+ + Qtopia::escapeString(defEmail) + "<br>";
str = emails();
- if ( !str.isEmpty() )
- text += "<b>" + QObject::tr("Email Addresses: ") + "</b>"
+ if ( !str.isEmpty() && ( str != defEmail ) )
+ text += "<b>" + QObject::tr("All Emails: ") + "</b>"
+ Qtopia::escapeString(str) + "<br>";
str = homePhone();
if ( !str.isEmpty() )
text += "<b>" + QObject::tr("Home Phone: ") + "</b>"