Commit 16186362 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

GIT_SILENT: use nullptr now

parent 2ecd2883
......@@ -67,7 +67,7 @@ class Q_DECL_HIDDEN MarcusBains::Private
public:
Private(EventView *eventView, Agenda *agenda)
: mEventView(eventView), mAgenda(agenda),
mTimer(Q_NULLPTR), mTimeBox(Q_NULLPTR), mOldTodayCol(-1)
mTimer(nullptr), mTimeBox(nullptr), mOldTodayCol(-1)
{
}
......@@ -206,10 +206,10 @@ public:
int columns, int rows, int rowSize, bool isInteractive)
: mAgendaView(agendaView), mScrollArea(scrollArea), mAllDayMode(false),
mColumns(columns), mRows(rows), mGridSpacingX(0.0), mGridSpacingY(rowSize),
mDesiredGridSpacingY(rowSize), mChanger(Q_NULLPTR),
mDesiredGridSpacingY(rowSize), mChanger(nullptr),
mResizeBorderWidth(0), mScrollBorderWidth(0), mScrollDelay(0), mScrollOffset(0),
mWorkingHoursEnable(false), mHolidayMask(Q_NULLPTR), mWorkingHoursYTop(0),
mWorkingHoursYBottom(0), mHasSelection(0), mSelectedId(-1), mMarcusBains(Q_NULLPTR),
mWorkingHoursEnable(false), mHolidayMask(nullptr), mWorkingHoursYTop(0),
mWorkingHoursYBottom(0), mHasSelection(0), mSelectedId(-1), mMarcusBains(nullptr),
mActionType(Agenda::NOP), mItemMoved(false), mOldLowerScrollValue(0),
mOldUpperScrollValue(0), mReturnPressed(false), mIsInteractive(isInteractive)
{
......@@ -402,13 +402,13 @@ void Agenda::init()
d->mOldLowerScrollValue = -1;
d->mOldUpperScrollValue = -1;
d->mClickedItem = Q_NULLPTR;
d->mClickedItem = nullptr;
d->mActionItem = Q_NULLPTR;
d->mActionItem = nullptr;
d->mActionType = NOP;
d->mItemMoved = false;
d->mSelectedItem = Q_NULLPTR;
d->mSelectedItem = nullptr;
d->mSelectedId = -1;
setAcceptDrops(true);
......@@ -427,7 +427,7 @@ void Agenda::init()
// Create the Marcus Bains line.
if (d->mAllDayMode) {
d->mMarcusBains = Q_NULLPTR;
d->mMarcusBains = nullptr;
} else {
d->mMarcusBains = new MarcusBains(d->mAgendaView, this);
}
......@@ -442,7 +442,7 @@ void Agenda::clear()
d->mAgendaItemsById.clear();
d->mItemsQueuedForDeletion.clear();
d->mSelectedItem = Q_NULLPTR;
d->mSelectedItem = nullptr;
clearSelection();
}
......@@ -674,7 +674,7 @@ bool Agenda::eventFilter_mouse(QObject *object, QMouseEvent *me)
if (item) {
KCalCore::Incidence::Ptr incidence = item->incidence();
if (incidence->isReadOnly()) {
d->mActionItem = Q_NULLPTR;
d->mActionItem = nullptr;
} else {
d->mActionItem = item;
startItemAction(viewportPos);
......@@ -700,8 +700,8 @@ bool Agenda::eventFilter_mouse(QObject *object, QMouseEvent *me)
}
showNewEventPopupSignal();
} else {
selectItem(Q_NULLPTR);
d->mActionItem = Q_NULLPTR;
selectItem(nullptr);
d->mActionItem = nullptr;
#ifndef QT_NO_CURSOR
setCursor(Qt::ArrowCursor);
#endif
......@@ -776,7 +776,7 @@ bool Agenda::eventFilter_mouse(QObject *object, QMouseEvent *me)
case QEvent::MouseButtonDblClick:
if (object == this) {
selectItem(Q_NULLPTR);
selectItem(nullptr);
Q_EMIT newEventSignal();
} else {
AgendaItem::QPtr doubleClickedItem = qobject_cast<AgendaItem *>(object);
......@@ -966,7 +966,7 @@ void Agenda::performItemAction(const QPoint &pos)
if (d->mChanger) {
// d->mChanger->cancelChange(d->mActionItem->incidence());
}
d->mActionItem = Q_NULLPTR;
d->mActionItem = nullptr;
d->mActionType = NOP;
d->mItemMoved = false;
return;
......@@ -1002,7 +1002,7 @@ void Agenda::performItemAction(const QPoint &pos)
#ifndef QT_NO_CURSOR
setCursor(Qt::ArrowCursor);
#endif
d->mActionItem = Q_NULLPTR;
d->mActionItem = nullptr;
d->mActionType = NOP;
d->mItemMoved = false;
return;
......@@ -1290,7 +1290,7 @@ void Agenda::endItemAction()
}
}
d->mActionItem = Q_NULLPTR;
d->mActionItem = nullptr;
d->mItemMoved = false;
if (multiModify) {
......@@ -1732,7 +1732,7 @@ AgendaItem::QPtr Agenda::insertItem(const KCalCore::Incidence::Ptr &incidence, c
{
if (d->mAllDayMode) {
qCDebug(CALENDARVIEW_LOG) << "using this in all-day mode is illegal.";
return Q_NULLPTR;
return nullptr;
}
d->mActionType = NOP;
......@@ -1777,7 +1777,7 @@ AgendaItem::QPtr Agenda::insertAllDayItem(const KCalCore::Incidence::Ptr &incide
{
if (!d->mAllDayMode) {
qCCritical(CALENDARVIEW_LOG) << "using this in non all-day mode is illegal.";
return Q_NULLPTR;
return nullptr;
}
d->mActionType = NOP;
......@@ -1842,7 +1842,7 @@ void Agenda::insertMultiItem(const KCalCore::Incidence::Ptr &event, const KDateT
QString newtext;
int width = XEnd - XBegin + 1;
int count = 0;
AgendaItem::QPtr current = Q_NULLPTR;
AgendaItem::QPtr current = nullptr;
QList<AgendaItem::QPtr> multiItems;
int visibleCount = d->mSelectedDates.first().daysTo(d->mSelectedDates.last());
for (cellX = XBegin; cellX <= XEnd; ++cellX) {
......@@ -1875,16 +1875,16 @@ void Agenda::insertMultiItem(const KCalCore::Incidence::Ptr &event, const KDateT
if (it != e) { // .first asserts if the list is empty
AgendaItem::QPtr first = multiItems.first();
AgendaItem::QPtr last = multiItems.last();
AgendaItem::QPtr prev = Q_NULLPTR, next = Q_NULLPTR;
AgendaItem::QPtr prev = nullptr, next = nullptr;
while (it != e) {
AgendaItem::QPtr item = *it;
++it;
next = (it == e) ? Q_NULLPTR : (*it);
next = (it == e) ? nullptr : (*it);
if (item) {
item->setMultiItem((item == first) ? Q_NULLPTR : first,
item->setMultiItem((item == first) ? nullptr : first,
prev, next,
(item == last) ? Q_NULLPTR : last);
(item == last) ? nullptr : last);
}
prev = item;
}
......@@ -2160,7 +2160,7 @@ void Agenda::deselectItem()
}
}
d->mSelectedItem = Q_NULLPTR;
d->mSelectedItem = nullptr;
}
void Agenda::selectItem(const AgendaItem::QPtr &item)
......@@ -2169,7 +2169,7 @@ void Agenda::selectItem(const AgendaItem::QPtr &item)
return;
}
deselectItem();
if (item == Q_NULLPTR) {
if (item == nullptr) {
Q_EMIT incidenceSelected(KCalCore::Incidence::Ptr(), QDate());
return;
}
......
......@@ -55,14 +55,14 @@ using namespace EventViews;
//-----------------------------------------------------------------------------
QPixmap *AgendaItem::alarmPxmp = Q_NULLPTR;
QPixmap *AgendaItem::recurPxmp = Q_NULLPTR;
QPixmap *AgendaItem::readonlyPxmp = Q_NULLPTR;
QPixmap *AgendaItem::replyPxmp = Q_NULLPTR;
QPixmap *AgendaItem::groupPxmp = Q_NULLPTR;
QPixmap *AgendaItem::groupPxmpTent = Q_NULLPTR;
QPixmap *AgendaItem::organizerPxmp = Q_NULLPTR;
QPixmap *AgendaItem::eventPxmp = Q_NULLPTR;
QPixmap *AgendaItem::alarmPxmp = nullptr;
QPixmap *AgendaItem::recurPxmp = nullptr;
QPixmap *AgendaItem::readonlyPxmp = nullptr;
QPixmap *AgendaItem::replyPxmp = nullptr;
QPixmap *AgendaItem::groupPxmp = nullptr;
QPixmap *AgendaItem::groupPxmpTent = nullptr;
QPixmap *AgendaItem::organizerPxmp = nullptr;
QPixmap *AgendaItem::eventPxmp = nullptr;
//-----------------------------------------------------------------------------
......@@ -98,8 +98,8 @@ AgendaItem::AgendaItem(EventView *eventView, const MultiViewCalendar::Ptr &calen
mIconGroup = false;
mIconGroupTent = false;
mIconOrganizer = false;
mMultiItemInfo = Q_NULLPTR;
mStartMoveInfo = Q_NULLPTR;
mMultiItemInfo = nullptr;
mStartMoveInfo = nullptr;
mItemPos = itemPos;
mItemCount = itemCount;
......@@ -201,7 +201,7 @@ bool AgendaItem::dissociateFromMultiItem()
nextItem->setMultiItem(firstItem, prevItem, nextItem->prevMultiItem(), lastItem);
}
delete mMultiItemInfo;
mMultiItemInfo = Q_NULLPTR;
mMultiItemInfo = nullptr;
return true;
}
......@@ -286,10 +286,10 @@ bool AgendaItem::isMultiItem() const
AgendaItem::QPtr AgendaItem::prependMoveItem(const AgendaItem::QPtr &e)
{
if (!e) {
return Q_NULLPTR;
return nullptr;
}
AgendaItem::QPtr first = Q_NULLPTR, last = Q_NULLPTR;
AgendaItem::QPtr first = nullptr, last = nullptr;
if (isMultiItem()) {
first = mMultiItemInfo->mFirstMultiItem;
last = mMultiItemInfo->mLastMultiItem;
......@@ -301,7 +301,7 @@ AgendaItem::QPtr AgendaItem::prependMoveItem(const AgendaItem::QPtr &e)
last = this;
}
e->setMultiItem(Q_NULLPTR, Q_NULLPTR, first, last);
e->setMultiItem(nullptr, nullptr, first, last);
first->setMultiItem(e, e, first->nextMultiItem(), first->lastMultiItem());
AgendaItem::QPtr tmp = first->nextMultiItem();
......@@ -314,7 +314,7 @@ AgendaItem::QPtr AgendaItem::prependMoveItem(const AgendaItem::QPtr &e)
e->mStartMoveInfo = new MultiItemInfo(*mStartMoveInfo);
// e->moveInfo()->mFirstMultiItem = moveInfo()->mFirstMultiItem;
// e->moveInfo()->mLastMultiItem = moveInfo()->mLastMultiItem;
e->moveInfo()->mPrevMultiItem = Q_NULLPTR;
e->moveInfo()->mPrevMultiItem = nullptr;
e->moveInfo()->mNextMultiItem = first;
}
......@@ -327,10 +327,10 @@ AgendaItem::QPtr AgendaItem::prependMoveItem(const AgendaItem::QPtr &e)
AgendaItem::QPtr AgendaItem::appendMoveItem(const AgendaItem::QPtr &e)
{
if (!e) {
return Q_NULLPTR;
return nullptr;
}
AgendaItem::QPtr first = Q_NULLPTR, last = Q_NULLPTR;
AgendaItem::QPtr first = nullptr, last = nullptr;
if (isMultiItem()) {
first = mMultiItemInfo->mFirstMultiItem;
last = mMultiItemInfo->mLastMultiItem;
......@@ -342,7 +342,7 @@ AgendaItem::QPtr AgendaItem::appendMoveItem(const AgendaItem::QPtr &e)
last = this;
}
e->setMultiItem(first, last, Q_NULLPTR, Q_NULLPTR);
e->setMultiItem(first, last, nullptr, nullptr);
AgendaItem::QPtr tmp = first;
while (tmp) {
......@@ -356,7 +356,7 @@ AgendaItem::QPtr AgendaItem::appendMoveItem(const AgendaItem::QPtr &e)
// e->moveInfo()->mFirstMultiItem = moveInfo()->mFirstMultiItem;
// e->moveInfo()->mLastMultiItem = moveInfo()->mLastMultiItem;
e->moveInfo()->mPrevMultiItem = last;
e->moveInfo()->mNextMultiItem = Q_NULLPTR;
e->moveInfo()->mNextMultiItem = nullptr;
}
if (last && last->moveInfo()) {
last->moveInfo()->mNextMultiItem = e;
......@@ -378,18 +378,18 @@ AgendaItem::QPtr AgendaItem::removeMoveItem(const AgendaItem::QPtr &e)
}
if (first == e) {
first = first->nextMultiItem();
first->setMultiItem(Q_NULLPTR, Q_NULLPTR, first->nextMultiItem(), first->lastMultiItem());
first->setMultiItem(nullptr, nullptr, first->nextMultiItem(), first->lastMultiItem());
}
if (last == e) {
last = last->prevMultiItem();
last->setMultiItem(last->firstMultiItem(), last->prevMultiItem(), Q_NULLPTR, Q_NULLPTR);
last->setMultiItem(last->firstMultiItem(), last->prevMultiItem(), nullptr, nullptr);
}
AgendaItem::QPtr tmp = first;
if (first == last) {
delete mMultiItemInfo;
tmp = Q_NULLPTR;
mMultiItemInfo = Q_NULLPTR;
tmp = nullptr;
mMultiItemInfo = nullptr;
}
while (tmp) {
next = tmp->nextMultiItem();
......@@ -400,10 +400,10 @@ AgendaItem::QPtr AgendaItem::removeMoveItem(const AgendaItem::QPtr &e)
if (e == prev) {
prev = prev->prevMultiItem();
}
tmp->setMultiItem((tmp == first) ? Q_NULLPTR : first,
(tmp == prev) ? Q_NULLPTR : prev,
(tmp == next) ? Q_NULLPTR : next,
(tmp == last) ? Q_NULLPTR : last);
tmp->setMultiItem((tmp == first) ? nullptr : first,
(tmp == prev) ? nullptr : prev,
(tmp == next) ? nullptr : next,
(tmp == last) ? nullptr : last);
tmp = tmp->nextMultiItem();
}
}
......@@ -433,10 +433,10 @@ void AgendaItem::startMovePrivate()
mStartMoveInfo->mPrevMultiItem = mMultiItemInfo->mPrevMultiItem;
mStartMoveInfo->mNextMultiItem = mMultiItemInfo->mNextMultiItem;
} else {
mStartMoveInfo->mFirstMultiItem = Q_NULLPTR;
mStartMoveInfo->mLastMultiItem = Q_NULLPTR;
mStartMoveInfo->mPrevMultiItem = Q_NULLPTR;
mStartMoveInfo->mNextMultiItem = Q_NULLPTR;
mStartMoveInfo->mFirstMultiItem = nullptr;
mStartMoveInfo->mLastMultiItem = nullptr;
mStartMoveInfo->mPrevMultiItem = nullptr;
mStartMoveInfo->mNextMultiItem = nullptr;
}
if (isMultiItem() && mMultiItemInfo->mNextMultiItem) {
mMultiItemInfo->mNextMultiItem->startMovePrivate();
......@@ -475,7 +475,7 @@ void AgendaItem::resetMovePrivate()
if (!mStartMoveInfo->mFirstMultiItem) {
// This was the first multi-item when the move started, delete all previous
AgendaItem::QPtr toDel = mStartMoveInfo->mPrevMultiItem;
AgendaItem::QPtr nowDel = Q_NULLPTR;
AgendaItem::QPtr nowDel = nullptr;
while (toDel) {
nowDel = toDel;
if (nowDel->moveInfo()) {
......@@ -483,13 +483,13 @@ void AgendaItem::resetMovePrivate()
}
Q_EMIT removeAgendaItem(nowDel);
}
mMultiItemInfo->mFirstMultiItem = Q_NULLPTR;
mMultiItemInfo->mPrevMultiItem = Q_NULLPTR;
mMultiItemInfo->mFirstMultiItem = nullptr;
mMultiItemInfo->mPrevMultiItem = nullptr;
}
if (!mStartMoveInfo->mLastMultiItem) {
// This was the last multi-item when the move started, delete all next
AgendaItem::QPtr toDel = mStartMoveInfo->mNextMultiItem;
AgendaItem::QPtr nowDel = Q_NULLPTR;
AgendaItem::QPtr nowDel = nullptr;
while (toDel) {
nowDel = toDel;
if (nowDel->moveInfo()) {
......@@ -497,18 +497,18 @@ void AgendaItem::resetMovePrivate()
}
Q_EMIT removeAgendaItem(nowDel);
}
mMultiItemInfo->mLastMultiItem = Q_NULLPTR;
mMultiItemInfo->mNextMultiItem = Q_NULLPTR;
mMultiItemInfo->mLastMultiItem = nullptr;
mMultiItemInfo->mNextMultiItem = nullptr;
}
if (mStartMoveInfo->mFirstMultiItem == Q_NULLPTR && mStartMoveInfo->mLastMultiItem == Q_NULLPTR) {
if (mStartMoveInfo->mFirstMultiItem == nullptr && mStartMoveInfo->mLastMultiItem == nullptr) {
// it was a single-day event before we started the move.
delete mMultiItemInfo;
mMultiItemInfo = Q_NULLPTR;
mMultiItemInfo = nullptr;
}
}
delete mStartMoveInfo;
mStartMoveInfo = Q_NULLPTR;
mStartMoveInfo = nullptr;
}
Q_EMIT showAgendaItem(this);
if (nextMultiItem()) {
......@@ -531,7 +531,7 @@ void AgendaItem::endMovePrivate()
// if first, delete all previous
if (!firstMultiItem() || firstMultiItem() == this) {
AgendaItem::QPtr toDel = mStartMoveInfo->mPrevMultiItem;
AgendaItem::QPtr nowDel = Q_NULLPTR;
AgendaItem::QPtr nowDel = nullptr;
while (toDel) {
nowDel = toDel;
if (nowDel->moveInfo()) {
......@@ -543,7 +543,7 @@ void AgendaItem::endMovePrivate()
// if last, delete all next
if (!lastMultiItem() || lastMultiItem() == this) {
AgendaItem::QPtr toDel = mStartMoveInfo->mNextMultiItem;
AgendaItem::QPtr nowDel = Q_NULLPTR;
AgendaItem::QPtr nowDel = nullptr;
while (toDel) {
nowDel = toDel;
if (nowDel->moveInfo()) {
......@@ -554,7 +554,7 @@ void AgendaItem::endMovePrivate()
}
// also delete the moving info
delete mStartMoveInfo;
mStartMoveInfo = Q_NULLPTR;
mStartMoveInfo = nullptr;
if (nextMultiItem()) {
nextMultiItem()->endMovePrivate();
}
......
......@@ -178,20 +178,20 @@ class AgendaView::Private : public Akonadi::ETMCalendar::CalendarObserver
public:
explicit Private(AgendaView *parent, bool isInteractive, bool isSideBySide)
: q(parent),
mTopDayLabels(Q_NULLPTR),
mLayoutTopDayLabels(Q_NULLPTR),
mTopDayLabelsFrame(Q_NULLPTR),
mLayoutBottomDayLabels(Q_NULLPTR),
mBottomDayLabels(Q_NULLPTR),
mBottomDayLabelsFrame(Q_NULLPTR),
mTimeBarHeaderFrame(Q_NULLPTR),
mAllDayAgenda(Q_NULLPTR),
mAgenda(Q_NULLPTR),
mTimeLabelsZone(Q_NULLPTR),
mTopDayLabels(nullptr),
mLayoutTopDayLabels(nullptr),
mTopDayLabelsFrame(nullptr),
mLayoutBottomDayLabels(nullptr),
mBottomDayLabels(nullptr),
mBottomDayLabelsFrame(nullptr),
mTimeBarHeaderFrame(nullptr),
mAllDayAgenda(nullptr),
mAgenda(nullptr),
mTimeLabelsZone(nullptr),
mAllowAgendaUpdate(true),
mUpdateItem(0),
mIsSideBySide(isSideBySide),
mDummyAllDayLeft(Q_NULLPTR),
mDummyAllDayLeft(nullptr),
mUpdateAllDayAgenda(true),
mUpdateAgenda(true),
mIsInteractive(isInteractive),
......@@ -1700,7 +1700,7 @@ void AgendaView::showIncidences(const Akonadi::Item::List &incidences, const QDa
}
if (!wehaveall) {
calendar()->setFilter(Q_NULLPTR);
calendar()->setFilter(nullptr);
}
const KDateTime::Spec timeSpec = preferences()->timeSpec();
......@@ -2312,20 +2312,20 @@ CalendarDecoration::Decoration *AgendaView::Private::loadCalendarDecoration(cons
auto factory = loader.instance();
if (!factory) {
qCDebug(CALENDARVIEW_LOG) << "Factory creation failed";
return Q_NULLPTR;
return nullptr;
}
auto pluginFactory = qobject_cast<CalendarDecoration::DecorationFactory *>(factory);
if (!pluginFactory) {
qCDebug(CALENDARVIEW_LOG) << "Cast failed";
return Q_NULLPTR;
return nullptr;
}
return pluginFactory->createPluginFactory();
}
}
return Q_NULLPTR;
return nullptr;
}
void AgendaView::setChanges(EventView::Changes changes)
......
......@@ -54,7 +54,7 @@ TimeLabels::TimeLabels(const QTimeZone &zone, int rows, TimeLabelsZone *parent,
mMousePos->setFrameStyle(QFrame::HLine | QFrame::Plain);
mMousePos->setFixedSize(width(), 1);
colorMousePos();
mAgenda = Q_NULLPTR;
mAgenda = nullptr;
if (mTimezone.isValid()) {
setToolTip(i18n("Timezone:") + i18n(mTimezone.id().constData()));
......
......@@ -143,7 +143,7 @@ QList<QScrollArea *> TimeLabelsZone::timeLabels() const
void TimeLabelsZone::setAgendaView(AgendaView *agendaView)
{
mParent = agendaView;
mAgenda = agendaView ? agendaView->agenda() : Q_NULLPTR;
mAgenda = agendaView ? agendaView->agenda() : nullptr;
foreach (QScrollArea *timeLabel, mTimeLabelsList) {
setupTimeLabel(timeLabel);
......
......@@ -57,7 +57,7 @@ using namespace KCalCore;
using namespace EventViews;
using namespace Akonadi;
CalendarSupport::CollectionSelection *EventViewPrivate::sGlobalCollectionSelection = Q_NULLPTR;
CalendarSupport::CollectionSelection *EventViewPrivate::sGlobalCollectionSelection = nullptr;
/* static */
void EventView::setGlobalCollectionSelection(CalendarSupport::CollectionSelection *s)
......@@ -425,7 +425,7 @@ KCheckableProxyModel *EventView::takeCustomCollectionSelectionProxyModel()
{
Q_D(EventView);
KCheckableProxyModel *m = d->collectionSelectionModel;
d->collectionSelectionModel = Q_NULLPTR;
d->collectionSelectionModel = nullptr;
d->setUpModels();
return m;
}
......@@ -533,7 +533,7 @@ void EventView::restoreConfig(const KConfigGroup &configGroup)
const bool useCustom = configGroup.readEntry("UseCustomCollectionSelection", false);
if (!d->collectionSelectionModel && !useCustom) {
delete d->collectionSelectionModel;
d->collectionSelectionModel = Q_NULLPTR;
d->collectionSelectionModel = nullptr;
d->setUpModels();
} else if (useCustom) {
......@@ -572,7 +572,7 @@ void EventView::restoreConfig(const KConfigGroup &configGroup)
void EventView::saveConfig(KConfigGroup &configGroup)
{
Q_D(EventView);
configGroup.writeEntry("UseCustomCollectionSelection", d->collectionSelectionModel != Q_NULLPTR);
configGroup.writeEntry("UseCustomCollectionSelection", d->collectionSelectionModel != nullptr);
if (d->collectionSelectionModel) {
KConfigGroup selectionGroup =
......
......@@ -133,7 +133,7 @@ public:
* will be retrieved for display.
* @param parent is the parent QWidget.
*/
explicit EventView(QWidget *parent = Q_NULLPTR);
explicit EventView(QWidget *parent = nullptr);
/**
* Destructor. Views will do view-specific cleanups here.
......
......@@ -37,16 +37,16 @@
using namespace EventViews;
EventViewPrivate::EventViewPrivate()
: calendar(Q_NULLPTR),
customCollectionSelection(Q_NULLPTR),
collectionSelectionModel(Q_NULLPTR),
: calendar(nullptr),
customCollectionSelection(nullptr),
collectionSelectionModel(nullptr),
mReturnPressed(false),
mDateRangeSelectionEnabled(true),
mTypeAhead(false),
mTypeAheadReceiver(Q_NULLPTR),
mTypeAheadReceiver(nullptr),
mPrefs(new Prefs()),
mKCalPrefs(new CalendarSupport::KCalPrefs()),
mChanger(Q_NULLPTR),
mChanger(nullptr),
mChanges(EventView::DatesChanged),
mCollectionId(-1)
{ }
......@@ -71,7 +71,7 @@ void EventViewPrivate::finishTypeAhead()
void EventViewPrivate::setUpModels()
{
delete customCollectionSelection;
customCollectionSelection = Q_NULLPTR;
customCollectionSelection = nullptr;
if (collectionSelectionModel) {
customCollectionSelection = new CalendarSupport::CollectionSelection(collectionSelectionModel->selectionModel());
}
......
......@@ -47,7 +47,7 @@
using namespace EventViews;
JournalDateView::JournalDateView(const Akonadi::ETMCalendar::Ptr &calendar, QWidget *parent)
: QFrame(parent), mCalendar(calendar), mChanger(Q_NULLPTR)
: QFrame(parent), mCalendar(calendar), mChanger(nullptr)
{
auto layout = new QVBoxLayout(this);
layout->setMargin(0);
......@@ -154,7 +154,7 @@ JournalFrame::JournalFrame(const Akonadi::Item &j,
{
mDirty = false;
mWriteInProgress = false;
mChanger = Q_NULLPTR;
mChanger = nullptr;
QVBoxLayout *verticalLayout = new QVBoxLayout(this);
......
......@@ -37,7 +37,7 @@
using namespace EventViews;
JournalView::JournalView(QWidget *parent) : EventView(parent), mChanger(Q_NULLPTR)
JournalView::JournalView(QWidget *parent) : EventView(parent), mChanger(nullptr)
{
QVBoxLayout *topLayout = new QVBoxLayout(this);
topLayout->setMargin(0);
......@@ -59,7 +59,7 @@ JournalView::~JournalView()
void JournalView::appendJournal(const Akonadi::Item &journal, const QDate &dt)
{
JournalDateView *entry = Q_NULLPTR;
JournalDateView *entry = nullptr;
if (mEntries.contains(dt)) {
entry = mEntries[dt];
} else {
......
......@@ -264,7 +264,7 @@ ListView::ListView(const Akonadi::ETMCalendar::Ptr &calendar,
: EventView(parent), d(new Private())
{
setCalendar(calendar);
d->mActiveItem = Q_NULLPTR;
d->mActiveItem = nullptr;
d->mIsNonInteractive = nonInteractive;
d->mTreeWidget = new QTreeWidget(this);
......@@ -312,7 +312,7 @@ int ListView::currentDateCount() const