[kmobiletools] KDE/kdepim/kmobiletools/kmobiletools/libkmobiletools
Marco Gulino
marco at kmobiletools.org
Thu Jun 21 21:57:12 CEST 2007
SVN commit 678590 by gulino:
Removing QSharedData, as it's not going to be useful when subclassing KMime.
Also making assembleHeaders virtual, as it's going to be subclassed too.
M +3 -4 sms.cpp
M +2 -3 sms.h
--- trunk/KDE/kdepim/kmobiletools/kmobiletools/libkmobiletools/sms.cpp #678589:678590
@@ -27,14 +27,13 @@
#include <qregexp.h>
#include <kcodecs.h>
#include <QTextStream>
-#include <QSharedData>
#define SMS_MIMETYPE "application/x-kmobiletools-sms"
#include "kmobiletoolshelper.h"
-class SMSPrivate : public QSharedData {
+class SMSPrivate {
public:
- SMSPrivate(SMS* p_parent) : QSharedData(),
+ SMSPrivate(SMS* p_parent) :
i_folder(0), i_slot(0), i_type(SMS::All), b_unread(false)
{ parent=p_parent; }
QStringList sl_numbers;
@@ -173,7 +172,7 @@
// Convenience non-static method for the above one
QStringList SMS::getMultiText() const
{
- ((SMSPrivate*)d.data() )->refreshUid(); /// @TODO move this to the single setters?
+ d->refreshUid(); /// @TODO move this to the single setters?
return getMultiText(getText() );
}
--- trunk/KDE/kdepim/kmobiletools/kmobiletools/libkmobiletools/sms.h #678589:678590
@@ -26,7 +26,6 @@
#include <QtCore/QObject>
#include <QtCore/QStringList>
#include <kdatetime.h>
-#include <QtCore/QSharedDataPointer>
/**
@author Marco Gulino
*/
@@ -87,10 +86,10 @@
// Headers
KMime::Headers::Date *date();
protected:
- QByteArray assembleHeaders();
+ virtual QByteArray assembleHeaders();
private:
- QSharedDataPointer<SMSPrivate> d;
+ SMSPrivate *const d;
/// @TODO signals and slots removed, now find a way to do this in smslist.
/*public Q_SLOTS:
More information about the kmobiletools
mailing list