author | zautrix <zautrix> | 2004-10-12 20:21:55 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-10-12 20:21:55 (UTC) |
commit | c38bc76bfec3aae65f3bc22c3e2a6ac0d6b0437d (patch) (side-by-side diff) | |
tree | 786dcfb580c2399d85ab80c0f68b9adc22515db5 | |
parent | 4a3a203c0f95f7d53a784c785004f8c4452c0154 (diff) | |
download | kdepimpi-c38bc76bfec3aae65f3bc22c3e2a6ac0d6b0437d.zip kdepimpi-c38bc76bfec3aae65f3bc22c3e2a6ac0d6b0437d.tar.gz kdepimpi-c38bc76bfec3aae65f3bc22c3e2a6ac0d6b0437d.tar.bz2 |
remoced debug output
-rw-r--r-- | kaddressbook/addresseeeditorwidget.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kaddressbook/addresseeeditorwidget.cpp b/kaddressbook/addresseeeditorwidget.cpp index 4db0a20..012780b 100644 --- a/kaddressbook/addresseeeditorwidget.cpp +++ b/kaddressbook/addresseeeditorwidget.cpp @@ -1009,129 +1009,129 @@ void AddresseeEditorWidget::load() mNoteEdit->setText( mAddressee.note() ); mEmailWidget->setEmails( mAddressee.emails() ); mPhoneEditWidget->setPhoneNumbers( mAddressee.phoneNumbers() ); mAddressEditWidget->setAddresses( mAddressee, mAddressee.addresses() ); mBirthdayPicker->setDate( mAddressee.birthday().date() ); //US mAnniversaryPicker->setDate( QDate::fromString( mAddressee.custom( //US "KADDRESSBOOK", "X-Anniversary" ), Qt::ISODate) ); QDate dt = KGlobal::locale()->readDate( mAddressee.custom("KADDRESSBOOK", "X-Anniversary" ), "%Y-%m-%d"); // = Qt::ISODate mAnniversaryPicker->setDate( dt ); mNicknameEdit->setText( mAddressee.nickName() ); mCategoryEdit->setText( mAddressee.categories().join( "," ) ); mGeoWidget->setGeo( mAddressee.geo() ); mImageWidget->setPhoto( mAddressee.photo() ); mImageWidget->setLogo( mAddressee.logo() ); mKeyWidget->setKeys( mAddressee.keys() ); mSecrecyWidget->setSecrecy( mAddressee.secrecy() ); #ifndef KAB_EMBEDDED mSoundWidget->setSound( mAddressee.sound() ); #else //KAB_EMBEDDED //US qDebug("AddresseeEditorWidget::load has to be changed 2"); #endif //KAB_EMBEDDED // Load customs mIMAddressEdit->setText( mAddressee.custom( "KADDRESSBOOK", "X-IMAddress" ) ); mSpouseEdit->setText( mAddressee.custom( "KADDRESSBOOK", "X-SpousesName" ) ); mChildEdit->setText( mAddressee.custom( "KADDRESSBOOK", "X-Children" ) ); mManagerEdit->setText( mAddressee.custom( "KADDRESSBOOK", "X-ManagersName" ) ); mAssistantEdit->setText( mAddressee.custom( "KADDRESSBOOK", "X-AssistantsName" ) ); mDepartmentEdit->setText( mAddressee.custom( "KADDRESSBOOK", "X-Department" ) ); mOfficeEdit->setText( mAddressee.custom( "KADDRESSBOOK", "X-Office" ) ); mProfessionEdit->setText( mAddressee.custom( "KADDRESSBOOK", "X-Profession" ) ); QString gen = mAddressee.custom( "KADDRESSBOOK", "X-Gender" ); if ( gen == "female" ) mGenderBox->setCurrentItem ( 1 ); else if ( gen == "male" ) mGenderBox->setCurrentItem ( 2 ); else mGenderBox->setCurrentItem ( 0 ); blockSignals( block ); mBlockSignals = false; mDirty = false; } void AddresseeEditorWidget::save() { if ( !dirty() ) { return; } mAddressee.setRole( mRoleEdit->text() ); mAddressee.setOrganization( mOrgEdit->text() ); mAddressee.setUrl( KURL( mURLEdit->text() ) ); mAddressee.setNote( mNoteEdit->text() ); if ( mBirthdayPicker->inputIsValid() ) { QDate da = mBirthdayPicker->date(); if ( da > QDate::currentDate() ) da.setYMD(da.year()-100, da.month(), da.day() ); mAddressee.setBirthday( QDateTime( da ) ); - qDebug("bday %s ",da.toString().latin1()); + //qDebug("bday %s ",da.toString().latin1()); } else { mAddressee.setBirthday( QDateTime() ); mBirthdayPicker->clear(); } mAddressee.setNickName( mNicknameEdit->text() ); mAddressee.setCategories( QStringList::split( ",", mCategoryEdit->text() ) ); mAddressee.setGeo( mGeoWidget->geo() ); mAddressee.setPhoto( mImageWidget->photo() ); mAddressee.setLogo( mImageWidget->logo() ); mAddressee.setKeys( mKeyWidget->keys() ); #ifndef KAB_EMBEDDED mAddressee.setSound( mSoundWidget->sound() ); #else //KAB_EMBEDDED //US qDebug("AddresseeEditorWidget::save sound not supported"); #endif //KAB_EMBEDDED mAddressee.setSecrecy( mSecrecyWidget->secrecy() ); // save custom fields mAddressee.insertCustom( "KADDRESSBOOK", "X-IMAddress", mIMAddressEdit->text() ); mAddressee.insertCustom( "KADDRESSBOOK", "X-SpousesName", mSpouseEdit->text() ); mAddressee.insertCustom( "KADDRESSBOOK", "X-Children", mChildEdit->text() ); mAddressee.insertCustom( "KADDRESSBOOK", "X-ManagersName", mManagerEdit->text() ); mAddressee.insertCustom( "KADDRESSBOOK", "X-AssistantsName", mAssistantEdit->text() ); mAddressee.insertCustom( "KADDRESSBOOK", "X-Department", mDepartmentEdit->text() ); mAddressee.insertCustom( "KADDRESSBOOK", "X-Office", mOfficeEdit->text() ); mAddressee.insertCustom( "KADDRESSBOOK", "X-Profession", mProfessionEdit->text() ); if ( mAnniversaryPicker->inputIsValid() ) { QString dt = KGlobal::locale()->formatDate(mAnniversaryPicker->date(), true, KLocale::ISODate); mAddressee.insertCustom( "KADDRESSBOOK", "X-Anniversary", dt); } else { mAddressee.removeCustom( "KADDRESSBOOK", "X-Anniversary" ); mAnniversaryPicker->clear(); } int gen = mGenderBox->currentItem (); if ( gen == 1 ) mAddressee.insertCustom( "KADDRESSBOOK", "X-Gender", "female"); else if ( gen == 2 ) mAddressee.insertCustom( "KADDRESSBOOK", "X-Gender", "male"); else mAddressee.removeCustom( "KADDRESSBOOK", "X-Gender" ); // Save the email addresses QStringList emails = mAddressee.emails(); QStringList::Iterator iter; for ( iter = emails.begin(); iter != emails.end(); ++iter ) mAddressee.removeEmail( *iter ); emails = mEmailWidget->emails(); bool first = true; for ( iter = emails.begin(); iter != emails.end(); ++iter ) { mAddressee.insertEmail( *iter, first ); first = false; } // Save the phone numbers KABC::PhoneNumber::List phoneNumbers; KABC::PhoneNumber::List::Iterator phoneIter; phoneNumbers = mAddressee.phoneNumbers(); for ( phoneIter = phoneNumbers.begin(); phoneIter != phoneNumbers.end(); ++phoneIter ) mAddressee.removePhoneNumber( *phoneIter ); |