diff options
author | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2019-06-04 09:10:45 +0200 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2019-06-04 10:23:44 +0200 |
commit | ab683bcbde7e01c74a46d7b6222fd406c9325428 (patch) | |
tree | 21661e6ea64dfb63debc0815b801c9c3dcf13504 /tests | |
parent | 878d6226f2472b3dff192207aa0c2a03eb4d3465 (diff) |
Fix clang warnings about class definitions
Use member initialization, add override, use "= default" for trivial
constructors and destructors.
Change-Id: I30f64f3d39c1656d52e21653f75935e5c41bca71
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/qwinmime/tst_qwinmime.cpp | 4 | ||||
-rw-r--r-- | tests/manual/dwmfeatures/testwidget.h | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/tests/auto/qwinmime/tst_qwinmime.cpp b/tests/auto/qwinmime/tst_qwinmime.cpp index 666f292..0c57de4 100644 --- a/tests/auto/qwinmime/tst_qwinmime.cpp +++ b/tests/auto/qwinmime/tst_qwinmime.cpp @@ -36,7 +36,7 @@ class TestMime : public QWinMime { public: - TestMime(bool verbose = false) : formatsForMimeCalled(false), m_verbose(verbose) {} + TestMime(bool verbose = false) : m_verbose(verbose) {} bool canConvertFromMime(const FORMATETC &, const QMimeData *mimeData) const Q_DECL_OVERRIDE { @@ -81,7 +81,7 @@ public: return QString(); } - mutable bool formatsForMimeCalled; + mutable bool formatsForMimeCalled = false; private: const bool m_verbose; diff --git a/tests/manual/dwmfeatures/testwidget.h b/tests/manual/dwmfeatures/testwidget.h index 50dec4e..8004eca 100644 --- a/tests/manual/dwmfeatures/testwidget.h +++ b/tests/manual/dwmfeatures/testwidget.h @@ -50,8 +50,8 @@ public: ~TestWidget(); protected: - void changeEvent(QEvent *e); - bool event(QEvent *); + void changeEvent(QEvent *e) override; + bool event(QEvent *) override; private: Ui::TestWidget *ui; |