Diffstat (limited to 'noncore/net/mail/libmailwrapper/mailtypes.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/net/mail/libmailwrapper/mailtypes.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/noncore/net/mail/libmailwrapper/mailtypes.cpp b/noncore/net/mail/libmailwrapper/mailtypes.cpp index f56bb63..9c312e9 100644 --- a/noncore/net/mail/libmailwrapper/mailtypes.cpp +++ b/noncore/net/mail/libmailwrapper/mailtypes.cpp | |||
@@ -163,13 +163,13 @@ const QValueList<int>& RecPart::Positionlist()const | |||
163 | return m_poslist; | 163 | return m_poslist; |
164 | } | 164 | } |
165 | 165 | ||
166 | RecBody::RecBody() | 166 | RecBody::RecBody() |
167 | : m_BodyText(),m_PartsList(),m_description() | 167 | : m_BodyText(),m_PartsList(),m_description() |
168 | { | 168 | { |
169 | m_PartsList.setAutoDelete(true); | 169 | m_PartsList.clear(); |
170 | } | 170 | } |
171 | 171 | ||
172 | RecBody::~RecBody() | 172 | RecBody::~RecBody() |
173 | { | 173 | { |
174 | } | 174 | } |
175 | 175 | ||
@@ -180,27 +180,26 @@ void RecBody::setBodytext(const QString&bodyText) | |||
180 | 180 | ||
181 | const QString& RecBody::Bodytext()const | 181 | const QString& RecBody::Bodytext()const |
182 | { | 182 | { |
183 | return m_BodyText; | 183 | return m_BodyText; |
184 | } | 184 | } |
185 | 185 | ||
186 | void RecBody::setParts(const QList<RecPart>&parts) | 186 | void RecBody::setParts(const QValueList<RecPart>&parts) |
187 | { | 187 | { |
188 | m_PartsList.clear(); | ||
188 | m_PartsList = parts; | 189 | m_PartsList = parts; |
189 | m_PartsList.setAutoDelete(true); | ||
190 | } | 190 | } |
191 | 191 | ||
192 | const QList<RecPart>& RecBody::Parts()const | 192 | const QValueList<RecPart>& RecBody::Parts()const |
193 | { | 193 | { |
194 | return m_PartsList; | 194 | return m_PartsList; |
195 | } | 195 | } |
196 | 196 | ||
197 | void RecBody::addPart(const RecPart& part) | 197 | void RecBody::addPart(const RecPart& part) |
198 | { | 198 | { |
199 | RecPart*p = new RecPart(part); | 199 | m_PartsList.append(part); |
200 | m_PartsList.append(p); | ||
201 | } | 200 | } |
202 | 201 | ||
203 | void RecBody::setDescription(const RecPart&des) | 202 | void RecBody::setDescription(const RecPart&des) |
204 | { | 203 | { |
205 | m_description = des; | 204 | m_description = des; |
206 | } | 205 | } |