Commit 56b0a719 authored by Laurent Montel's avatar Laurent Montel 😁

GIT_SILENT: use nullptr now

parent 90b6ac7e
......@@ -52,7 +52,7 @@ class CALENDARSUPPORT_EXPORT ArchiveDialog : public QDialog
public:
ArchiveDialog(const Akonadi::ETMCalendar::Ptr &calendar,
Akonadi::IncidenceChanger *changer,
QWidget *parent = Q_NULLPTR);
QWidget *parent = nullptr);
~ArchiveDialog();
Q_SIGNALS:
......
......@@ -143,7 +143,7 @@ Attachment::Ptr AttachmentHandler::find(const QString &attachmentName,
return find(attachmentName, incidence);
}
static QTemporaryFile *s_tempFile = Q_NULLPTR;
static QTemporaryFile *s_tempFile = nullptr;
static QUrl tempFileForAttachment(const Attachment::Ptr &attachment)
{
......@@ -165,7 +165,7 @@ static QUrl tempFileForAttachment(const Attachment::Ptr &attachment)
if (tf.size() != attachment->size()) {
//whoops. failed to write the entire attachment. return an invalid URL.
delete s_tempFile;
s_tempFile = Q_NULLPTR;
s_tempFile = nullptr;
return url;
}
......@@ -186,7 +186,7 @@ bool AttachmentHandler::view(const Attachment::Ptr &attachment)
// put the attachment in a temporary file and launch it
QUrl tempUrl = tempFileForAttachment(attachment);
if (tempUrl.isValid()) {
stat = KRun::runUrl(tempUrl, attachment->mimeType(), Q_NULLPTR, true);
stat = KRun::runUrl(tempUrl, attachment->mimeType(), nullptr, true);
} else {
stat = false;
KMessageBox::error(
......@@ -194,7 +194,7 @@ bool AttachmentHandler::view(const Attachment::Ptr &attachment)
i18n("Unable to create a temporary file for the attachment."));
}
delete s_tempFile;
s_tempFile = Q_NULLPTR;
s_tempFile = nullptr;
}
return stat;
}
......@@ -257,7 +257,7 @@ bool AttachmentHandler::saveAs(const Attachment::Ptr &attachment)
i18n("Unable to create a temporary file for the attachment."));
}
delete s_tempFile;
s_tempFile = Q_NULLPTR;
s_tempFile = nullptr;
}
return stat;
}
......
......@@ -152,7 +152,7 @@ bool CalendarUtilsPrivate::purgeCompletedSubTodos(const KCalCore::Todo::Ptr &tod
if (deleteThisTodo) {
if (todo->isCompleted()) {
if (!mChanger->deleteIncidence(mCalendar->item(todo), Q_NULLPTR)) {
if (!mChanger->deleteIncidence(mCalendar->item(todo), nullptr)) {
allPurged = false;
}
} else {
......@@ -259,7 +259,7 @@ void CalendarUtils::purgeCompletedTodos()
// endMultiModify();
if (!allDeleted) {
KMessageBox::information(
Q_NULLPTR,
nullptr,
i18nc("@info",
"Unable to purge to-dos with uncompleted children."),
i18nc("@title:window", "Delete To-do"),
......
......@@ -50,7 +50,7 @@ public:
* Creates a new CalendarUtils instance. The instance does not take owner ship
* over the Calendar.
*/
explicit CalendarUtils(const Akonadi::ETMCalendar::Ptr &calendar, QObject *parent = Q_NULLPTR);
explicit CalendarUtils(const Akonadi::ETMCalendar::Ptr &calendar, QObject *parent = nullptr);
~CalendarUtils();
......
......@@ -35,7 +35,7 @@ class CALENDARSUPPORT_EXPORT CategoryConfig : public QObject
{
Q_OBJECT
public:
explicit CategoryConfig(KCoreConfigSkeleton *cfg, QObject *parent = Q_NULLPTR);
explicit CategoryConfig(KCoreConfigSkeleton *cfg, QObject *parent = nullptr);
~CategoryConfig();
QStringList customCategories() const;
void setCustomCategories(const QStringList &categories);
......
......@@ -40,7 +40,7 @@ class CALENDARSUPPORT_EXPORT CollectionSelection : public QObject
{
Q_OBJECT
public:
explicit CollectionSelection(QItemSelectionModel *selectionModel, QObject *parent = Q_NULLPTR);
explicit CollectionSelection(QItemSelectionModel *selectionModel, QObject *parent = nullptr);
~CollectionSelection();
QItemSelectionModel *model() const;
......
......@@ -56,7 +56,7 @@ class CALENDARSUPPORT_EXPORT EventArchiver : public QObject
{
Q_OBJECT
public:
explicit EventArchiver(QObject *parent = Q_NULLPTR);
explicit EventArchiver(QObject *parent = nullptr);
virtual ~EventArchiver();
/**
......
......@@ -33,7 +33,7 @@ class ModelTest : public QObject
{
Q_OBJECT
public:
explicit ModelTest(QAbstractItemModel *model, QObject *parent = Q_NULLPTR);
explicit ModelTest(QAbstractItemModel *model, QObject *parent = nullptr);
private Q_SLOTS:
void nonDestructiveBasicTest();
......
......@@ -38,7 +38,7 @@ class CalendarSupport::FreeBusyCalendarPrivate
{
public:
FreeBusyCalendarPrivate()
: mModel(Q_NULLPTR)
: mModel(nullptr)
{
}
......
......@@ -83,7 +83,7 @@ class CalendarSupport::FreeBusyItemModelPrivate
public:
FreeBusyItemModelPrivate()
: mForceDownload(false),
mRootData(Q_NULLPTR)
mRootData(nullptr)
{
}
~FreeBusyItemModelPrivate()
......
......@@ -33,7 +33,7 @@ class CALENDARSUPPORT_EXPORT IdentityManager : public KIdentityManagement::Ident
{
Q_OBJECT
public:
explicit IdentityManager(QObject *parent = Q_NULLPTR, const char *name = Q_NULLPTR)
explicit IdentityManager(QObject *parent = nullptr, const char *name = nullptr)
: KIdentityManagement::IdentityManager(true/*readonly*/, parent, name) {}
protected:
......
......@@ -36,7 +36,7 @@ class IncidenceAttachmentModelPrivate
IncidenceAttachmentModelPrivate(IncidenceAttachmentModel *qq,
const QPersistentModelIndex &modelIndex,
const Akonadi::Item &item = Akonadi::Item())
: q_ptr(qq), m_modelIndex(modelIndex), m_item(item), m_monitor(Q_NULLPTR)
: q_ptr(qq), m_modelIndex(modelIndex), m_item(item), m_monitor(nullptr)
{
if (modelIndex.isValid()) {
QObject::connect(modelIndex.model(), SIGNAL(dataChanged(QModelIndex,QModelIndex)),
......
......@@ -53,11 +53,11 @@ public:
};
explicit IncidenceAttachmentModel(const QPersistentModelIndex &modelIndex,
QObject *parent = Q_NULLPTR);
QObject *parent = nullptr);
explicit IncidenceAttachmentModel(const Akonadi::Item &item, QObject *parent = Q_NULLPTR);
explicit IncidenceAttachmentModel(const Akonadi::Item &item, QObject *parent = nullptr);
explicit IncidenceAttachmentModel(QObject *parent = Q_NULLPTR);
explicit IncidenceAttachmentModel(QObject *parent = nullptr);
~IncidenceAttachmentModel();
......
......@@ -35,7 +35,7 @@ public:
Type
};
explicit KCalModel(QObject *parent = Q_NULLPTR);
explicit KCalModel(QObject *parent = nullptr);
virtual ~KCalModel();
......
......@@ -40,7 +40,7 @@ class CALENDARSUPPORT_EXPORT MessageWidget : public KMessageWidget
{
Q_OBJECT
public:
explicit MessageWidget(QWidget *parent = Q_NULLPTR);
explicit MessageWidget(QWidget *parent = nullptr);
~MessageWidget();
bool eventFilter(QObject *watched, QEvent *event) Q_DECL_OVERRIDE;
void showEvent(QShowEvent *event) Q_DECL_OVERRIDE;
......
......@@ -70,8 +70,8 @@ class Q_DECL_HIDDEN IncidenceViewer::Private
{
public:
Private(IncidenceViewer *parent)
: mCalendar(Q_NULLPTR), mParent(parent), mParentCollectionFetchJob(Q_NULLPTR),
mAttachmentModel(Q_NULLPTR), mDelayedClear(false)
: mCalendar(nullptr), mParent(parent), mParentCollectionFetchJob(nullptr),
mAttachmentModel(nullptr), mDelayedClear(false)
{
mAttachmentHandler = new AttachmentHandler(parent);
mBrowser = new TextBrowser;
......@@ -144,7 +144,7 @@ IncidenceViewer::IncidenceViewer(Akonadi::ETMCalendar *calendar, QWidget *parent
IncidenceViewer::IncidenceViewer(QWidget *parent)
: QWidget(parent), d(new Private(this))
{
d->mCalendar = Q_NULLPTR;
d->mCalendar = nullptr;
init();
}
......
......@@ -196,7 +196,7 @@ QMimeData *CalendarSupport::createMimeData(const Akonadi::Item::List &items,
const KDateTime::Spec &timeSpec)
{
if (items.isEmpty()) {
return Q_NULLPTR;
return nullptr;
}
KCalCore::MemoryCalendar::Ptr cal(new KCalCore::MemoryCalendar(timeSpec));
......@@ -215,7 +215,7 @@ QMimeData *CalendarSupport::createMimeData(const Akonadi::Item::List &items,
}
if (incidencesFound == 0) {
return Q_NULLPTR;
return nullptr;
}
std::unique_ptr<QMimeData> mimeData(new QMimeData);
......
......@@ -254,7 +254,7 @@ CALENDARSUPPORT_EXPORT QList<QDate> workDays(const QDate &start, const QDate &en
CALENDARSUPPORT_EXPORT QStringList holiday(const QDate &date);
CALENDARSUPPORT_EXPORT void saveAttachments(const Akonadi::Item &item,
QWidget *widget = Q_NULLPTR);
QWidget *widget = nullptr);
CALENDARSUPPORT_EXPORT QStringList categories(const KCalCore::Incidence::List &incidences);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment