summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMontel Laurent <[email protected]>2017-08-29 22:02:31 +0200
committerMontel Laurent <[email protected]>2017-08-29 22:02:31 +0200
commitdbdcca9ba68df4c10fc3717dc6cea7e8e839a6d7 (patch)
tree4b9dff40dc06154a03c00acbfe0fd3375a584c22
parentaa453cdc0d66e8dacd22d1dd3497aececdd09b05 (diff)
initialize pointer
-rw-r--r--autotests/dummykernel.h10
-rw-r--r--autotests/foldertreewidgettest.cpp6
-rw-r--r--src/collectionpage/collectionexpirypage.h18
-rw-r--r--src/collectionpage/collectiongeneralpage.cpp2
-rw-r--r--src/collectionpage/collectiongeneralpage.h22
-rw-r--r--src/filter/dialog/filteractionmissingaccountdialog.h2
-rw-r--r--src/filter/dialog/filteractionmissingargumentdialog.h6
-rw-r--r--src/filter/dialog/filteractionmissingidentitydialog.h2
-rw-r--r--src/filter/dialog/filteractionmissingsoundurldialog.h2
-rw-r--r--src/filter/dialog/filteractionmissingtagdialog.h2
-rw-r--r--src/filter/dialog/filteractionmissingtemplatedialog.h2
-rw-r--r--src/filter/dialog/filteractionmissingtransportdialog.h2
-rw-r--r--src/filter/dialog/selectthunderbirdfilterfilesdialog.h2
-rw-r--r--src/filter/dialog/selectthunderbirdfilterfileswidget.h2
-rw-r--r--src/filter/filteractions/filteractionaddtag.h2
-rw-r--r--src/filter/filteractions/filteractionplaysound.h2
-rw-r--r--src/filter/filteractions/filteractionwidget.cpp8
-rw-r--r--src/filter/filteractions/filteractionwithurl.h2
-rw-r--r--src/filter/filterconverter/filterconverttosieveresultdialog.h2
-rw-r--r--src/filter/filterimporter/autotests/filtertestkernel.h10
-rw-r--r--src/filter/filterimporterexporter.cpp2
-rw-r--r--src/filter/filtermanager.cpp2
-rw-r--r--src/filter/filterselectiondialog.h8
-rw-r--r--src/filter/invalidfilters/invalidfilterdialog.h4
-rw-r--r--src/filter/invalidfilters/invalidfilterwidget.h2
-rw-r--r--src/filter/kmfilterdialog.h48
-rw-r--r--src/filter/kmfilterlistbox.h22
-rw-r--r--src/filter/soundtestwidget.h4
-rw-r--r--src/filter/tests/filterimporterexportergui.h2
-rw-r--r--src/folder/accountconfigorderdialog.cpp8
-rw-r--r--src/folder/foldercollectionmonitor.cpp2
-rw-r--r--src/folder/folderrequester.cpp8
-rw-r--r--src/folder/folderselectiondialog.cpp10
-rw-r--r--src/folder/foldertreewidget.cpp16
-rw-r--r--src/job/backupjob.h8
-rw-r--r--src/search/searchpatternedit.h20
-rw-r--r--src/search/widgethandler/tagrulewidgethandler.cpp2
-rw-r--r--src/snippets/snippetdialog.h6
-rw-r--r--src/snippets/snippetsmanager.cpp28
-rw-r--r--src/snippets/snippetsmodel.cpp10
-rw-r--r--src/snippets/snippetsmodel.h2
-rw-r--r--src/snippets/snippetvariabledialog.h6
-rw-r--r--src/tag/addtagdialog.cpp4
-rw-r--r--src/tag/tagwidget.cpp22
-rw-r--r--src/util/resourcereadconfigfile.cpp2
-rw-r--r--src/widgets/favoritecollectionwidget.cpp6
-rw-r--r--src/widgets/redirectdialog.cpp16
-rw-r--r--src/widgets/redirectwidget.h2
48 files changed, 191 insertions, 187 deletions
diff --git a/autotests/dummykernel.h b/autotests/dummykernel.h
index 322d3d2..0b9600d 100644
--- a/autotests/dummykernel.h
+++ b/autotests/dummykernel.h
@@ -38,11 +38,11 @@ public:
void expunge(Akonadi::Collection::Id col, bool sync) override;
private:
- KIdentityManagement::IdentityManager *mIdentityManager;
- MessageComposer::MessageSender *mMessageSender;
- MailCommon::FolderCollectionMonitor *mFolderCollectionMonitor;
- Akonadi::EntityTreeModel *mEntityTreeModel;
- Akonadi::EntityMimeTypeFilterModel *mCollectionModel;
+ KIdentityManagement::IdentityManager *mIdentityManager = nullptr;
+ MessageComposer::MessageSender *mMessageSender = nullptr;
+ MailCommon::FolderCollectionMonitor *mFolderCollectionMonitor = nullptr;
+ Akonadi::EntityTreeModel *mEntityTreeModel = nullptr;
+ Akonadi::EntityMimeTypeFilterModel *mCollectionModel = nullptr;
};
#endif
diff --git a/autotests/foldertreewidgettest.cpp b/autotests/foldertreewidgettest.cpp
index 23c93eb..dc6a313 100644
--- a/autotests/foldertreewidgettest.cpp
+++ b/autotests/foldertreewidgettest.cpp
@@ -255,9 +255,9 @@ private:
}
static QStringList collectNames(QAbstractItemModel *model);
- EntityMimeTypeFilterModel *mCollectionModel;
- QAbstractItemModel *mTopModel;
- MailCommon::FolderTreeWidget *mFolderTreeWidget;
+ EntityMimeTypeFilterModel *mCollectionModel = nullptr;
+ QAbstractItemModel *mTopModel = nullptr;
+ MailCommon::FolderTreeWidget *mFolderTreeWidget = nullptr;
QStringList mFolderNames;
};
diff --git a/src/collectionpage/collectionexpirypage.h b/src/collectionpage/collectionexpirypage.h
index 85cf744..430f698 100644
--- a/src/collectionpage/collectionexpirypage.h
+++ b/src/collectionpage/collectionexpirypage.h
@@ -59,17 +59,17 @@ private:
void saveAndExpire(Akonadi::Collection &collection, bool saveSettings, bool _expirenow);
private:
- QCheckBox *expireReadMailCB;
- KPluralHandlingSpinBox *expireReadMailSB;
- QCheckBox *expireUnreadMailCB;
- KPluralHandlingSpinBox *expireUnreadMailSB;
- QRadioButton *moveToRB;
- FolderRequester *folderSelector;
- QRadioButton *deletePermanentlyRB;
- QPushButton *expireNowPB;
+ QCheckBox *expireReadMailCB = nullptr;
+ KPluralHandlingSpinBox *expireReadMailSB = nullptr;
+ QCheckBox *expireUnreadMailCB = nullptr;
+ KPluralHandlingSpinBox *expireUnreadMailSB = nullptr;
+ QRadioButton *moveToRB = nullptr;
+ FolderRequester *folderSelector = nullptr;
+ QRadioButton *deletePermanentlyRB = nullptr;
+ QPushButton *expireNowPB = nullptr;
Akonadi::Collection mCollection;
- bool mChanged;
+ bool mChanged = false;
};
AKONADI_COLLECTION_PROPERTIES_PAGE_FACTORY(CollectionExpiryPageFactory, CollectionExpiryPage)
diff --git a/src/collectionpage/collectiongeneralpage.cpp b/src/collectionpage/collectiongeneralpage.cpp
index ad03711..4e592e4 100644
--- a/src/collectionpage/collectiongeneralpage.cpp
+++ b/src/collectionpage/collectiongeneralpage.cpp
@@ -82,7 +82,7 @@ void CollectionGeneralPage::init(const Akonadi::Collection &collection)
|| Kernel::folderIsInbox(collection);
mIsResourceFolder = (collection.parentCollection() == Akonadi::Collection::root());
- QLabel *label;
+ QLabel *label = nullptr;
QVBoxLayout *topLayout = new QVBoxLayout(this);
diff --git a/src/collectionpage/collectiongeneralpage.h b/src/collectionpage/collectiongeneralpage.h
index 90be602..70d155f 100644
--- a/src/collectionpage/collectiongeneralpage.h
+++ b/src/collectionpage/collectiongeneralpage.h
@@ -59,18 +59,18 @@ private Q_SLOTS:
private:
void addLine(QWidget *parent, QVBoxLayout *layout);
QString mColorName;
- PimCommon::ContentTypeWidget *mContentsComboBox;
- PimCommon::IncidencesForWidget *mIncidencesForComboBox;
- QCheckBox *mSharedSeenFlagsCheckBox;
- QCheckBox *mNotifyOnNewMailCheckBox;
- QCheckBox *mKeepRepliesInSameFolderCheckBox;
- QCheckBox *mHideInSelectionDialogCheckBox;
- QCheckBox *mUseDefaultIdentityCheckBox;
- KLineEdit *mNameEdit;
- KIdentityManagement::IdentityCombo *mIdentityComboBox;
+ PimCommon::ContentTypeWidget *mContentsComboBox = nullptr;
+ PimCommon::IncidencesForWidget *mIncidencesForComboBox = nullptr;
+ QCheckBox *mSharedSeenFlagsCheckBox = nullptr;
+ QCheckBox *mNotifyOnNewMailCheckBox = nullptr;
+ QCheckBox *mKeepRepliesInSameFolderCheckBox = nullptr;
+ QCheckBox *mHideInSelectionDialogCheckBox = nullptr;
+ QCheckBox *mUseDefaultIdentityCheckBox = nullptr;
+ KLineEdit *mNameEdit = nullptr;
+ KIdentityManagement::IdentityCombo *mIdentityComboBox = nullptr;
QSharedPointer<MailCommon::FolderSettings> mFolderCollection;
- bool mIsLocalSystemFolder;
- bool mIsResourceFolder;
+ bool mIsLocalSystemFolder = false;
+ bool mIsResourceFolder = false;
};
AKONADI_COLLECTION_PROPERTIES_PAGE_FACTORY(CollectionGeneralPageFactory, CollectionGeneralPage)
diff --git a/src/filter/dialog/filteractionmissingaccountdialog.h b/src/filter/dialog/filteractionmissingaccountdialog.h
index ddbcf1d..d33e713 100644
--- a/src/filter/dialog/filteractionmissingaccountdialog.h
+++ b/src/filter/dialog/filteractionmissingaccountdialog.h
@@ -35,7 +35,7 @@ public:
private:
void readConfig();
void writeConfig();
- MailCommon::KMFilterAccountList *mAccountList;
+ MailCommon::KMFilterAccountList *mAccountList = nullptr;
};
}
#endif // FILTERACTIONMISSINGACCOUNTDIALOG_H
diff --git a/src/filter/dialog/filteractionmissingargumentdialog.h b/src/filter/dialog/filteractionmissingargumentdialog.h
index 5461b66..349e363 100644
--- a/src/filter/dialog/filteractionmissingargumentdialog.h
+++ b/src/filter/dialog/filteractionmissingargumentdialog.h
@@ -58,9 +58,9 @@ private:
private:
void writeConfig();
void readConfig();
- MailCommon::FolderRequester *mFolderRequester;
- QListWidget *mListwidget;
- QPushButton *mOkButton;
+ MailCommon::FolderRequester *mFolderRequester = nullptr;
+ QListWidget *mListwidget = nullptr;
+ QPushButton *mOkButton = nullptr;
};
#endif /* FILTERACTIONMISSINGARGUMENTDIALOG_H */
diff --git a/src/filter/dialog/filteractionmissingidentitydialog.h b/src/filter/dialog/filteractionmissingidentitydialog.h
index 9c5d77e..d91c007 100644
--- a/src/filter/dialog/filteractionmissingidentitydialog.h
+++ b/src/filter/dialog/filteractionmissingidentitydialog.h
@@ -37,7 +37,7 @@ public:
private:
void writeConfig();
void readConfig();
- KIdentityManagement::IdentityCombo *mComboBoxIdentity;
+ KIdentityManagement::IdentityCombo *mComboBoxIdentity = nullptr;
};
}
diff --git a/src/filter/dialog/filteractionmissingsoundurldialog.h b/src/filter/dialog/filteractionmissingsoundurldialog.h
index f57d138..6b04682 100644
--- a/src/filter/dialog/filteractionmissingsoundurldialog.h
+++ b/src/filter/dialog/filteractionmissingsoundurldialog.h
@@ -34,7 +34,7 @@ public:
private:
void readConfig();
void writeConfig();
- KUrlRequester *mUrlWidget;
+ KUrlRequester *mUrlWidget = nullptr;
};
}
diff --git a/src/filter/dialog/filteractionmissingtagdialog.h b/src/filter/dialog/filteractionmissingtagdialog.h
index fbf777a..59ea46a 100644
--- a/src/filter/dialog/filteractionmissingtagdialog.h
+++ b/src/filter/dialog/filteractionmissingtagdialog.h
@@ -41,7 +41,7 @@ private:
enum TypeData {
UrlData = Qt::UserRole + 1
};
- QListWidget *mTagList;
+ QListWidget *mTagList = nullptr;
};
}
#endif // FILTERACTIONMISSINGTAGDIALOG_H
diff --git a/src/filter/dialog/filteractionmissingtemplatedialog.h b/src/filter/dialog/filteractionmissingtemplatedialog.h
index c0e0da1..d510702 100644
--- a/src/filter/dialog/filteractionmissingtemplatedialog.h
+++ b/src/filter/dialog/filteractionmissingtemplatedialog.h
@@ -35,7 +35,7 @@ public:
private:
void readConfig();
void writeConfig();
- KComboBox *mComboBoxTemplate;
+ KComboBox *mComboBoxTemplate = nullptr;
};
}
#endif // FILTERACTIONMISSINGTEMPLATEDIALOG_H
diff --git a/src/filter/dialog/filteractionmissingtransportdialog.h b/src/filter/dialog/filteractionmissingtransportdialog.h
index 67dd5cb..f77f90c 100644
--- a/src/filter/dialog/filteractionmissingtransportdialog.h
+++ b/src/filter/dialog/filteractionmissingtransportdialog.h
@@ -37,7 +37,7 @@ public:
private:
void writeConfig();
void readConfig();
- MailTransport::TransportComboBox *mComboBoxTransport;
+ MailTransport::TransportComboBox *mComboBoxTransport = nullptr;
};
}
diff --git a/src/filter/dialog/selectthunderbirdfilterfilesdialog.h b/src/filter/dialog/selectthunderbirdfilterfilesdialog.h
index d9add23..f62a198 100644
--- a/src/filter/dialog/selectthunderbirdfilterfilesdialog.h
+++ b/src/filter/dialog/selectthunderbirdfilterfilesdialog.h
@@ -37,7 +37,7 @@ public:
private:
void readConfig();
void writeConfig();
- SelectThunderbirdFilterFilesWidget *mSelectFilterFilesWidget;
+ SelectThunderbirdFilterFilesWidget *mSelectFilterFilesWidget = nullptr;
};
}
diff --git a/src/filter/dialog/selectthunderbirdfilterfileswidget.h b/src/filter/dialog/selectthunderbirdfilterfileswidget.h
index 55b296e..28922c4 100644
--- a/src/filter/dialog/selectthunderbirdfilterfileswidget.h
+++ b/src/filter/dialog/selectthunderbirdfilterfileswidget.h
@@ -47,7 +47,7 @@ private Q_SLOTS:
void slotUrlChanged(const QString &path);
void slotItemSelectionChanged();
private:
- Ui::SelectThunderbirdFilterFilesWidget *ui;
+ Ui::SelectThunderbirdFilterFilesWidget *ui = nullptr;
};
}
#endif // SELECTTHUNDERBIRDFILTERFILESWIDGET_H
diff --git a/src/filter/filteractions/filteractionaddtag.h b/src/filter/filteractions/filteractionaddtag.h
index 3af9ecc..5b4973b 100644
--- a/src/filter/filteractions/filteractionaddtag.h
+++ b/src/filter/filteractions/filteractionaddtag.h
@@ -62,7 +62,7 @@ private:
void initializeTagList();
mutable QMap<QUrl, QString> mList;
QString mParameter;
- mutable PimCommon::MinimumComboBox *mComboBox;
+ mutable PimCommon::MinimumComboBox *mComboBox = nullptr;
};
}
diff --git a/src/filter/filteractions/filteractionplaysound.h b/src/filter/filteractions/filteractionplaysound.h
index 0861a1a..c0cda8b 100644
--- a/src/filter/filteractions/filteractionplaysound.h
+++ b/src/filter/filteractions/filteractionplaysound.h
@@ -45,7 +45,7 @@ public:
bool isEmpty() const override;
QString informationAboutNotValidAction() const override;
private:
- mutable Phonon::MediaObject *mPlayer;
+ mutable Phonon::MediaObject *mPlayer = nullptr;
};
}
diff --git a/src/filter/filteractions/filteractionwidget.cpp b/src/filter/filteractions/filteractionwidget.cpp
index be0031d..474125c 100644
--- a/src/filter/filteractions/filteractionwidget.cpp
+++ b/src/filter/filteractions/filteractionwidget.cpp
@@ -66,11 +66,11 @@ public:
FilterActionWidget *q;
QList<MailCommon::FilterAction *> mActionList;
- KComboBox *mComboBox;
- QPushButton *mAdd;
- QPushButton *mRemove;
+ KComboBox *mComboBox = nullptr;
+ QPushButton *mAdd = nullptr;
+ QPushButton *mRemove = nullptr;
- QGridLayout *mLayout;
+ QGridLayout *mLayout = nullptr;
};
void FilterActionWidget::Private::setFilterAction(QWidget *widget)
diff --git a/src/filter/filteractions/filteractionwithurl.h b/src/filter/filteractions/filteractionwithurl.h
index 4a583d3..508af59 100644
--- a/src/filter/filteractions/filteractionwithurl.h
+++ b/src/filter/filteractions/filteractionwithurl.h
@@ -109,7 +109,7 @@ public:
protected:
QString mParameter;
private:
- mutable FilterActionWithUrlHelpButton *mHelpButton;
+ mutable FilterActionWithUrlHelpButton *mHelpButton = nullptr;
private Q_SLOTS:
void slotHelp();
};
diff --git a/src/filter/filterconverter/filterconverttosieveresultdialog.h b/src/filter/filterconverter/filterconverttosieveresultdialog.h
index 359b0e0..6ab9ce2 100644
--- a/src/filter/filterconverter/filterconverttosieveresultdialog.h
+++ b/src/filter/filterconverter/filterconverttosieveresultdialog.h
@@ -40,7 +40,7 @@ private Q_SLOTS:
private:
void readConfig();
void writeConfig();
- KPIMTextEdit::PlainTextEditorWidget *mEditor;
+ KPIMTextEdit::PlainTextEditorWidget *mEditor = nullptr;
};
}
diff --git a/src/filter/filterimporter/autotests/filtertestkernel.h b/src/filter/filterimporter/autotests/filtertestkernel.h
index 58f44ad..1a8760d 100644
--- a/src/filter/filterimporter/autotests/filtertestkernel.h
+++ b/src/filter/filterimporter/autotests/filtertestkernel.h
@@ -52,11 +52,11 @@ public:
void expunge(Akonadi::Collection::Id col, bool sync) override;
private:
- KIdentityManagement::IdentityManager *mIdentityManager;
- MessageComposer::MessageSender *mMessageSender;
- MailCommon::FolderCollectionMonitor *mFolderCollectionMonitor;
- Akonadi::EntityTreeModel *mEntityTreeModel;
- Akonadi::EntityMimeTypeFilterModel *mCollectionModel;
+ KIdentityManagement::IdentityManager *mIdentityManager = nullptr;
+ MessageComposer::MessageSender *mMessageSender = nullptr;
+ MailCommon::FolderCollectionMonitor *mFolderCollectionMonitor = nullptr;
+ Akonadi::EntityTreeModel *mEntityTreeModel = nullptr;
+ Akonadi::EntityMimeTypeFilterModel *mCollectionModel = nullptr;
};
#endif
diff --git a/src/filter/filterimporterexporter.cpp b/src/filter/filterimporterexporter.cpp
index e626c16..6cd45a2 100644
--- a/src/filter/filterimporterexporter.cpp
+++ b/src/filter/filterimporterexporter.cpp
@@ -131,7 +131,7 @@ public:
}
void warningInfoAboutInvalidFilter(const QStringList &emptyFilters) const;
- QWidget *mParent;
+ QWidget *mParent = nullptr;
};
void FilterImporterExporter::Private::warningInfoAboutInvalidFilter(
diff --git a/src/filter/filtermanager.cpp b/src/filter/filtermanager.cpp
index 9753a38..acdba46 100644
--- a/src/filter/filtermanager.cpp
+++ b/src/filter/filtermanager.cpp
@@ -59,7 +59,7 @@ public:
static FilterActionDict *mFilterActionDict;
FilterManager *q;
- OrgFreedesktopAkonadiMailFilterAgentInterface *mMailFilterAgentInterface;
+ OrgFreedesktopAkonadiMailFilterAgentInterface *mMailFilterAgentInterface = nullptr;
QList<MailCommon::MailFilter *> mFilters;
Akonadi::Monitor *mMonitor;
bool mInitialized;
diff --git a/src/filter/filterselectiondialog.h b/src/filter/filterselectiondialog.h
index 81cf3f3..d904b03 100644
--- a/src/filter/filterselectiondialog.h
+++ b/src/filter/filterselectiondialog.h
@@ -49,11 +49,11 @@ public Q_SLOTS:
private:
void writeConfig();
void readConfig();
- QListWidget *filtersListWidget;
+ QListWidget *filtersListWidget = nullptr;
QList<MailFilter *> originalFilters;
- QPushButton *selectAllButton;
- QPushButton *unselectAllButton;
- QPushButton *mOkButton;
+ QPushButton *selectAllButton = nullptr;
+ QPushButton *unselectAllButton = nullptr;
+ QPushButton *mOkButton = nullptr;
};
}
#endif // FILTERSELECTIONDIALOG_H
diff --git a/src/filter/invalidfilters/invalidfilterdialog.h b/src/filter/invalidfilters/invalidfilterdialog.h
index 2c9966f..d334fc0 100644
--- a/src/filter/invalidfilters/invalidfilterdialog.h
+++ b/src/filter/invalidfilters/invalidfilterdialog.h
@@ -36,8 +36,8 @@ public:
private:
void writeConfig();
void readConfig();
- InvalidFilterWidget *mInvalidFilterWidget;
- InvalidFilterInfoWidget *mInvalidFilterInfoWidget;
+ InvalidFilterWidget *mInvalidFilterWidget = nullptr;
+ InvalidFilterInfoWidget *mInvalidFilterInfoWidget = nullptr;
};
}
#endif // INVALIDFILTERDIALOG_H
diff --git a/src/filter/invalidfilters/invalidfilterwidget.h b/src/filter/invalidfilters/invalidfilterwidget.h
index 104acef..0caa3ce 100644
--- a/src/filter/invalidfilters/invalidfilterwidget.h
+++ b/src/filter/invalidfilters/invalidfilterwidget.h
@@ -36,7 +36,7 @@ Q_SIGNALS:
void showDetails(const QString &);
void hideInformationWidget();
private:
- InvalidFilterListView *mInvalidFilterListWidget;
+ InvalidFilterListView *mInvalidFilterListWidget = nullptr;
};
}
diff --git a/src/filter/kmfilterdialog.h b/src/filter/kmfilterdialog.h
index fa60562..9ec819b 100644
--- a/src/filter/kmfilterdialog.h
+++ b/src/filter/kmfilterdialog.h
@@ -214,39 +214,45 @@ protected:
/** The widget that contains the ListBox showing the filters, and the
controls to remove filters, add new ones and to change their order. */
- KMFilterListBox *mFilterList;
+ KMFilterListBox *mFilterList = nullptr;
/** The widget that allows editing of the filter pattern. */
- MailCommon::SearchPatternEdit *mPatternEdit;
+ MailCommon::SearchPatternEdit *mPatternEdit = nullptr;
/** The widget that allows editing of the filter actions. */
- MailCommon::FilterActionWidgetLister *mActionLister;
+ MailCommon::FilterActionWidgetLister *mActionLister = nullptr;
/** Lets the user select whether to apply this filter on
inbound/outbound messages, both, or only on explicit CTRL-J. */
- QCheckBox *mApplyOnIn, *mApplyOnOut, *mApplyBeforeOut, *mApplyOnCtrlJ, *mApplyOnAllFolders;
+ QCheckBox *mApplyOnIn = nullptr;
+ QCheckBox *mApplyOnOut = nullptr;
+ QCheckBox *mApplyBeforeOut = nullptr;
+ QCheckBox *mApplyOnCtrlJ = nullptr;
+ QCheckBox *mApplyOnAllFolders = nullptr;
/** For a filter applied to inbound messages selects whether to apply
this filter to all accounts or to selected accounts only. */
- QRadioButton *mApplyOnForAll, *mApplyOnForTraditional, *mApplyOnForChecked;
+ QRadioButton *mApplyOnForAll = nullptr;
+ QRadioButton *mApplyOnForTraditional = nullptr;
+ QRadioButton *mApplyOnForChecked = nullptr;
/** ListView that shows the accounts in the advanced tab */
- KMFilterAccountList *mAccountList;
-
- QCheckBox *mStopProcessingHere;
- QCheckBox *mConfigureShortcut;
- QCheckBox *mConfigureToolbar;
- QLabel *mFilterActionLabel;
- KIconButton *mFilterActionIconButton;
- KKeySequenceWidget *mKeySeqWidget;
- QGroupBox *mAdvOptsGroup;
-
- MailCommon::MailFilter *mFilter;
- MailCommon::FolderRequester *mFolderRequester;
- QPushButton *mRunNow;
- QDialogButtonBox *buttonBox;
- bool mDoNotClose;
- bool mIgnoreFilterUpdates;
+ KMFilterAccountList *mAccountList = nullptr;
+
+ QCheckBox *mStopProcessingHere = nullptr;
+ QCheckBox *mConfigureShortcut = nullptr;
+ QCheckBox *mConfigureToolbar = nullptr;
+ QLabel *mFilterActionLabel = nullptr;
+ KIconButton *mFilterActionIconButton = nullptr;
+ KKeySequenceWidget *mKeySeqWidget = nullptr;
+ QGroupBox *mAdvOptsGroup = nullptr;
+
+ MailCommon::MailFilter *mFilter = nullptr;
+ MailCommon::FolderRequester *mFolderRequester = nullptr;
+ QPushButton *mRunNow = nullptr;
+ QDialogButtonBox *buttonBox = nullptr;
+ bool mDoNotClose = false;
+ bool mIgnoreFilterUpdates = false;
};
}
diff --git a/src/filter/kmfilterlistbox.h b/src/filter/kmfilterlistbox.h
index c848ce9..76a44c3 100644
--- a/src/filter/kmfilterlistbox.h
+++ b/src/filter/kmfilterlistbox.h
@@ -62,7 +62,7 @@ public:
MailCommon::MailFilter *filter();
private:
- MailCommon::MailFilter *mFilter;
+ MailCommon::MailFilter *mFilter = nullptr;
};
class KMFilterListBox : public QGroupBox
@@ -231,18 +231,18 @@ protected Q_SLOTS:
protected:
/** The listbox displaying the filter list. */
- QListWidget *mListWidget;
+ QListWidget *mListWidget = nullptr;
/** The various action buttons. */
- QPushButton *mBtnNew;
- QPushButton *mBtnCopy;
- QPushButton *mBtnDelete;
- QPushButton *mBtnUp;
- QPushButton *mBtnDown;
- QPushButton *mBtnRename;
- QPushButton *mBtnTop;
- QPushButton *mBtnBottom;
- KListWidgetSearchLine *mSearchListWidget;
+ QPushButton *mBtnNew = nullptr;
+ QPushButton *mBtnCopy = nullptr;
+ QPushButton *mBtnDelete = nullptr;
+ QPushButton *mBtnUp = nullptr;
+ QPushButton *mBtnDown = nullptr;
+ QPushButton *mBtnRename = nullptr;
+ QPushButton *mBtnTop = nullptr;
+ QPushButton *mBtnBottom = nullptr;
+ KListWidgetSearchLine *mSearchListWidget = nullptr;
bool eventFilter(QObject *obj, QEvent *event) override;
private:
void applyFilterChanged(bool closeAfterSaving);
diff --git a/src/filter/soundtestwidget.h b/src/filter/soundtestwidget.h
index 6099a6f..14fc455 100644
--- a/src/filter/soundtestwidget.h
+++ b/src/filter/soundtestwidget.h
@@ -78,8 +78,8 @@ private:
void playSound();
void openSoundDialog(KUrlRequester *);
void slotUrlChanged(const QString &);
- KUrlRequester *m_urlRequester;
- QPushButton *m_playButton;
+ KUrlRequester *m_urlRequester = nullptr;
+ QPushButton *m_playButton = nullptr;
};
}
diff --git a/src/filter/tests/filterimporterexportergui.h b/src/filter/tests/filterimporterexportergui.h
index 7e9ba12..47e9416 100644
--- a/src/filter/tests/filterimporterexportergui.h
+++ b/src/filter/tests/filterimporterexportergui.h
@@ -31,7 +31,7 @@ private Q_SLOTS:
void slotImportFilter(QAction *act);
private:
void importFilters(MailCommon::FilterImporterExporter::FilterType type);
- QTextEdit *mTextEdit;
+ QTextEdit *mTextEdit = nullptr;
};
#endif // FILTERIMPORTEREXPORTERGUI_H
diff --git a/src/folder/accountconfigorderdialog.cpp b/src/folder/accountconfigorderdialog.cpp
index ad63451..eb0426a 100644
--- a/src/folder/accountconfigorderdialog.cpp
+++ b/src/folder/accountconfigorderdialog.cpp
@@ -58,10 +58,10 @@ public:
{
}
- QListWidget *mListAccount;
- QPushButton *mUpButton;
- QPushButton *mDownButton;
- QCheckBox *mEnableAccountOrder;
+ QListWidget *mListAccount = nullptr;
+ QPushButton *mUpButton = nullptr;
+ QPushButton *mDownButton = nullptr;
+ QCheckBox *mEnableAccountOrder = nullptr;
};
AccountConfigOrderDialog::AccountConfigOrderDialog(QWidget *parent)
diff --git a/src/folder/foldercollectionmonitor.cpp b/src/folder/foldercollectionmonitor.cpp
index 25c0d9e..1007e1d 100644
--- a/src/folder/foldercollectionmonitor.cpp
+++ b/src/folder/foldercollectionmonitor.cpp
@@ -43,7 +43,7 @@ public:
{
}
- Akonadi::ChangeRecorder *mMonitor;
+ Akonadi::ChangeRecorder *mMonitor = nullptr;
};
FolderCollectionMonitor::FolderCollectionMonitor(Akonadi::Session *session, QObject *parent)
diff --git a/src/folder/folderrequester.cpp b/src/folder/folderrequester.cpp
index 118b5d4..5a2a888 100644
--- a/src/folder/folderrequester.cpp
+++ b/src/folder/folderrequester.cpp
@@ -58,10 +58,10 @@ public:
}
Akonadi::Collection mCollection;
- KLineEdit *mEdit;
- bool mMustBeReadWrite;
- bool mShowOutbox;
- bool mNotCreateNewFolder;
+ KLineEdit *mEdit = nullptr;
+ bool mMustBeReadWrite = false;
+ bool mShowOutbox = false;
+ bool mNotCreateNewFolder = false;
};
FolderRequester::FolderRequester(QWidget *parent)
diff --git a/src/folder/folderselectiondialog.cpp b/src/folder/folderselectiondialog.cpp
index 4db6c8c..4c0f3b9 100644
--- a/src/folder/folderselectiondialog.cpp
+++ b/src/folder/folderselectiondialog.cpp
@@ -53,11 +53,11 @@ public:
{
}
- FolderTreeWidget *folderTreeWidget;
- QPushButton *mUser1Button;
- QPushButton *mOkButton;
- bool mNotAllowToCreateNewFolder;
- bool mUseGlobalSettings;
+ FolderTreeWidget *folderTreeWidget = nullptr;
+ QPushButton *mUser1Button = nullptr;
+ QPushButton *mOkButton = nullptr;
+ bool mNotAllowToCreateNewFolder = false;
+ bool mUseGlobalSettings = false;
};
FolderSelectionDialog::FolderSelectionDialog(QWidget *parent, SelectionFolderOptions options)
diff --git a/src/folder/foldertreewidget.cpp b/src/folder/foldertreewidget.cpp
index 7ffc112..ef593f5 100644
--- a/src/folder/foldertreewidget.cpp
+++ b/src/folder/foldertreewidget.cpp
@@ -70,17 +70,17 @@ public:
QString filter;
QString oldFilterStr;
- Akonadi::StatisticsProxyModel *filterModel;
- FolderTreeView *folderTreeView;
- Akonadi::QuotaColorProxyModel *quotaModel;
- FolderTreeWidgetProxyModel *readableproxy;
- EntityCollectionOrderProxyModel *entityOrderProxy;
- QLineEdit *filterFolderLineEdit;
+ Akonadi::StatisticsProxyModel *filterModel = nullptr;
+ FolderTreeView *folderTreeView = nullptr;
+ Akonadi::QuotaColorProxyModel *quotaModel = nullptr;
+ FolderTreeWidgetProxyModel *readableproxy = nullptr;
+ EntityCollectionOrderProxyModel *entityOrderProxy = nullptr;
+ QLineEdit *filterFolderLineEdit = nullptr;
QPointer<Akonadi::ETMViewStateSaver> saver;
QStringList expandedItems;
QString currentItem;
- QLabel *label;
- bool dontKeyFilter;
+ QLabel *label = nullptr;
+ bool dontKeyFilter = false;
};
FolderTreeWidget::FolderTreeWidget(
diff --git a/src/job/backupjob.h b/src/job/backupjob.h
index de0e3df..9df5ca1 100644
--- a/src/job/backupjob.h
+++ b/src/job/backupjob.h
@@ -105,8 +105,8 @@ private:
QDateTime mArchiveTime;
ArchiveType mArchiveType;
Akonadi::Collection mRootFolder;
- KArchive *mArchive;
- QWidget *mParentWidget;
+ KArchive *mArchive = nullptr;
+ QWidget *mParentWidget = nullptr;
int mArchivedMessages;
uint mArchivedSize;
QPointer<KPIM::ProgressItem> mProgressItem;
@@ -118,8 +118,8 @@ private:
Akonadi::Collection::List mAllFolders;
Akonadi::Collection mCurrentFolder;
Akonadi::Item::List mPendingMessages;
- Akonadi::ItemFetchJob *mCurrentJob;
- bool mDisplayMessageBox;
+ Akonadi::ItemFetchJob *mCurrentJob = nullptr;
+ bool mDisplayMessageBox = false;
};
}
diff --git a/src/search/searchpatternedit.h b/src/search/searchpatternedit.h
index 8bb7025..e414db8 100644
--- a/src/search/searchpatternedit.h
+++ b/src/search/searchpatternedit.h
@@ -143,11 +143,11 @@ private Q_SLOTS:
private:
void initLayout(SearchPatternEditOptions options, SearchModeType modeType);
- MailCommon::SearchPattern *mPattern;
- QRadioButton *mAllRBtn;
- QRadioButton *mAnyRBtn;
- QRadioButton *mAllMessageRBtn;
- SearchRuleWidgetLister *mRuleLister;
+ MailCommon::SearchPattern *mPattern = nullptr;
+ QRadioButton *mAllRBtn = nullptr;
+ QRadioButton *mAnyRBtn = nullptr;
+ QRadioButton *mAllMessageRBtn = nullptr;
+ SearchRuleWidgetLister *mRuleLister = nullptr;
};
/**
@@ -267,11 +267,11 @@ private:
void initFieldList(MailCommon::SearchPatternEdit::SearchPatternEditOptions options);
QStringList mFilterFieldList;
- KComboBox *mRuleField;
- QStackedWidget *mFunctionStack;
- QStackedWidget *mValueStack;
- QPushButton *mAdd;
- QPushButton *mRemove;
+ KComboBox *mRuleField = nullptr;
+ QStackedWidget *mFunctionStack = nullptr;
+ QStackedWidget *mValueStack = nullptr;
+ QPushButton *mAdd = nullptr;
+ QPushButton *mRemove = nullptr;
};
class SearchRuleWidgetLister : public KPIM::KWidgetLister
diff --git a/src/search/widgethandler/tagrulewidgethandler.cpp b/src/search/widgethandler/tagrulewidgethandler.cpp
index 272e492..78f60f5 100644
--- a/src/search/widgethandler/tagrulewidgethandler.cpp
+++ b/src/search/widgethandler/tagrulewidgethandler.cpp
@@ -46,7 +46,7 @@ private Q_SLOTS:
void onTagsFetched(KJob *);
private:
- KComboBox *mComboBox;
+ KComboBox *mComboBox = nullptr;
};
FillTagComboJob::FillTagComboJob(KComboBox *combo, QObject *parent)
diff --git a/src/snippets/snippetdialog.h b/src/snippets/snippetdialog.h
index 152892b..2ad7b16 100644
--- a/src/snippets/snippetdialog.h
+++ b/src/snippets/snippetdialog.h
@@ -56,9 +56,9 @@ private Q_SLOTS:
private:
bool snippetIsValid() const;
- KActionCollection *mActionCollection;
- Ui::SnippetDialog *mUi;
- QPushButton *mOkButton;
+ KActionCollection *mActionCollection = nullptr;
+ Ui::SnippetDialog *mUi = nullptr;
+ QPushButton *mOkButton = nullptr;
};
}
#endif
diff --git a/src/snippets/snippetsmanager.cpp b/src/snippets/snippetsmanager.cpp
index 7d31c8b..7c8e940 100644
--- a/src/snippets/snippetsmanager.cpp
+++ b/src/snippets/snippetsmanager.cpp
@@ -87,23 +87,23 @@ public:
void load();
void save();
- SnippetsManager *q;
- SnippetsModel *mModel;
- QItemSelectionModel *mSelectionModel;
- KActionCollection *mActionCollection;
- QObject *mEditor;
+ SnippetsManager *q = nullptr;
+ SnippetsModel *mModel = nullptr;
+ QItemSelectionModel *mSelectionModel = nullptr;
+ KActionCollection *mActionCollection = nullptr;
+ QObject *mEditor = nullptr;
QByteArray mEditorInsertMethod;
QMap<QString, QString> mSavedVariables;
- QAction *mAddSnippetAction;
- QAction *mEditSnippetAction;
- QAction *mDeleteSnippetAction;
- QAction *mAddSnippetGroupAction;
- QAction *mEditSnippetGroupAction;
- QAction *mDeleteSnippetGroupAction;
- QAction *mInsertSnippetAction;
- QWidget *mParent;
- bool mDirty;
+ QAction *mAddSnippetAction = nullptr;
+ QAction *mEditSnippetAction = nullptr;
+ QAction *mDeleteSnippetAction = nullptr;
+ QAction *mAddSnippetGroupAction = nullptr;
+ QAction *mEditSnippetGroupAction = nullptr;
+ QAction *mDeleteSnippetGroupAction = nullptr;
+ QAction *mInsertSnippetAction = nullptr;
+ QWidget *mParent = nullptr;
+ bool mDirty = false;
};
QModelIndex SnippetsManager::Private::currentGroupIndex() const
diff --git a/src/snippets/snippetsmodel.cpp b/src/snippets/snippetsmodel.cpp
index fdd0640..8715f74 100644
--- a/src/snippets/snippetsmodel.cpp
+++ b/src/snippets/snippetsmodel.cpp
@@ -55,7 +55,7 @@ public:
private:
QList<SnippetItem *> mChildItems;
- SnippetItem *mParentItem;
+ SnippetItem *mParentItem = nullptr;
bool mIsGroup;
QString mName;
@@ -243,7 +243,7 @@ QModelIndex SnippetsModel::index(int row, int column, const QModelIndex &parent)
return QModelIndex();
}
- SnippetItem *parentItem;
+ SnippetItem *parentItem = nullptr;
if (!parent.isValid()) {
parentItem = mRootItem;
@@ -277,7 +277,7 @@ QModelIndex SnippetsModel::parent(const QModelIndex &index) const
int SnippetsModel::rowCount(const QModelIndex &parent) const
{
- SnippetItem *parentItem;
+ SnippetItem *parentItem = nullptr;
if (parent.column() > 0) {
return 0;
}
@@ -293,7 +293,7 @@ int SnippetsModel::rowCount(const QModelIndex &parent) const
bool SnippetsModel::insertRows(int row, int count, const QModelIndex &parent)
{
- SnippetItem *parentItem;
+ SnippetItem *parentItem = nullptr;
if (!parent.isValid()) {
parentItem = mRootItem;
@@ -313,7 +313,7 @@ bool SnippetsModel::insertRows(int row, int count, const QModelIndex &parent)
bool SnippetsModel::removeRows(int row, int count, const QModelIndex &parent)
{
- SnippetItem *parentItem;
+ SnippetItem *parentItem = nullptr;
if (!parent.isValid()) {
parentItem = mRootItem;
diff --git a/src/snippets/snippetsmodel.h b/src/snippets/snippetsmodel.h
index d74b866..e519969 100644
--- a/src/snippets/snippetsmodel.h
+++ b/src/snippets/snippetsmodel.h
@@ -72,7 +72,7 @@ Q_SIGNALS:
void dndDone();
void addNewDndSnippset(const QString &);
private:
- SnippetItem *mRootItem;
+ SnippetItem *mRootItem = nullptr;
};
}
diff --git a/src/snippets/snippetvariabledialog.h b/src/snippets/snippetvariabledialog.h
index f7528d7..bcd3658 100644
--- a/src/snippets/snippetvariabledialog.h
+++ b/src/snippets/snippetvariabledialog.h
@@ -41,9 +41,9 @@ public:
private:
void slotAccepted();
QString mVariableName;
- QMap<QString, QString> *mVariables;
- KPIMTextEdit::PlainTextEditorWidget *mVariableValueText;
- QCheckBox *mSaveVariable;
+ QMap<QString, QString> *mVariables = nullptr;
+ KPIMTextEdit::PlainTextEditorWidget *mVariableValueText = nullptr;
+ QCheckBox *mSaveVariable = nullptr;
};
}
diff --git a/src/tag/addtagdialog.cpp b/src/tag/addtagdialog.cpp
index 3e3ed64..7cb079a 100644
--- a/src/tag/addtagdialog.cpp
+++ b/src/tag/addtagdialog.cpp
@@ -41,10 +41,10 @@ public:
QString mLabel;
QString mGid;
- MailCommon::TagWidget *mTagWidget;
+ MailCommon::TagWidget *mTagWidget = nullptr;
QList<MailCommon::Tag::Ptr> mTags;
Akonadi::Tag mTag;
- QPushButton *mOkButton;
+ QPushButton *mOkButton = nullptr;
};
AddTagDialog::AddTagDialog(const QList<KActionCollection *> &actions, QWidget *parent)
diff --git a/src/tag/tagwidget.cpp b/src/tag/tagwidget.cpp
index 7c39339..0e49d7a 100644
--- a/src/tag/tagwidget.cpp
+++ b/src/tag/tagwidget.cpp
@@ -50,22 +50,22 @@ public:
{
}
- KLineEdit *mTagNameLineEdit;
+ KLineEdit *mTagNameLineEdit = nullptr;
- QCheckBox *mTextColorCheck;
- QCheckBox *mBackgroundColorCheck;
- QCheckBox *mTextFontCheck;
- QCheckBox *mInToolbarCheck;
+ QCheckBox *mTextColorCheck = nullptr;
+ QCheckBox *mBackgroundColorCheck = nullptr;
+ QCheckBox *mTextFontCheck = nullptr;
+ QCheckBox *mInToolbarCheck = nullptr;
- KColorCombo *mTextColorCombo;
- KColorCombo *mBackgroundColorCombo;
+ KColorCombo *mTextColorCombo = nullptr;
+ KColorCombo *mBackgroundColorCombo = nullptr;
- QCheckBox *mBoldCheckBox;
- QCheckBox *mItalicCheckBox;
+ QCheckBox *mBoldCheckBox = nullptr;
+ QCheckBox *mItalicCheckBox = nullptr;
- KIconButton *mIconButton;
+ KIconButton *mIconButton = nullptr;
- KKeySequenceWidget *mKeySequenceWidget;
+ KKeySequenceWidget *mKeySequenceWidget = nullptr;
};
TagWidget::TagWidget(const QList<KActionCollection *> &actionCollections, QWidget *parent)
diff --git a/src/util/resourcereadconfigfile.cpp b/src/util/resourcereadconfigfile.cpp
index 9c64c4d..c15f2d6 100644
--- a/src/util/resourcereadconfigfile.cpp
+++ b/src/util/resourcereadconfigfile.cpp
@@ -34,7 +34,7 @@ public:
delete mConfig;
}
- KConfig *mConfig;
+ KConfig *mConfig = nullptr;
};
ResourceReadConfigFile::ResourceReadConfigFile(const QString &resourceName)
diff --git a/src/widgets/favoritecollectionwidget.cpp b/src/widgets/favoritecollectionwidget.cpp
index 3039305..be573d9 100644
--- a/src/widgets/favoritecollectionwidget.cpp
+++ b/src/widgets/favoritecollectionwidget.cpp
@@ -38,14 +38,12 @@ class Q_DECL_HIDDEN FavoriteCollectionWidget::Private
{
public:
Private()
- : listMode(nullptr)
- , iconMode(nullptr)
{
}
QColor textColor;
- QAction *listMode;
- QAction *iconMode;
+ QAction *listMode = nullptr;
+ QAction *iconMode = nullptr;
};
FavoriteCollectionWidget::FavoriteCollectionWidget(KXMLGUIClient *xmlGuiClient, QWidget *parent)
diff --git a/src/widgets/redirectdialog.cpp b/src/widgets/redirectdialog.cpp
index b703730..29639ac 100644
--- a/src/widgets/redirectdialog.cpp
+++ b/src/widgets/redirectdialog.cpp
@@ -81,16 +81,16 @@ public:
void slotUser2();
void slotAddressChanged(const QString &);
QString redirectLabelType(TypeAddress type) const;
- RedirectDialog *q;
- RedirectWidget *mEditTo;
- RedirectWidget *mEditCc;
- RedirectWidget *mEditBcc;
+ RedirectDialog *q = nullptr;
+ RedirectWidget *mEditTo = nullptr;
+ RedirectWidget *mEditCc = nullptr;
+ RedirectWidget *mEditBcc = nullptr;
RedirectDialog::SendMode mSendMode;
- KIdentityManagement::IdentityCombo *mComboboxIdentity;
- MailTransport::TransportComboBox *mTransportCombobox;
- QPushButton *mUser1Button;
- QPushButton *mUser2Button;
+ KIdentityManagement::IdentityCombo *mComboboxIdentity = nullptr;
+ MailTransport::TransportComboBox *mTransportCombobox = nullptr;
+ QPushButton *mUser1Button = nullptr;
+ QPushButton *mUser2Button = nullptr;
};
QString RedirectDialog::Private::redirectLabelType(TypeAddress type) const
diff --git a/src/widgets/redirectwidget.h b/src/widgets/redirectwidget.h
index 0d1ca73..b446a4c 100644
--- a/src/widgets/redirectwidget.h
+++ b/src/widgets/redirectwidget.h
@@ -43,7 +43,7 @@ Q_SIGNALS:
private:
void slotAddressSelection();
- MessageComposer::ComposerLineEdit *mEdit;
+ MessageComposer::ComposerLineEdit *mEdit = nullptr;
QString mResendStr;
};
}