author | eilers <eilers> | 2002-10-13 11:22:01 (UTC) |
---|---|---|
committer | eilers <eilers> | 2002-10-13 11:22:01 (UTC) |
commit | 5f9fb52583eb399c79a108b8e79c1a558a730422 (patch) (side-by-side diff) | |
tree | d578ce7167053003e1cc5c5e3821bd4ac26fe122 /core/pim/addressbook/contacteditor.cpp | |
parent | 1cbed80910293516879d9b9308ae36072033f70e (diff) | |
download | opie-5f9fb52583eb399c79a108b8e79c1a558a730422.zip opie-5f9fb52583eb399c79a108b8e79c1a558a730422.tar.gz opie-5f9fb52583eb399c79a108b8e79c1a558a730422.tar.bz2 |
First attempt to fix language translation bug. Comboboxes should now
work if translation is broken... Some translations should be reenabled
in next fix..
Diffstat (limited to 'core/pim/addressbook/contacteditor.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/pim/addressbook/contacteditor.cpp | 176 |
1 files changed, 89 insertions, 87 deletions
diff --git a/core/pim/addressbook/contacteditor.cpp b/core/pim/addressbook/contacteditor.cpp index 12d7421..b01583f 100644 --- a/core/pim/addressbook/contacteditor.cpp +++ b/core/pim/addressbook/contacteditor.cpp @@ -106,6 +106,6 @@ void ContactEditor::init() { for ( i = 0; it != slOrdered.end(); i++, ++it ) { - if ( (*it) == tr( "Business Fax" ) ) { - slChooserNames.append( *it ); + if ( (*it) == "Business Fax" ) { + slChooserNames.append( tr( "Business Fax" ) ); slChooserValues.append("" ); //slDynamicEntries->remove( it ); @@ -113,6 +113,6 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Home Fax" ) ) { - slChooserNames.append( *it ); + if ( (*it) == "Home Fax" ) { + slChooserNames.append( tr( "Home Fax" ) ); slChooserValues.append("" ); //slDynamicEntries->remove( it ); @@ -121,6 +121,6 @@ void ContactEditor::init() { - if ( (*it) == tr( "Business Phone" ) ) { - slChooserNames.append( *it ); + if ( (*it) == "Business Phone" ) { + slChooserNames.append( tr( "Business Phone" ) ); slChooserValues.append( "" ); //slDynamicEntries->remove( it ); @@ -128,6 +128,6 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Home Phone" ) ) { - slChooserNames.append( *it ); + if ( (*it) == "Home Phone" ) { + slChooserNames.append( tr( "Home Phone" ) ); slChooserValues.append( "" ); //slDynamicEntries->remove( it ); @@ -143,6 +143,6 @@ void ContactEditor::init() { } */ - if ( (*it) == tr( "Business Mobile" ) ) { - slChooserNames.append( *it ); + if ( (*it) == "Business Mobile" ) { + slChooserNames.append( tr( "Business Mobile" ) ); slChooserValues.append( "" ); //slDynamicEntries->remove( it ); @@ -150,6 +150,6 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Home Mobile" ) ) { - slChooserNames.append( *it ); + if ( (*it) == "Home Mobile" ) { + slChooserNames.append( tr( "Home Mobile" ) ); slChooserValues.append( "" ); //slDynamicEntries->remove( it ); @@ -158,6 +158,6 @@ void ContactEditor::init() { - if ( (*it) == tr( "Business WebPage" ) ) { - slChooserNames.append( *it ); + if ( (*it) == "Business WebPage" ) { + slChooserNames.append( tr( "Business WebPage" ) ); slChooserValues.append( "" ); //slDynamicEntries->remove( it ); @@ -165,6 +165,6 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Home Web Page" ) ) { - slChooserNames.append( *it ); + if ( (*it) == "Home Web Page" ) { + slChooserNames.append( tr( "Home Web Page" ) ); slChooserValues.append( "" ); //slDynamicEntries->remove( it ); @@ -172,6 +172,6 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Business Pager" ) ) { - slChooserNames.append( *it ); + if ( (*it) == "Business Pager" ) { + slChooserNames.append( tr( "Business Pager" ) ); slChooserValues.append( "" ); //slDynamicEntries->remove( it ); @@ -179,6 +179,6 @@ void ContactEditor::init() { } - if ( *it == tr( "Default Email" ) ) { - slChooserNames.append( *it ); + if ( *it == "Default Email" ) { + slChooserNames.append( tr( "Default Email" ) ); slChooserValues.append( "" ); //slDynamicEntries->remove( it ); @@ -186,6 +186,6 @@ void ContactEditor::init() { } - if ( *it == tr( "Emails" ) ) { - slChooserNames.append( *it ); + if ( *it == "Emails" ) { + slChooserNames.append( tr( "Emails" ) ); slChooserValues.append( "" ); //slDynamicEntries->remove( it ); @@ -196,35 +196,35 @@ void ContactEditor::init() { continue; - if ( *it == tr( "Name Title" ) ) { + if ( *it == "Name Title" ) { //slDynamicEntries->remove( it ); continue; } - if ( *it == tr( "First Name" ) ) { + if ( *it == "First Name" ) { // slDynamicEntries->remove( it ); continue; } - if ( *it == tr( "Middle Name" ) ) { + if ( *it == "Middle Name" ) { // slDynamicEntries->remove( it ); continue; } - if ( *it == tr( "Last Name" ) ) { + if ( *it == "Last Name" ) { // slDynamicEntries->remove( it ); continue; } - if ( *it == tr( "Suffix" ) ) { + if ( *it == "Suffix" ) { // slDynamicEntries->remove( it ); continue; } - if ( *it == tr( "File As" ) ) { + if ( *it == "File As" ) { // slDynamicEntries->remove( it ); continue; } - if ( *it == tr( "Gender" ) ) { + if ( *it == "Gender" ) { hasGender = TRUE; // slDynamicEntries->remove( it ); @@ -232,5 +232,5 @@ void ContactEditor::init() { } - if ( *it == tr( "Job Title" ) ) { + if ( *it == "Job Title" ) { hasTitle = TRUE; // slDynamicEntries->remove( it ); @@ -238,5 +238,5 @@ void ContactEditor::init() { } - if ( *it == tr( "Company") || *it == tr( "Organization" ) ) { + if ( ( *it == "Company") || (*it == "Organization" ) ) { hasCompany = TRUE; // slDynamicEntries->remove( it ); @@ -244,5 +244,5 @@ void ContactEditor::init() { } - if ( *it == tr( "Notes" ) ) { + if ( *it == "Notes" ) { hasNotes = TRUE; // slDynamicEntries->remove( it ); @@ -250,10 +250,10 @@ void ContactEditor::init() { } - if ( *it == tr( "Groups" ) ) { + if ( *it == "Groups" ) { // slDynamicEntries->remove( it ); continue; } - if ( (*it) == tr( "Business Street" ) ) { + if ( (*it) == "Business Street" ) { hasStreet = TRUE; // slDynamicEntries->remove( it ); @@ -261,5 +261,5 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Home Street" ) ) { + if ( (*it) == "Home Street" ) { hasStreet = TRUE; // slDynamicEntries->remove( it ); @@ -279,5 +279,5 @@ void ContactEditor::init() { } */ - if ( (*it) == tr( "Business City" ) ) { + if ( (*it) == "Business City" ) { hasCity = TRUE; // slDynamicEntries->remove( it ); @@ -285,5 +285,5 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Business State" ) ) { + if ( (*it) == "Business State" ) { hasState = TRUE; // slDynamicEntries->remove( it ); @@ -291,5 +291,5 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Business Zip" ) ) { + if ( (*it) == "Business Zip" ) { hasZip = TRUE; // slDynamicEntries->remove( it ); @@ -297,5 +297,5 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Business Country" ) ) { + if ( (*it) == "Business Country" ) { hasCountry = TRUE; // slDynamicEntries->remove( it ); @@ -303,5 +303,5 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Home City" ) ) { + if ( (*it) == "Home City" ) { hasCity = TRUE; // slDynamicEntries->remove( it ); @@ -309,5 +309,5 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Home State" ) ) { + if ( (*it) == "Home State" ) { hasState = TRUE; // slDynamicEntries->remove( it ); @@ -315,5 +315,5 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Home Zip" ) ) { + if ( (*it) == "Home Zip" ) { hasZip = TRUE; // slDynamicEntries->remove( it ); @@ -321,5 +321,5 @@ void ContactEditor::init() { } - if ( (*it) == tr( "Home Country" ) ) { + if ( (*it) == "Home Country" ) { hasCountry = TRUE; // slDynamicEntries->remove( it ); @@ -1361,35 +1361,35 @@ void ContactEditor::setEntry( const OContact &entry ) { QListIterator<QLineEdit> itLE( listValue ); for ( it = slDynamicEntries.begin(); it != slDynamicEntries.end(); ++it, ++itLE) { - if ( *it == tr("Department") ) + if ( *it =="Department" ) (*itLE)->setText( ent.department() ); - if ( *it == tr("Company" )) + if ( *it == "Company" ) (*itLE)->setText( ent.company() ); - if ( *it == tr("Office" )) + if ( *it == "Office" ) (*itLE)->setText( ent.office() ); - if ( *it == tr("Profession" )) + if ( *it == "Profession" ) (*itLE)->setText( ent.profession() ); - if ( *it == tr("Assistant" )) + if ( *it == "Assistant" ) (*itLE)->setText( ent.assistant() ); - if ( *it == tr("Manager" )) + if ( *it == "Manager" ) (*itLE)->setText( ent.manager() ); - if ( *it == tr("Spouse" )) + if ( *it == "Spouse" ) (*itLE)->setText( ent.spouse() ); - if ( *it == tr("Birthday" )) + if ( *it == "Birthday" ) (*itLE)->setText( ent.birthday() ); - if ( *it == tr("Anniversary" )) + if ( *it == "Anniversary" ) (*itLE)->setText( ent.anniversary() ); - if ( *it == tr("Nickname" )) + if ( *it == "Nickname" ) (*itLE)->setText( ent.nickname() ); - if ( *it == tr("Children" )) + if ( *it == "Children" ) (*itLE)->setText( ent.children() ); @@ -1399,5 +1399,5 @@ void ContactEditor::setEntry( const OContact &entry ) { for ( it = slChooserNames.begin(), itV = slChooserValues.begin(); it != slChooserNames.end(); ++it, ++itV ) { - if ( *it == tr("Business Phone") || *it == tr("Work Phone" )) + if ( ( *it == "Business Phone") || ( *it == "Work Phone" ) ) *itV = ent.businessPhone(); /* @@ -1405,8 +1405,8 @@ void ContactEditor::setEntry( const OContact &entry ) { *itV = ent.business2Phone(); */ - if ( *it == tr("Business Fax") || *it == tr("Work Fax" )) + if ( ( *it == "Business Fax") || ( *it == "Work Fax" ) ) *itV = ent.businessFax(); - if ( *it == tr("Business Mobile") || *it == tr("work Mobile" )) + if ( ( *it == "Business Mobile" ) || ( *it == "work Mobile" ) ) *itV = ent.businessMobile(); /* @@ -1414,11 +1414,11 @@ void ContactEditor::setEntry( const OContact &entry ) { *itV = ent.companyPhone(); */ - if ( *it == tr("Default Email" )) + if ( *it == "Default Email" ) *itV = ent.defaultEmail(); - if ( *it == tr("Emails" )) + if ( *it == "Emails" ) *itV = ent.emailList().join(", "); // :SX - if ( *it == tr("Home Phone" )) + if ( *it == "Home Phone" ) *itV = ent.homePhone(); /* @@ -1426,8 +1426,8 @@ void ContactEditor::setEntry( const OContact &entry ) { *itV = ent.home2Phone(); */ - if ( *it == tr("Home Fax" )) + if ( *it == "Home Fax" ) *itV = ent.homeFax(); - if ( *it == tr("Home Mobile" )) + if ( *it == "Home Mobile" ) *itV = ent.homeMobile(); /* @@ -1441,5 +1441,5 @@ void ContactEditor::setEntry( const OContact &entry ) { *itV = ent.otherPhone(); */ - if ( *it == tr("Business Pager") || *it == tr("Work Pager" )) + if ( ( *it == "Business Pager" ) || ( *it == "Work Pager" ) ) *itV = ent.businessPager(); /* @@ -1462,7 +1462,8 @@ void ContactEditor::setEntry( const OContact &entry ) { *itV = ent.yahooIM(); */ - if ( *it == tr("Home Web Page") ) + if ( *it == "Home Web Page" ) *itV = ent.homeWebpage(); - if ( *it == tr("Business WebPage") || *it == tr("Work Web Page") ) + + if ( ( *it == "Business WebPage" ) || ( *it == "Work Web Page" ) ) *itV = ent.businessWebpage(); @@ -1494,5 +1495,5 @@ void ContactEditor::saveEntry() { useFullName = FALSE; - } +} /*if ( ent.firstName() != txtFirstName->text() || @@ -1558,35 +1559,35 @@ void ContactEditor::saveEntry() { QListIterator<QLineEdit> itLE( listValue ); for ( it = slDynamicEntries.begin(); it != slDynamicEntries.end(); ++it, ++itLE) { - if ( *it == tr("Department" )) + if ( *it == "Department" ) ent.setDepartment( (*itLE)->text() ); - if ( *it == tr("Company" )) + if ( *it == "Company" ) ent.setCompany( (*itLE)->text() ); - if ( *it == tr("Office" )) + if ( *it == "Office" ) ent.setOffice( (*itLE)->text() ); - if ( *it == tr("Profession" )) + if ( *it == "Profession" ) ent.setProfession( (*itLE)->text() ); - if ( *it == tr("Assistant" )) + if ( *it == "Assistant" ) ent.setAssistant( (*itLE)->text() ); - if ( *it == tr("Manager" )) + if ( *it == "Manager" ) ent.setManager( (*itLE)->text() ); - if ( *it == tr("Spouse" )) + if ( *it == "Spouse" ) ent.setSpouse( (*itLE)->text() ); - if ( *it == tr("Birthday" )) + if ( *it == "Birthday" ) ent.setBirthday( (*itLE)->text() ); - if ( *it == tr("Anniversary" )) + if ( *it == "Anniversary" ) ent.setAnniversary( (*itLE)->text() ); - if ( *it == tr("Nickname" )) + if ( *it == "Nickname" ) ent.setNickname( (*itLE)->text() ); - if ( *it == tr("Children" )) + if ( *it == "Children" ) ent.setChildren( (*itLE)->text() ); @@ -1596,5 +1597,5 @@ void ContactEditor::saveEntry() { for ( it = slChooserNames.begin(), itV = slChooserValues.begin(); it != slChooserNames.end(); ++it, ++itV ) { - if ( *it == tr("Business Phone") || *it == tr("Work Phone" )) + if ( ( *it == "Business Phone" ) || ( *it == "Work Phone" ) ) ent.setBusinessPhone( *itV ); /* @@ -1602,8 +1603,8 @@ void ContactEditor::saveEntry() { ent.setBusiness2Phone( *itV ); */ - if ( *it == tr("Business Fax") || *it == tr("Work Fax" )) + if ( ( *it == "Business Fax" ) || ( *it == "Work Fax" ) ) ent.setBusinessFax( *itV ); - if ( *it == tr("Business Mobile") || *it == tr("Work Mobile" )) + if ( ( *it == "Business Mobile" ) || ( *it == "Work Mobile" ) ) ent.setBusinessMobile( *itV ); /* @@ -1614,5 +1615,5 @@ void ContactEditor::saveEntry() { //ent.setDefaultEmail( *itV ); - if ( *it == tr("Emails" )) { + if ( *it == "Emails" ){ QString allemail; QString defaultmail; @@ -1623,5 +1624,5 @@ void ContactEditor::saveEntry() { } - if ( *it == tr("Home Phone" )) + if ( *it == "Home Phone" ) ent.setHomePhone( *itV ); /* @@ -1629,8 +1630,8 @@ void ContactEditor::saveEntry() { ent.setHome2Phone( *itV ); */ - if ( *it == tr("Home Fax" )) + if ( *it == "Home Fax" ) ent.setHomeFax( *itV ); - if ( *it == tr("Home Mobile" )) + if ( *it == "Home Mobile" ) ent.setHomeMobile( *itV ); /* @@ -1644,5 +1645,5 @@ void ContactEditor::saveEntry() { ent.setOtherPhone( *itV ); */ - if ( *it == tr("Business Pager") || *it == tr("Work Pager") ) + if ( ( *it == "Business Pager" ) || ( *it == "Work Pager" ) ) ent.setBusinessPager( *itV ); /* @@ -1665,7 +1666,8 @@ void ContactEditor::saveEntry() { ent.setYahooIM( *itV ); */ - if ( *it == tr("Home Web Page") ) + if ( *it == "Home Web Page" ) ent.setHomeWebpage( *itV ); - if ( *it == tr("Business WebPage") || *it == tr("Work Web Page" )) + + if ( ( *it == "Business WebPage" ) || ( *it == "Work Web Page" ) ) ent.setBusinessWebpage( *itV ); |