author | zautrix <zautrix> | 2004-08-10 19:41:31 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-08-10 19:41:31 (UTC) |
commit | 2f1b58e344b882578977dd3786f7a94495096d22 (patch) (side-by-side diff) | |
tree | 6658bef546b6feac1688aa465ca94344e15704d7 /libkcal/calendar.cpp | |
parent | 467e50111dfd6d66aca205501b6bf369b7f0a166 (diff) | |
download | kdepimpi-2f1b58e344b882578977dd3786f7a94495096d22.zip kdepimpi-2f1b58e344b882578977dd3786f7a94495096d22.tar.gz kdepimpi-2f1b58e344b882578977dd3786f7a94495096d22.tar.bz2 |
More syncing stuff
-rw-r--r-- | libkcal/calendar.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/libkcal/calendar.cpp b/libkcal/calendar.cpp index 32aac7a..a3977d7 100644 --- a/libkcal/calendar.cpp +++ b/libkcal/calendar.cpp @@ -21,24 +21,25 @@ #include <stdlib.h> #include <time.h> #include <kdebug.h> #include <kglobal.h> #include <klocale.h> #include "exceptions.h" #include "calfilter.h" #include "calendar.h" +#include "syncdefines.h" using namespace KCal; Calendar::Calendar() { init(); setTimeZoneId( i18n (" 00:00 Europe/London(UTC)") ); } Calendar::Calendar( const QString &timeZoneId ) { @@ -238,25 +239,39 @@ QPtrList<Incidence> Calendar::incidences() QPtrList<Event> e = events(); for( i = e.first(); i; i = e.next() ) incidences.append( i ); QPtrList<Todo> t = todos(); for( i = t.first(); i; i = t.next() ) incidences.append( i ); QPtrList<Journal> j = journals(); for( i = j.first(); i; i = j.next() ) incidences.append( i ); return incidences; } +void Calendar::resetTempSyncStat() +{ + QPtrList<Incidence> incidences; + + Incidence *i; + + QPtrList<Event> e = rawEvents(); + for( i = e.first(); i; i = e.next() ) i->setTempSyncStat( SYNC_TEMPSTATE_INITIAL ); + + QPtrList<Todo> t = rawTodos(); + for( i = t.first(); i; i = t.next() ) i->setTempSyncStat( SYNC_TEMPSTATE_INITIAL ); + QPtrList<Journal> j = journals(); + for( i = j.first(); i; i = j.next() ) i->setTempSyncStat( SYNC_TEMPSTATE_INITIAL ); +} QPtrList<Incidence> Calendar::rawIncidences() { QPtrList<Incidence> incidences; Incidence *i; QPtrList<Event> e = rawEvents(); for( i = e.first(); i; i = e.next() ) incidences.append( i ); QPtrList<Todo> t = rawTodos(); for( i = t.first(); i; i = t.next() ) incidences.append( i ); |