summaryrefslogtreecommitdiffabout
path: root/libkcal/incidence.cpp
Unidiff
Diffstat (limited to 'libkcal/incidence.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--libkcal/incidence.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/libkcal/incidence.cpp b/libkcal/incidence.cpp
index 549014e..39c14f5 100644
--- a/libkcal/incidence.cpp
+++ b/libkcal/incidence.cpp
@@ -56,10 +56,17 @@ Incidence::Incidence( const Incidence &i ) : IncidenceBase( i )
56 mCategories = i.mCategories; 56 mCategories = i.mCategories;
57// Incidence *mRelatedTo; Incidence *mRelatedTo; 57// Incidence *mRelatedTo; Incidence *mRelatedTo;
58 mRelatedTo = 0; 58 mRelatedTo = 0;
59 mRelatedToUid = i.mRelatedToUid; 59 mRelatedToUid = i.mRelatedToUid;
60// QPtrList<Incidence> mRelations; QPtrList<Incidence> mRelations; 60// QPtrList<Incidence> mRelations; QPtrList<Incidence> mRelations;
61 mExDates = i.mExDates; 61 mExDates = i.mExDates;
62 mAttachments = i.mAttachments; 62 QPtrListIterator<Attachment> itat( i.mAttachments );
63 Attachment *at;
64 while( (at = itat.current()) ) {
65 Attachment *a = new Attachment( *at );
66 mAttachments.append( a );
67 ++itat;
68 }
69 mAttachments.setAutoDelete( true );
63 mResources = i.mResources; 70 mResources = i.mResources;
64 mSecrecy = i.mSecrecy; 71 mSecrecy = i.mSecrecy;
65 mPriority = i.mPriority; 72 mPriority = i.mPriority;
@@ -757,6 +764,7 @@ Recurrence *Incidence::recurrence()
757 if ( ! mRecurrence ) { 764 if ( ! mRecurrence ) {
758 mRecurrence = new Recurrence(this); 765 mRecurrence = new Recurrence(this);
759 mRecurrence->setRecurStart( dtStart() ); 766 mRecurrence->setRecurStart( dtStart() );
767 mRecurrence->setRecurReadOnly( isReadOnly());
760 //qDebug("creating new recurence "); 768 //qDebug("creating new recurence ");
761 //abort(); 769 //abort();
762 } 770 }