diff options
author | Thorbjørn Martsum <tmartsum@gmail.com> | 2015-06-26 07:17:03 +0200 |
---|---|---|
committer | Thorbjørn Lund Martsum <tmartsum@gmail.com> | 2015-06-27 07:08:46 +0000 |
commit | f1b01b7d159bcf04a2b832dba36f876479669641 (patch) | |
tree | 00de1e7b439c0ac09fda339bf25df5a35810c96f /tests/manual | |
parent | 12b36aec2baf216756b6147abacaed22e73b2560 (diff) |
QHeaderView - fix a logical / visual index mismatch
f9408317e70bc2e635a2f9baeff35d1c06227734 was unfortunately
approved though it had an annoying bug. The patch had
an assign of a visual index into a logical index.
This patch fixes that issue.
Change-Id: I9cc75e4e9701858c92e2c3e5817415041b42f8e8
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
Diffstat (limited to 'tests/manual')
-rw-r--r-- | tests/manual/widgets/itemviews/qheaderview/qheaderviewtest1.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/manual/widgets/itemviews/qheaderview/qheaderviewtest1.cpp b/tests/manual/widgets/itemviews/qheaderview/qheaderviewtest1.cpp index 1e26af8f57..af11e2a098 100644 --- a/tests/manual/widgets/itemviews/qheaderview/qheaderviewtest1.cpp +++ b/tests/manual/widgets/itemviews/qheaderview/qheaderviewtest1.cpp @@ -140,10 +140,12 @@ private: QTableView *setupTableView() { tableView = new QTableView; - m.setRowCount(500); + const int rowCount = 200; + m.setRowCount(rowCount); m.setColumnCount(250); tableView->setSelectionMode(QAbstractItemView::SingleSelection); tableView->setModel(&m); + tableView->verticalHeader()->swapSections(rowCount - 1, 5); return tableView; } |