author | zautrix <zautrix> | 2004-08-02 00:52:35 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-08-02 00:52:35 (UTC) |
commit | 54157cb44316de72d776cfae70bdadf6c52f4773 (patch) (side-by-side diff) | |
tree | 953c8ae225a54fc43a7298d49b08e821bf741cb9 /libkcal/sharpformat.cpp | |
parent | 3ebd85e83e6f9d4ac59ce1828548f7236e2b1af0 (diff) | |
download | kdepimpi-54157cb44316de72d776cfae70bdadf6c52f4773.zip kdepimpi-54157cb44316de72d776cfae70bdadf6c52f4773.tar.gz kdepimpi-54157cb44316de72d776cfae70bdadf6c52f4773.tar.bz2 |
Hack, hack, hack
-rw-r--r-- | libkcal/sharpformat.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/libkcal/sharpformat.cpp b/libkcal/sharpformat.cpp index d39d2dd..605a54d 100644 --- a/libkcal/sharpformat.cpp +++ b/libkcal/sharpformat.cpp @@ -85,12 +85,12 @@ class SharpParser : public QObject if ( qName == "Event" ) { Event *event; - event = existingCalendar->event( attList[0].toInt() ); + event = existingCalendar->event( "Sharp_DTM",attList[0].toInt() ); if ( event ) event = (Event*)event->clone(); else event = new Event; - event->setZaurusId( attList[0].toInt() ); + event->setID("Sharp_DTM", attList[0].toInt() ); event->setZaurusUid( cSum ); event->setTempSyncStat(SYNC_TEMPSTATE_NEW_EXTERNAL ); @@ -189,7 +189,7 @@ class SharpParser : public QObject } else if ( qName == "Todo" ) { Todo *todo; - todo = existingCalendar->todo( attList[0].toInt() ); + todo = existingCalendar->todo( "Sharp_DTM", attList[0].toInt() ); if (todo ) todo = (Todo*)todo->clone(); else @@ -201,7 +201,7 @@ class SharpParser : public QObject //3,Privat,20040317T000000,20040318T000000,20040319T000000,0,5,Call bbb,"notes123 bbb gggg ""bb "" " //2,"Familie,Freunde,Holiday",20040318T000000,20040324T000000,20040317T000000,1,2,tod2,notes - todo->setZaurusId( attList[0].toInt() ); + todo->setID( "Sharp_DTM", attList[0].toInt() ); todo->setZaurusUid( cSum ); todo->setTempSyncStat( SYNC_TEMPSTATE_NEW_EXTERNAL ); @@ -466,7 +466,7 @@ int SharpFormat::getNumFromRecord( QString answer, Incidence* inc ) int newnum = templist[0].toInt( &ok ); if ( ok && newnum > 0) { retval = newnum; - inc->setZaurusId( newnum ); + inc->setID( "Sharp_DTM",newnum ); inc->setZaurusUid( getCsum( templist ) ); inc->setTempSyncStat( SYNC_TEMPSTATE_NEW_ID ); } @@ -520,7 +520,7 @@ bool SharpFormat::save( Calendar *calendar) deleteEnt = true; changeEnt = true; } - else if ( ev->zaurusId() == -1 ) { // add new + else if ( ev->getID("Sharp_DTM") == -1 ) { // add new command = "(echo \"" + ePrefix + eString + "\" ) | db2file datebook -w -g -c " + codec+ " > "+ fileName; system ( command.utf8() ); QFile file( fileName ); @@ -606,7 +606,7 @@ bool SharpFormat::save( Calendar *calendar) deleteEnt = true; changeEnt = true; } - else if ( to->zaurusId() == -1 ) { // add new + else if ( to->getID("Sharp_DTM") == -1 ) { // add new command = "(echo \"" + tPrefix + eString + "\" ) | db2file todo -w -g -c " + codec+ " > "+ fileName; system ( command.utf8() ); QFile file( fileName ); @@ -696,7 +696,7 @@ QString SharpFormat::dtToString( const QDateTime& dti, bool useTZ ) QString SharpFormat::getEventString( Event* event ) { QStringList list; - list.append( QString::number(event->zaurusId() ) ); + list.append( QString::number(event->getID("Sharp_DTM") ) ); list.append( event->categories().join(",") ); if ( !event->summary().isEmpty() ) list.append( event->summary() ); @@ -860,7 +860,7 @@ QString SharpFormat::getEventString( Event* event ) QString SharpFormat::getTodoString( Todo* todo ) { QStringList list; - list.append( QString::number( todo->zaurusId() ) ); + list.append( QString::number( todo->getID("Sharp_DTM") ) ); list.append( todo->categories().join(",") ); if ( todo->hasStartDate() ) { |