From 77aa480c9891a90c9b492618ebfd2b20f2d0727a Mon Sep 17 00:00:00 2001 From: zautrix Date: Wed, 29 Jun 2005 16:14:46 +0000 Subject: many sync fixes --- (limited to 'kaddressbook') diff --git a/kaddressbook/addresseeeditorwidget.cpp b/kaddressbook/addresseeeditorwidget.cpp index bd32859..5334a0e 100644 --- a/kaddressbook/addresseeeditorwidget.cpp +++ b/kaddressbook/addresseeeditorwidget.cpp @@ -659,7 +659,7 @@ void AddresseeEditorWidget::setupTab2() QHBox * nbox = new QHBox ( tab2 ); label = new QLabel( i18n( "Birthday:" )+" ", nbox ); mBirthdayPicker = new KDateEdit( nbox ); - mBirthdayPicker->toggleDateFormat(); + //mBirthdayPicker->toggleDateFormat(); mBirthdayPicker->setHandleInvalid( true ); connect( mBirthdayPicker, SIGNAL( dateChanged( QDate ) ), SLOT( dateChanged( QDate ) ) ); @@ -681,7 +681,7 @@ void AddresseeEditorWidget::setupTab2() label = new QLabel( i18n( "Birthday:" ), tab2 ); layout->addWidget( label, iii, 1 ); mBirthdayPicker = new KDateEdit( tab2 ); - mBirthdayPicker->toggleDateFormat(); + //mBirthdayPicker->toggleDateFormat(); mBirthdayPicker->setHandleInvalid( true ); connect( mBirthdayPicker, SIGNAL( dateChanged( QDate ) ), SLOT( dateChanged( QDate ) ) ); @@ -1079,8 +1079,6 @@ void AddresseeEditorWidget::save() 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()); } diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp index 3715786..046cb63 100644 --- a/kaddressbook/kabcore.cpp +++ b/kaddressbook/kabcore.cpp @@ -375,6 +375,7 @@ KABCore::KABCore( KXMLGUIClient *client, bool readWrite, QWidget *parent, const connect( ExternalAppHandler::instance(), SIGNAL (requestForDetails(const QString&, const QString&, const QString&, const QString&, const QString&)),this, SLOT(requestForDetails(const QString&, const QString&, const QString&, const QString&, const QString&))); connect( ExternalAppHandler::instance(), SIGNAL (requestForBirthdayList(const QString&, const QString&)),this, SLOT(requestForBirthdayList(const QString&, const QString&))); connect( ExternalAppHandler::instance(), SIGNAL (nextView()),this, SLOT(setDetailsToggle())); + connect( ExternalAppHandler::instance(), SIGNAL (doRingSync()),this, SLOT( doRingSync())); connect( ExternalAppHandler::instance(), SIGNAL (callContactdialog()),this, SLOT(callContactdialog())); @@ -2580,6 +2581,10 @@ void KABCore::resizeAndCallContactdialog() QTimer::singleShot( 10,this, SLOT ( callContactdialog() ) ); } +void KABCore::doRingSync() +{ + syncManager->multiSync( false ); +} void KABCore::callContactdialog() { static bool running = false; diff --git a/kaddressbook/kabcore.h b/kaddressbook/kabcore.h index 6479a58..ceeeda7 100644 --- a/kaddressbook/kabcore.h +++ b/kaddressbook/kabcore.h @@ -373,6 +373,7 @@ class KABCore : public QWidget, public KSyncInterface void setCaptionBack(); void resizeAndCallContactdialog(); void callContactdialog(); + void doRingSync(); void importFromOL(); void extensionModified( const KABC::Addressee::List &list ); -- cgit v0.9.0.2