diff options
author | Jesus Fernandez <jesus.fernandez@qt.io> | 2017-10-27 09:20:29 +0200 |
---|---|---|
committer | Jesus Fernandez <Jesus.Fernandez@qt.io> | 2017-11-03 15:55:53 +0000 |
commit | adf07e92233816d2e79fa7c7990316e91187781c (patch) | |
tree | 71467eeda9c33971b0bd274eb715992ef61909c8 /tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp | |
parent | c988a8a28214914d20f4b8858e7f314a51b27507 (diff) |
tests: Make braces consistent
Make the function brace policy consistent.
Change-Id: Iaf1f05a63958f19927e9b1953da06f99a4eba644
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp')
-rw-r--r-- | tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp b/tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp index 8e429ae14b..895b61fc51 100644 --- a/tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp +++ b/tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp @@ -214,12 +214,14 @@ public: QtTestModel(int _rows, int _cols, QObject *parent = 0): QAbstractItemModel(parent), fetched(false), rows(_rows), cols(_cols), levels(INT_MAX), wrongIndex(false) { init(); } - void init() { + void init() + { decorationsEnabled = false; statusTipsEnabled = false; } - inline qint32 level(const QModelIndex &index) const { + inline qint32 level(const QModelIndex &index) const + { return index.isValid() ? qint32(index.internalId()) : qint32(-1); } @@ -251,7 +253,8 @@ public: return cols; } - bool isEditable(const QModelIndex &index) const { + bool isEditable(const QModelIndex &index) const + { if (index.isValid()) return true; return false; |