summaryrefslogtreecommitdiffabout
path: root/korganizer
authorzautrix <zautrix>2004-08-09 14:56:56 (UTC)
committer zautrix <zautrix>2004-08-09 14:56:56 (UTC)
commitad99dd380750834b3ccc4dd6fdcdd446ca5ba7ee (patch) (side-by-side diff)
tree0394df7d796d38e7df637e6d45b82e7945fab55e /korganizer
parent48f53b2d2e7ed189e88f924259693ab66ff44b7f (diff)
downloadkdepimpi-ad99dd380750834b3ccc4dd6fdcdd446ca5ba7ee.zip
kdepimpi-ad99dd380750834b3ccc4dd6fdcdd446ca5ba7ee.tar.gz
kdepimpi-ad99dd380750834b3ccc4dd6fdcdd446ca5ba7ee.tar.bz2
more phone sync
Diffstat (limited to 'korganizer') (more/less context) (show whitespace changes)
-rw-r--r--korganizer/calendarview.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp
index d6ead37..547d02b 100644
--- a/korganizer/calendarview.cpp
+++ b/korganizer/calendarview.cpp
@@ -1178,55 +1178,53 @@ void CalendarView::syncPhone()
{
syncExternal( 1 );
}
void CalendarView::syncExternal( int mode )
{
mGlobalSyncMode = SYNC_MODE_EXTERNAL;
//mCurrentSyncDevice = "sharp-DTM";
if ( KOPrefs::instance()->mAskForPreferences )
edit_sync_options();
qApp->processEvents();
CalendarLocal* calendar = new CalendarLocal();
calendar->setTimeZoneId(KOPrefs::instance()->mTimeZoneId);
bool syncOK = false;
bool loadSuccess = false;
PhoneFormat* phoneFormat = 0;
#ifndef DESKTOP_VERSION
SharpFormat* sharpFormat = 0;
if ( mode == 0 ) { // sharp
sharpFormat = new SharpFormat () ;
loadSuccess = sharpFormat->load( calendar, mCalendar );
} else
#endif
if ( mode == 1 ) { // phone
- phoneFormat = new PhoneFormat ();
- loadSuccess = phoneFormat->load( calendar,
- mCalendar,
- mCurrentSyncDevice,
+ phoneFormat = new PhoneFormat (mCurrentSyncDevice,
KOPrefs::instance()->mPhoneDevice,
KOPrefs::instance()->mPhoneConnection,
KOPrefs::instance()->mPhoneModel);
+ loadSuccess = phoneFormat->load( calendar,mCalendar);
} else
return;
if ( loadSuccess ) {
getEventViewerDialog()->setSyncMode( true );
syncOK = synchronizeCalendar( mCalendar, calendar, KOPrefs::instance()->mSyncAlgoPrefs );
getEventViewerDialog()->setSyncMode( false );
qApp->processEvents();
if ( syncOK ) {
if ( KOPrefs::instance()->mWriteBackFile )
{
QPtrList<Incidence> iL = mCalendar->rawIncidences();
Incidence* inc = iL.first();
/* obsolete
while ( inc ) {
inc->setZaurusStat( inc->revision () );
inc = iL.next();
}
*/
#ifndef DESKTOP_VERSION
if ( sharpFormat )
sharpFormat->save(calendar);
#endif
if ( phoneFormat )