summaryrefslogtreecommitdiff
authoreilers <eilers>2003-08-06 12:21:16 (UTC)
committer eilers <eilers>2003-08-06 12:21:16 (UTC)
commitba25812361114b7cf059a3a1fb3aed42f8a7ebde (patch) (unidiff)
treea3f2fa10c70a2e4697ae4298260b4f5da54750f0
parentf1d5295227f5f15ad5e2a9d180fdbce18568cb71 (diff)
downloadopie-ba25812361114b7cf059a3a1fb3aed42f8a7ebde.zip
opie-ba25812361114b7cf059a3a1fb3aed42f8a7ebde.tar.gz
opie-ba25812361114b7cf059a3a1fb3aed42f8a7ebde.tar.bz2
Cardview update: It is more compressed. Pending: Add pricture for work- and home address..
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--libopie/pim/ocontact.cpp18
-rw-r--r--libopie2/opiepim/ocontact.cpp18
2 files changed, 18 insertions, 18 deletions
diff --git a/libopie/pim/ocontact.cpp b/libopie/pim/ocontact.cpp
index 3473baa..e34feeb 100644
--- a/libopie/pim/ocontact.cpp
+++ b/libopie/pim/ocontact.cpp
@@ -469,37 +469,37 @@ QString OContact::toRichText() const
469 text += "<b><img src=\"addressbook/email\"> " + QObject::tr("Default Email: ") + "</b>" 469 text += "<b><img src=\"addressbook/email\"> " + QObject::tr("Default Email: ") + "</b>"
470 + Qtopia::escapeString(defEmail); 470 + Qtopia::escapeString(defEmail);
471 marker = true; 471 marker = true;
472 } 472 }
473 473
474 // business address 474 // business address
475 if ( !businessStreet().isEmpty() || !businessCity().isEmpty() || 475 if ( !businessStreet().isEmpty() || !businessCity().isEmpty() ||
476 !businessZip().isEmpty() || !businessCountry().isEmpty() ) { 476 !businessZip().isEmpty() || !businessCountry().isEmpty() ) {
477 text += QObject::tr( "<br><br><b>Work Address:</b>" ); 477 text += QObject::tr( "<br><b>Work Address:</b>" );
478 marker = true; 478 marker = true;
479 } 479 }
480 480
481 if ( !(value = businessStreet()).isEmpty() ){ 481 if ( !(value = businessStreet()).isEmpty() ){
482 text += "<br>" + Qtopia::escapeString(value); 482 text += "<br>" + Qtopia::escapeString(value);
483 marker = true; 483 marker = true;
484 } 484 }
485 485
486 switch( addressformat ){ 486 switch( addressformat ){
487 case Zip_City_State:{ // Zip_Code City, State 487 case Zip_City_State:{ // Zip_Code City, State
488 state = businessState(); 488 state = businessState();
489 if ( !(value = businessZip()).isEmpty() ){ 489 if ( !(value = businessZip()).isEmpty() ){
490 text += "<br>" + Qtopia::escapeString(value) + " "; 490 text += "<br>" + Qtopia::escapeString(value) + " ";
491 marker = true; 491 marker = true;
492 492
493 } else 493 }
494 text += "<br>";
495
496 if ( !(value = businessCity()).isEmpty() ) { 494 if ( !(value = businessCity()).isEmpty() ) {
497 marker = true; 495 marker = true;
496 if ( businessZip().isEmpty() && !businessStreet().isEmpty() )
497 text += "<br>";
498 text += Qtopia::escapeString(value); 498 text += Qtopia::escapeString(value);
499 if ( state ) 499 if ( state )
500 text += ", " + Qtopia::escapeString(state); 500 text += ", " + Qtopia::escapeString(state);
501 } else if ( !state.isEmpty() ){ 501 } else if ( !state.isEmpty() ){
502 text += "<br>" + Qtopia::escapeString(state); 502 text += "<br>" + Qtopia::escapeString(state);
503 marker = true; 503 marker = true;
504 } 504 }
505 break; 505 break;
@@ -561,41 +561,41 @@ QString OContact::toRichText() const
561 } 561 }
562 str = businessPager(); 562 str = businessPager();
563 if ( !str.isEmpty() ){ 563 if ( !str.isEmpty() ){
564 text += "<br><b>" + QObject::tr("Business Pager: ") + "</b>" 564 text += "<br><b>" + QObject::tr("Business Pager: ") + "</b>"
565 + Qtopia::escapeString(str); 565 + Qtopia::escapeString(str);
566 marker = true; 566 marker = true;
567 } 567 }
568 568
569 text += "<br>"; 569 // text += "<br>";
570 570
571 // home address 571 // home address
572 if ( !homeStreet().isEmpty() || !homeCity().isEmpty() || 572 if ( !homeStreet().isEmpty() || !homeCity().isEmpty() ||
573 !homeZip().isEmpty() || !homeCountry().isEmpty() ) { 573 !homeZip().isEmpty() || !homeCountry().isEmpty() ) {
574 text += QObject::tr( "<br><br><b>Home Address:</b>" ); 574 text += QObject::tr( "<br><b>Home Address:</b>" );
575 marker = true; 575 marker = true;
576 } 576 }
577 577
578 if ( !(value = homeStreet()).isEmpty() ){ 578 if ( !(value = homeStreet()).isEmpty() ){
579 text += "<br>" + Qtopia::escapeString(value); 579 text += "<br>" + Qtopia::escapeString(value);
580 marker = true; 580 marker = true;
581 } 581 }
582 582
583 switch( addressformat ){ 583 switch( addressformat ){
584 case Zip_City_State:{ // Zip_Code City, State 584 case Zip_City_State:{ // Zip_Code City, State
585 state = homeState(); 585 state = homeState();
586 if ( !(value = homeZip()).isEmpty() ){ 586 if ( !(value = homeZip()).isEmpty() ){
587 text += "<br>" + Qtopia::escapeString(value) + " "; 587 text += "<br>" + Qtopia::escapeString(value) + " ";
588 marker = true; 588 marker = true;
589 } else 589 }
590 text += "<br>";
591
592 if ( !(value = homeCity()).isEmpty() ) { 590 if ( !(value = homeCity()).isEmpty() ) {
593 marker = true; 591 marker = true;
592 if ( homeZip().isEmpty() && !homeStreet().isEmpty() )
593 text += "<br>";
594 text += Qtopia::escapeString(value); 594 text += Qtopia::escapeString(value);
595 if ( !state.isEmpty() ) 595 if ( !state.isEmpty() )
596 text += ", " + Qtopia::escapeString(state); 596 text += ", " + Qtopia::escapeString(state);
597 } else if (!state.isEmpty()) { 597 } else if (!state.isEmpty()) {
598 text += "<br>" + Qtopia::escapeString(state); 598 text += "<br>" + Qtopia::escapeString(state);
599 marker = true; 599 marker = true;
600 } 600 }
601 break; 601 break;
diff --git a/libopie2/opiepim/ocontact.cpp b/libopie2/opiepim/ocontact.cpp
index 3473baa..e34feeb 100644
--- a/libopie2/opiepim/ocontact.cpp
+++ b/libopie2/opiepim/ocontact.cpp
@@ -469,37 +469,37 @@ QString OContact::toRichText() const
469 text += "<b><img src=\"addressbook/email\"> " + QObject::tr("Default Email: ") + "</b>" 469 text += "<b><img src=\"addressbook/email\"> " + QObject::tr("Default Email: ") + "</b>"
470 + Qtopia::escapeString(defEmail); 470 + Qtopia::escapeString(defEmail);
471 marker = true; 471 marker = true;
472 } 472 }
473 473
474 // business address 474 // business address
475 if ( !businessStreet().isEmpty() || !businessCity().isEmpty() || 475 if ( !businessStreet().isEmpty() || !businessCity().isEmpty() ||
476 !businessZip().isEmpty() || !businessCountry().isEmpty() ) { 476 !businessZip().isEmpty() || !businessCountry().isEmpty() ) {
477 text += QObject::tr( "<br><br><b>Work Address:</b>" ); 477 text += QObject::tr( "<br><b>Work Address:</b>" );
478 marker = true; 478 marker = true;
479 } 479 }
480 480
481 if ( !(value = businessStreet()).isEmpty() ){ 481 if ( !(value = businessStreet()).isEmpty() ){
482 text += "<br>" + Qtopia::escapeString(value); 482 text += "<br>" + Qtopia::escapeString(value);
483 marker = true; 483 marker = true;
484 } 484 }
485 485
486 switch( addressformat ){ 486 switch( addressformat ){
487 case Zip_City_State:{ // Zip_Code City, State 487 case Zip_City_State:{ // Zip_Code City, State
488 state = businessState(); 488 state = businessState();
489 if ( !(value = businessZip()).isEmpty() ){ 489 if ( !(value = businessZip()).isEmpty() ){
490 text += "<br>" + Qtopia::escapeString(value) + " "; 490 text += "<br>" + Qtopia::escapeString(value) + " ";
491 marker = true; 491 marker = true;
492 492
493 } else 493 }
494 text += "<br>";
495
496 if ( !(value = businessCity()).isEmpty() ) { 494 if ( !(value = businessCity()).isEmpty() ) {
497 marker = true; 495 marker = true;
496 if ( businessZip().isEmpty() && !businessStreet().isEmpty() )
497 text += "<br>";
498 text += Qtopia::escapeString(value); 498 text += Qtopia::escapeString(value);
499 if ( state ) 499 if ( state )
500 text += ", " + Qtopia::escapeString(state); 500 text += ", " + Qtopia::escapeString(state);
501 } else if ( !state.isEmpty() ){ 501 } else if ( !state.isEmpty() ){
502 text += "<br>" + Qtopia::escapeString(state); 502 text += "<br>" + Qtopia::escapeString(state);
503 marker = true; 503 marker = true;
504 } 504 }
505 break; 505 break;
@@ -561,41 +561,41 @@ QString OContact::toRichText() const
561 } 561 }
562 str = businessPager(); 562 str = businessPager();
563 if ( !str.isEmpty() ){ 563 if ( !str.isEmpty() ){
564 text += "<br><b>" + QObject::tr("Business Pager: ") + "</b>" 564 text += "<br><b>" + QObject::tr("Business Pager: ") + "</b>"
565 + Qtopia::escapeString(str); 565 + Qtopia::escapeString(str);
566 marker = true; 566 marker = true;
567 } 567 }
568 568
569 text += "<br>"; 569 // text += "<br>";
570 570
571 // home address 571 // home address
572 if ( !homeStreet().isEmpty() || !homeCity().isEmpty() || 572 if ( !homeStreet().isEmpty() || !homeCity().isEmpty() ||
573 !homeZip().isEmpty() || !homeCountry().isEmpty() ) { 573 !homeZip().isEmpty() || !homeCountry().isEmpty() ) {
574 text += QObject::tr( "<br><br><b>Home Address:</b>" ); 574 text += QObject::tr( "<br><b>Home Address:</b>" );
575 marker = true; 575 marker = true;
576 } 576 }
577 577
578 if ( !(value = homeStreet()).isEmpty() ){ 578 if ( !(value = homeStreet()).isEmpty() ){
579 text += "<br>" + Qtopia::escapeString(value); 579 text += "<br>" + Qtopia::escapeString(value);
580 marker = true; 580 marker = true;
581 } 581 }
582 582
583 switch( addressformat ){ 583 switch( addressformat ){
584 case Zip_City_State:{ // Zip_Code City, State 584 case Zip_City_State:{ // Zip_Code City, State
585 state = homeState(); 585 state = homeState();
586 if ( !(value = homeZip()).isEmpty() ){ 586 if ( !(value = homeZip()).isEmpty() ){
587 text += "<br>" + Qtopia::escapeString(value) + " "; 587 text += "<br>" + Qtopia::escapeString(value) + " ";
588 marker = true; 588 marker = true;
589 } else 589 }
590 text += "<br>";
591
592 if ( !(value = homeCity()).isEmpty() ) { 590 if ( !(value = homeCity()).isEmpty() ) {
593 marker = true; 591 marker = true;
592 if ( homeZip().isEmpty() && !homeStreet().isEmpty() )
593 text += "<br>";
594 text += Qtopia::escapeString(value); 594 text += Qtopia::escapeString(value);
595 if ( !state.isEmpty() ) 595 if ( !state.isEmpty() )
596 text += ", " + Qtopia::escapeString(state); 596 text += ", " + Qtopia::escapeString(state);
597 } else if (!state.isEmpty()) { 597 } else if (!state.isEmpty()) {
598 text += "<br>" + Qtopia::escapeString(state); 598 text += "<br>" + Qtopia::escapeString(state);
599 marker = true; 599 marker = true;
600 } 600 }
601 break; 601 break;