qitemselectionmodel.cpp

Absolute File Name:/home/qt/qt5_coco/qt5/qtbase/src/corelib/itemmodels/qitemselectionmodel.cpp
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4-
5-
6-
7bool QItemSelectionRange::intersects(const QItemSelectionRange &other) const-
8{-
9 return
executed 9777 times by 21 tests: return (isValid() && other.isValid() && parent() == other.parent() && model() == other.model() && ((top() <= other.top() && bottom() >= other.top()) || (top() >= other.top() && top() <= other.bottom())) && ((left() <= other.left() && right() >= other.left()) || (left() >= other.left() && left() <= other.right())));
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
(isValid() && other.isValid()
executed 9777 times by 21 tests: return (isValid() && other.isValid() && parent() == other.parent() && model() == other.model() && ((top() <= other.top() && bottom() >= other.top()) || (top() >= other.top() && top() <= other.bottom())) && ((left() <= other.left() && right() >= other.left()) || (left() >= other.left() && left() <= other.right())));
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
9777
10 && parent() == other.parent()
executed 9777 times by 21 tests: return (isValid() && other.isValid() && parent() == other.parent() && model() == other.model() && ((top() <= other.top() && bottom() >= other.top()) || (top() >= other.top() && top() <= other.bottom())) && ((left() <= other.left() && right() >= other.left()) || (left() >= other.left() && left() <= other.right())));
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
9777
11 && model() == other.model()
executed 9777 times by 21 tests: return (isValid() && other.isValid() && parent() == other.parent() && model() == other.model() && ((top() <= other.top() && bottom() >= other.top()) || (top() >= other.top() && top() <= other.bottom())) && ((left() <= other.left() && right() >= other.left()) || (left() >= other.left() && left() <= other.right())));
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
9777
12 && ((top() <= other.top() && bottom() >= other.top())
executed 9777 times by 21 tests: return (isValid() && other.isValid() && parent() == other.parent() && model() == other.model() && ((top() <= other.top() && bottom() >= other.top()) || (top() >= other.top() && top() <= other.bottom())) && ((left() <= other.left() && right() >= other.left()) || (left() >= other.left() && left() <= other.right())));
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
9777
13 || (top() >= other.top() && top() <= other.bottom()))
executed 9777 times by 21 tests: return (isValid() && other.isValid() && parent() == other.parent() && model() == other.model() && ((top() <= other.top() && bottom() >= other.top()) || (top() >= other.top() && top() <= other.bottom())) && ((left() <= other.left() && right() >= other.left()) || (left() >= other.left() && left() <= other.right())));
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
9777
14 && ((left() <= other.left() && right() >= other.left())
executed 9777 times by 21 tests: return (isValid() && other.isValid() && parent() == other.parent() && model() == other.model() && ((top() <= other.top() && bottom() >= other.top()) || (top() >= other.top() && top() <= other.bottom())) && ((left() <= other.left() && right() >= other.left()) || (left() >= other.left() && left() <= other.right())));
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
9777
15 || (left() >= other.left() && left() <= other.right())));
executed 9777 times by 21 tests: return (isValid() && other.isValid() && parent() == other.parent() && model() == other.model() && ((top() <= other.top() && bottom() >= other.top()) || (top() >= other.top() && top() <= other.bottom())) && ((left() <= other.left() && right() >= other.left()) || (left() >= other.left() && left() <= other.right())));
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
9777
16}-
17QItemSelectionRange QItemSelectionRange::intersected(const QItemSelectionRange &other) const-
18{-
19 if (model() == other.model()
model() == other.model()Description
TRUEevaluated 891 times by 11 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEnever evaluated
&& parent() == other.parent()
parent() == other.parent()Description
TRUEevaluated 891 times by 11 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEnever evaluated
) {
0-891
20 QModelIndex topLeft = model()->index(qMax(top(), other.top()),-
21 qMax(left(), other.left()),-
22 other.parent());-
23 QModelIndex bottomRight = model()->index(qMin(bottom(), other.bottom()),-
24 qMin(right(), other.right()),-
25 other.parent());-
26 return
executed 891 times by 11 tests: return QItemSelectionRange(topLeft, bottomRight);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
QItemSelectionRange(topLeft, bottomRight);
executed 891 times by 11 tests: return QItemSelectionRange(topLeft, bottomRight);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
891
27 }-
28 return
never executed: return QItemSelectionRange();
QItemSelectionRange();
never executed: return QItemSelectionRange();
0
29}-
30static void rowLengthsFromRange(const QItemSelectionRange &range, QVector<QPair<QPersistentModelIndex, uint> > &result)-
31{-
32 if (range.isValid()
range.isValid()Description
TRUEevaluated 15 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEnever evaluated
&& range.model()
range.model()Description
TRUEevaluated 15 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEnever evaluated
) {
0-15
33 const QModelIndex topLeft = range.topLeft();-
34 const int bottom = range.bottom();-
35 const uint width = range.width();-
36 const int column = topLeft.column();-
37 for (int row = topLeft.row(); row <= bottom
row <= bottomDescription
TRUEevaluated 23 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEevaluated 15 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
; ++row) {
15-23
38-
39-
40-
41 result.push_back(qMakePair(QPersistentModelIndex(topLeft.sibling(row, column)), width));-
42 }
executed 23 times by 2 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
23
43 }
executed 15 times by 2 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
15
44}
executed 15 times by 2 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
15
45-
46template<typename ModelIndexContainer>-
47static void indexesFromRange(const QItemSelectionRange &range, ModelIndexContainer &result)-
48{-
49 if (range.isValid()
range.isValid()Description
TRUEevaluated 1046 times by 18 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEnever evaluated
&& range.model()
range.model()Description
TRUEevaluated 1046 times by 18 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEnever evaluated
) {
0-1046
50 const QModelIndex topLeft = range.topLeft();-
51 const int bottom = range.bottom();-
52 const int right = range.right();-
53 for (int row = topLeft.row(); row <= bottom
row <= bottomDescription
TRUEevaluated 2176 times by 18 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 1046 times by 18 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
; ++row) {
1046-2176
54 const QModelIndex columnLeader = topLeft.sibling(row, topLeft.column());-
55 for (int column = topLeft.column(); column <= right
column <= rightDescription
TRUEevaluated 5925 times by 18 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 2176 times by 18 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
; ++column) {
2176-5925
56 QModelIndex index = columnLeader.sibling(row, column);-
57 Qt::ItemFlags flags = range.model()->flags(index);-
58 if ((flags & Qt::ItemIsSelectable) && (flags & Qt::ItemIsEnabled))-
59 result.push_back(index);
executed 5912 times by 18 tests: result.push_back(index);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
5912
60 }
executed 5925 times by 18 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
5925
61 }
executed 2176 times by 18 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
2176
62 }
executed 1046 times by 18 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
1046
63}
executed 1046 times by 18 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
1046
64-
65template<typename ModelIndexContainer>-
66static ModelIndexContainer qSelectionIndexes(const QItemSelection &selection)-
67{-
68 ModelIndexContainer result;-
69 for (const auto &range : selection)-
70 indexesFromRange(range, result);
executed 1046 times by 18 tests: indexesFromRange(range, result);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
1046
71 return
executed 6813 times by 24 tests: return result;
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAbstractProxyModel
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
result;
executed 6813 times by 24 tests: return result;
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAbstractProxyModel
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
6813
72}-
73-
74-
75-
76-
77-
78-
79bool QItemSelectionRange::isEmpty() const-
80{-
81 if (!isValid()
!isValid()Description
TRUEnever evaluated
FALSEevaluated 431 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemView
  • tst_QTableView
|| !model()
!model()Description
TRUEnever evaluated
FALSEevaluated 431 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemView
  • tst_QTableView
)
0-431
82 return
never executed: return true;
true;
never executed: return true;
0
83-
84 for (int column = left(); column <= right()
column <= right()Description
TRUEevaluated 431 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemView
  • tst_QTableView
FALSEnever evaluated
; ++column) {
0-431
85 for (int row = top(); row <= bottom()
row <= bottom()Description
TRUEevaluated 431 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemView
  • tst_QTableView
FALSEnever evaluated
; ++row) {
0-431
86 QModelIndex index = model()->index(row, column, parent());-
87 Qt::ItemFlags flags = model()->flags(index);-
88 if ((flags & Qt::ItemIsSelectable) && (flags & Qt::ItemIsEnabled))-
89 return
executed 431 times by 3 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QItemView
  • tst_QTableView
false;
executed 431 times by 3 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QItemView
  • tst_QTableView
431
90 }
never executed: end of block
0
91 }
never executed: end of block
0
92 return
never executed: return true;
true;
never executed: return true;
0
93}-
94-
95-
96-
97-
98-
99QModelIndexList QItemSelectionRange::indexes() const-
100{-
101 QModelIndexList result;-
102 indexesFromRange(*this, result);-
103 return
never executed: return result;
result;
never executed: return result;
0
104}-
105QItemSelection::QItemSelection(const QModelIndex &topLeft, const QModelIndex &bottomRight)-
106{-
107 select(topLeft, bottomRight);-
108}
executed 4828 times by 30 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAbstractProxyModel
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • ...
4828
109void QItemSelection::select(const QModelIndex &topLeft, const QModelIndex &bottomRight)-
110{-
111 if (!topLeft.isValid()
!topLeft.isValid()Description
TRUEevaluated 256 times by 17 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAbstractProxyModel
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 5313 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
|| !bottomRight.isValid()
!bottomRight.isValid()Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 5312 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
)
1-5313
112 return;
executed 257 times by 18 tests: return;
Executed by:
  • tst_QAbstractItemView
  • tst_QAbstractProxyModel
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
257
113-
114 if ((
(topLeft.model...Right.model())Description
TRUEnever evaluated
FALSEevaluated 5312 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
topLeft.model() != bottomRight.model())
(topLeft.model...Right.model())Description
TRUEnever evaluated
FALSEevaluated 5312 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
0-5312
115 || topLeft.parent() != bottomRight.parent()
topLeft.parent...Right.parent()Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 5311 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
) {
1-5311
116 QMessageLogger(__FILE__, 443, __PRETTY_FUNCTION__).warning("Can't select indexes from different model or with different parents");-
117 return;
executed 1 time by 1 test: return;
Executed by:
  • tst_QItemSelectionModel
1
118 }-
119 if (topLeft.row() > bottomRight.row()
topLeft.row() ...tomRight.row()Description
TRUEnever evaluated
FALSEevaluated 5311 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
|| topLeft.column() > bottomRight.column()
topLeft.column...Right.column()Description
TRUEnever evaluated
FALSEevaluated 5311 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
) {
0-5311
120 int top = qMin(topLeft.row(), bottomRight.row());-
121 int bottom = qMax(topLeft.row(), bottomRight.row());-
122 int left = qMin(topLeft.column(), bottomRight.column());-
123 int right = qMax(topLeft.column(), bottomRight.column());-
124 QModelIndex tl = topLeft.sibling(top, left);-
125 QModelIndex br = bottomRight.sibling(bottom, right);-
126 append(QItemSelectionRange(tl, br));-
127 return;
never executed: return;
0
128 }-
129 append(QItemSelectionRange(topLeft, bottomRight));-
130}
executed 5311 times by 29 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
5311
131-
132-
133-
134-
135-
136-
137bool QItemSelection::contains(const QModelIndex &index) const-
138{-
139 if (index.flags() & Qt::ItemIsSelectable
index.flags() ...emIsSelectableDescription
TRUEevaluated 9021 times by 21 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 7 times by 1 test
Evaluated by:
  • tst_QCalendarWidget
) {
7-9021
140 QList<QItemSelectionRange>::const_iterator it = begin();-
141 for (; it != end()
it != end()Description
TRUEevaluated 11213 times by 21 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 7396 times by 19 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
; ++it)
7396-11213
142 if ((*
(*it).contains(index)Description
TRUEevaluated 1625 times by 21 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 9588 times by 19 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
it).contains(index)
(*it).contains(index)Description
TRUEevaluated 1625 times by 21 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 9588 times by 19 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
)
1625-9588
143 return
executed 1625 times by 21 tests: return true;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
true;
executed 1625 times by 21 tests: return true;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
1625
144 }
executed 7396 times by 19 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
7396
145 return
executed 7403 times by 19 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
false;
executed 7403 times by 19 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
7403
146}-
147-
148-
149-
150-
151-
152QModelIndexList QItemSelection::indexes() const-
153{-
154 return
executed 1153 times by 17 tests: return qSelectionIndexes<QModelIndexList>(*this);
Executed by:
  • tst_QAbstractItemView
  • tst_QAbstractProxyModel
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
qSelectionIndexes<QModelIndexList>(*this);
executed 1153 times by 17 tests: return qSelectionIndexes<QModelIndexList>(*this);
Executed by:
  • tst_QAbstractItemView
  • tst_QAbstractProxyModel
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
1153
155}-
156-
157static QVector<QPair<QPersistentModelIndex, uint> > qSelectionPersistentRowLengths(const QItemSelection &sel)-
158{-
159 QVector<QPair<QPersistentModelIndex, uint> > result;-
160 for (const QItemSelectionRange &range : sel)-
161 rowLengthsFromRange(range, result);
executed 15 times by 2 tests: rowLengthsFromRange(range, result);
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
15
162 return
executed 250 times by 9 tests: return result;
Executed by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QHeaderView
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QTableView
  • tst_QTreeView
result;
executed 250 times by 9 tests: return result;
Executed by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QHeaderView
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QTableView
  • tst_QTreeView
250
163}-
164void QItemSelection::merge(const QItemSelection &other, QItemSelectionModel::SelectionFlags command)-
165{-
166 if (other.isEmpty()
other.isEmpty()Description
TRUEevaluated 229960 times by 42 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
FALSEevaluated 13405 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
||
13405-229960
167 !(command & QItemSelectionModel::Select ||-
168 command & QItemSelectionModel::Deselect ||-
169 command & QItemSelectionModel::Toggle))-
170 return;
executed 229960 times by 42 tests: return;
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
229960
171-
172 QItemSelection newSelection = other;-
173-
174 QItemSelection intersections;-
175 QItemSelection::iterator it = newSelection.begin();-
176 while (it != newSelection.end()
it != newSelection.end()Description
TRUEevaluated 13942 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
FALSEevaluated 13405 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
) {
13405-13942
177 if (!(*it).isValid()
!(*it).isValid()Description
TRUEevaluated 234 times by 15 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QListWidget
  • tst_QMenu
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 13708 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
) {
234-13708
178 it = newSelection.erase(it);-
179 continue;
executed 234 times by 15 tests: continue;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QListWidget
  • tst_QMenu
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
234
180 }-
181 for (int t = 0; t < count()
t < count()Description
TRUEevaluated 3578 times by 15 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 13708 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
; ++t) {
3578-13708
182 if ((*
(*it).intersects(at(t))Description
TRUEevaluated 639 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 2939 times by 15 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
it).intersects(at(t))
(*it).intersects(at(t))Description
TRUEevaluated 639 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 2939 times by 15 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
)
639-2939
183 intersections.append(at(t).intersected(*it));
executed 639 times by 10 tests: intersections.append(at(t).intersected(*it));
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
639
184 }
executed 3578 times by 15 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
3578
185 ++it;-
186 }
executed 13708 times by 29 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
13708
187-
188-
189 for (int i = 0; i < intersections.count()
i < intersections.count()Description
TRUEevaluated 639 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 13405 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
; ++i) {
639-13405
190 for (int t = 0; t < count()
t < count()Description
TRUEevaluated 2131 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 639 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
;) {
639-2131
191 if (at(t).intersects(intersections.at(i))
at(t).intersec...ections.at(i))Description
TRUEevaluated 639 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 1492 times by 9 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
) {
639-1492
192 split(at(t), intersections.at(i), this);-
193 removeAt(t);-
194 }
executed 639 times by 10 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
else {
639
195 ++t;-
196 }
executed 1492 times by 9 tests: end of block
Executed by:
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
1492
197 }-
198-
199 for (int n = 0; (command & QItemSelectionModel::Toggle) && n < newSelection.count()
n < newSelection.count()Description
TRUEevaluated 92 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QItemSelectionModel
FALSEevaluated 81 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QItemSelectionModel
;) {
81-92
200 if (newSelection.at(n).intersects(intersections.at(i))
newSelection.a...ections.at(i))Description
TRUEevaluated 81 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QItemSelectionModel
FALSEevaluated 11 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
) {
11-81
201 split(newSelection.at(n), intersections.at(i), &newSelection);-
202 newSelection.removeAt(n);-
203 }
executed 81 times by 3 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QItemSelectionModel
else {
81
204 ++n;-
205 }
executed 11 times by 2 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
11
206 }-
207 }
executed 639 times by 10 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
639
208-
209 if (!(command & QItemSelectionModel::Deselect)
!(command & QI...del::Deselect)Description
TRUEevaluated 12562 times by 27 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
FALSEevaluated 843 times by 14 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
)
843-12562
210 operator+=(newSelection);
executed 12562 times by 27 tests: operator+=(newSelection);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
12562
211}
executed 13405 times by 29 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
13405
212void QItemSelection::split(const QItemSelectionRange &range,-
213 const QItemSelectionRange &other, QItemSelection *result)-
214{-
215 if (range.parent() != other.parent()
range.parent()...other.parent()Description
TRUEnever evaluated
FALSEevaluated 1238 times by 11 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
|| range.model() != other.model()
range.model() != other.model()Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 1237 times by 11 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
)
0-1238
216 return;
executed 1 time by 1 test: return;
Executed by:
  • tst_QItemSelectionModel
1
217-
218 QModelIndex parent = other.parent();-
219 int top = range.top();-
220 int left = range.left();-
221 int bottom = range.bottom();-
222 int right = range.right();-
223 int other_top = other.top();-
224 int other_left = other.left();-
225 int other_bottom = other.bottom();-
226 int other_right = other.right();-
227 const QAbstractItemModel *model = range.model();-
228 ((!(model)) ? qt_assert("model",__FILE__,574) : qt_noop());-
229 if (other_top > top
other_top > topDescription
TRUEevaluated 214 times by 6 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
FALSEevaluated 1023 times by 11 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
) {
214-1023
230 QModelIndex tl = model->index(top, left, parent);-
231 QModelIndex br = model->index(other_top - 1, right, parent);-
232 result->append(QItemSelectionRange(tl, br));-
233 top = other_top;-
234 }
executed 214 times by 6 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
214
235 if (other_bottom < bottom
other_bottom < bottomDescription
TRUEevaluated 162 times by 6 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 1075 times by 11 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
) {
162-1075
236 QModelIndex tl = model->index(other_bottom + 1, left, parent);-
237 QModelIndex br = model->index(bottom, right, parent);-
238 result->append(QItemSelectionRange(tl, br));-
239 bottom = other_bottom;-
240 }
executed 162 times by 6 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
162
241 if (other_left > left
other_left > leftDescription
TRUEevaluated 175 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 1062 times by 11 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
) {
175-1062
242 QModelIndex tl = model->index(top, left, parent);-
243 QModelIndex br = model->index(bottom, other_left - 1, parent);-
244 result->append(QItemSelectionRange(tl, br));-
245 left = other_left;-
246 }
executed 175 times by 5 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
175
247 if (other_right < right
other_right < rightDescription
TRUEevaluated 150 times by 6 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 1087 times by 11 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
) {
150-1087
248 QModelIndex tl = model->index(top, other_right + 1, parent);-
249 QModelIndex br = model->index(bottom, right, parent);-
250 result->append(QItemSelectionRange(tl, br));-
251 right = other_right;-
252 }
executed 150 times by 6 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
150
253}
executed 1237 times by 11 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
1237
254-
255-
256void QItemSelectionModelPrivate::initModel(QAbstractItemModel *m)-
257{-
258 struct Cx {-
259 const char *signal;-
260 const char *slot;-
261 };-
262 static const Cx connections[] = {-
263 { qFlagLocation("2""rowsAboutToBeRemoved(QModelIndex,int,int)" "\0" __FILE__ ":" "609"),-
264 qFlagLocation("1""_q_rowsAboutToBeRemoved(QModelIndex,int,int)" "\0" __FILE__ ":" "610") },-
265 { qFlagLocation("2""columnsAboutToBeRemoved(QModelIndex,int,int)" "\0" __FILE__ ":" "611"),-
266 qFlagLocation("1""_q_columnsAboutToBeRemoved(QModelIndex,int,int)" "\0" __FILE__ ":" "612") },-
267 { qFlagLocation("2""rowsAboutToBeInserted(QModelIndex,int,int)" "\0" __FILE__ ":" "613"),-
268 qFlagLocation("1""_q_rowsAboutToBeInserted(QModelIndex,int,int)" "\0" __FILE__ ":" "614") },-
269 { qFlagLocation("2""columnsAboutToBeInserted(QModelIndex,int,int)" "\0" __FILE__ ":" "615"),-
270 qFlagLocation("1""_q_columnsAboutToBeInserted(QModelIndex,int,int)" "\0" __FILE__ ":" "616") },-
271 { qFlagLocation("2""rowsAboutToBeMoved(QModelIndex,int,int,QModelIndex,int)" "\0" __FILE__ ":" "617"),-
272 qFlagLocation("1""_q_layoutAboutToBeChanged()" "\0" __FILE__ ":" "618") },-
273 { qFlagLocation("2""columnsAboutToBeMoved(QModelIndex,int,int,QModelIndex,int)" "\0" __FILE__ ":" "619"),-
274 qFlagLocation("1""_q_layoutAboutToBeChanged()" "\0" __FILE__ ":" "620") },-
275 { qFlagLocation("2""rowsMoved(QModelIndex,int,int,QModelIndex,int)" "\0" __FILE__ ":" "621"),-
276 qFlagLocation("1""_q_layoutChanged()" "\0" __FILE__ ":" "622") },-
277 { qFlagLocation("2""columnsMoved(QModelIndex,int,int,QModelIndex,int)" "\0" __FILE__ ":" "623"),-
278 qFlagLocation("1""_q_layoutChanged()" "\0" __FILE__ ":" "624") },-
279 { qFlagLocation("2""layoutAboutToBeChanged(QList<QPersistentModelIndex>,QAbstractItemModel::LayoutChangeHint)" "\0" __FILE__ ":" "625"),-
280 qFlagLocation("1""_q_layoutAboutToBeChanged(QList<QPersistentModelIndex>,QAbstractItemModel::LayoutChangeHint)" "\0" __FILE__ ":" "626") },-
281 { qFlagLocation("2""layoutChanged(QList<QPersistentModelIndex>,QAbstractItemModel::LayoutChangeHint)" "\0" __FILE__ ":" "627"),-
282 qFlagLocation("1""_q_layoutChanged(QList<QPersistentModelIndex>,QAbstractItemModel::LayoutChangeHint)" "\0" __FILE__ ":" "628") },-
283 { qFlagLocation("2""modelReset()" "\0" __FILE__ ":" "629"),-
284 qFlagLocation("1""reset()" "\0" __FILE__ ":" "630") },-
285 { 0, 0 }-
286 };-
287-
288 if (model == m
model == mDescription
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 5009 times by 42 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
)
1-5009
289 return;
executed 1 time by 1 test: return;
Executed by:
  • tst_QItemSelectionModel
1
290-
291 QItemSelectionModel * const q = q_func();-
292 if (model
modelDescription
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 5008 times by 42 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
) {
1-5008
293 for (const Cx *cx = &connections[0]; cx->signal
cx->signalDescription
TRUEevaluated 11 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QItemSelectionModel
; cx++)
1-11
294 QObject::disconnect(model, cx->signal, q, cx->slot);
executed 11 times by 1 test: QObject::disconnect(model, cx->signal, q, cx->slot);
Executed by:
  • tst_QItemSelectionModel
11
295 q->reset();-
296 }
executed 1 time by 1 test: end of block
Executed by:
  • tst_QItemSelectionModel
1
297 model = m;-
298 if (model
modelDescription
TRUEevaluated 5008 times by 42 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QItemSelectionModel
) {
1-5008
299 for (const Cx *cx = &connections[0]; cx->signal
cx->signalDescription
TRUEevaluated 55088 times by 42 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
FALSEevaluated 5008 times by 42 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
; cx++)
5008-55088
300 QObject::connect(model, cx->signal, q, cx->slot);
executed 55088 times by 42 tests: QObject::connect(model, cx->signal, q, cx->slot);
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
55088
301 }
executed 5008 times by 42 tests: end of block
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
5008
302}
executed 5009 times by 42 tests: end of block
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
5009
303QItemSelection QItemSelectionModelPrivate::expandSelection(const QItemSelection &selection,-
304 QItemSelectionModel::SelectionFlags command) const-
305{-
306 if (selection.isEmpty()
selection.isEmpty()Description
TRUEevaluated 11 times by 2 tests
Evaluated by:
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 544 times by 14 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
&& !((command & QItemSelectionModel::Rows) ||
11-544
307 (
(command & QIt...odel::Columns)Description
TRUEnever evaluated
FALSEnever evaluated
command & QItemSelectionModel::Columns)
(command & QIt...odel::Columns)Description
TRUEnever evaluated
FALSEnever evaluated
))
0
308 return
never executed: return selection;
selection;
never executed: return selection;
0
309-
310 QItemSelection expanded;-
311 if (command & QItemSelectionModel::Rows
command & QIte...ionModel::RowsDescription
TRUEevaluated 519 times by 14 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 36 times by 3 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QTableView
) {
36-519
312 for (int i = 0; i < selection.count()
i < selection.count()Description
TRUEevaluated 513 times by 14 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 519 times by 14 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
; ++i) {
513-519
313 QModelIndex parent = selection.at(i).parent();-
314 int colCount = model->columnCount(parent);-
315 QModelIndex tl = model->index(selection.at(i).top(), 0, parent);-
316 QModelIndex br = model->index(selection.at(i).bottom(), colCount - 1, parent);-
317-
318 expanded.merge(QItemSelection(tl, br), QItemSelectionModel::Select);-
319 }
executed 513 times by 14 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
513
320 }
executed 519 times by 14 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
519
321 if (command & QItemSelectionModel::Columns
command & QIte...Model::ColumnsDescription
TRUEevaluated 36 times by 3 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QTableView
FALSEevaluated 519 times by 14 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
) {
36-519
322 for (int i = 0; i < selection.count()
i < selection.count()Description
TRUEevaluated 36 times by 3 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QTableView
FALSEevaluated 36 times by 3 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QTableView
; ++i) {
36
323 QModelIndex parent = selection.at(i).parent();-
324 int rowCount = model->rowCount(parent);-
325 QModelIndex tl = model->index(0, selection.at(i).left(), parent);-
326 QModelIndex br = model->index(rowCount - 1, selection.at(i).right(), parent);-
327-
328 expanded.merge(QItemSelection(tl, br), QItemSelectionModel::Select);-
329 }
executed 36 times by 3 tests: end of block
Executed by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QTableView
36
330 }
executed 36 times by 3 tests: end of block
Executed by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QTableView
36
331 return
executed 555 times by 14 tests: return expanded;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
expanded;
executed 555 times by 14 tests: return expanded;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
555
332}-
333-
334-
335-
336-
337void QItemSelectionModelPrivate::_q_rowsAboutToBeRemoved(const QModelIndex &parent,-
338 int start, int end)-
339{-
340 QItemSelectionModel * const q = q_func();-
341 finalize();-
342-
343-
344 if (currentIndex.isValid()
currentIndex.isValid()Description
TRUEevaluated 39 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 3549 times by 23 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QCalendarWidget
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
&& parent == currentIndex.parent()
parent == curr...Index.parent()Description
TRUEevaluated 26 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 13 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QSortFilterProxyModel
  • tst_QTreeView
13-3549
345 && currentIndex.row() >= start
currentIndex.row() >= startDescription
TRUEevaluated 16 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 10 times by 5 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
&& currentIndex.row() <= end
currentIndex.row() <= endDescription
TRUEevaluated 5 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QTreeView
FALSEevaluated 11 times by 7 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTreeWidget
) {
5-16
346 QModelIndex old = currentIndex;-
347 if (start > 0
start > 0Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QTreeView
FALSEevaluated 4 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QTreeView
)
1-4
348 currentIndex = model->index(start - 1, old.column(), parent);
executed 1 time by 1 test: currentIndex = model->index(start - 1, old.column(), parent);
Executed by:
  • tst_QTreeView
1
349 else if (model && end < model->rowCount(parent) - 1
end < model->r...nt(parent) - 1Description
TRUEnever evaluated
FALSEevaluated 4 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QTreeView
)
0-4
350 currentIndex = model->index(end + 1, old.column(), parent);
never executed: currentIndex = model->index(end + 1, old.column(), parent);
0
351 else-
352 currentIndex = QModelIndex();
executed 4 times by 3 tests: currentIndex = QModelIndex();
Executed by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QTreeView
4
353 q->currentChanged(currentIndex, old);-
354 q->currentRowChanged(currentIndex, old);-
355 if (currentIndex.column() != old.column()
currentIndex.c...= old.column()Description
TRUEevaluated 4 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QTreeView
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QTreeView
)
1-4
356 q->currentColumnChanged(currentIndex, old);
executed 4 times by 3 tests: q->currentColumnChanged(currentIndex, old);
Executed by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QTreeView
4
357 }
executed 5 times by 3 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QTreeView
5
358-
359 QItemSelection deselected;-
360 QItemSelection newParts;-
361 QItemSelection::iterator it = ranges.begin();-
362 while (it != ranges.end()
it != ranges.end()Description
TRUEevaluated 60 times by 12 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 3588 times by 24 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
) {
60-3588
363 if (it->topLeft().parent() != parent
it->topLeft()....nt() != parentDescription
TRUEevaluated 15 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeView
FALSEevaluated 45 times by 12 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
) {
15-45
364 QModelIndex itParent = it->topLeft().parent();-
365 while (itParent.isValid()
itParent.isValid()Description
TRUEevaluated 9 times by 4 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
FALSEevaluated 12 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeView
&& itParent.parent() != parent
itParent.parent() != parentDescription
TRUEevaluated 6 times by 4 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
FALSEevaluated 3 times by 3 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
)
3-12
366 itParent = itParent.parent();
executed 6 times by 4 tests: itParent = itParent.parent();
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
6
367-
368 if (itParent.isValid()
itParent.isValid()Description
TRUEevaluated 3 times by 3 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
FALSEevaluated 12 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeView
&& start <= itParent.row()
start <= itParent.row()Description
TRUEevaluated 3 times by 3 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
FALSEnever evaluated
&& itParent.row() <= end
itParent.row() <= endDescription
TRUEevaluated 3 times by 3 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
FALSEnever evaluated
) {
0-12
369 deselected.append(*it);-
370 it = ranges.erase(it);-
371 }
executed 3 times by 3 tests: end of block
Executed by:
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
else {
3
372 ++it;-
373 }
executed 12 times by 5 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeView
12
374 } else if (start <= it->bottom()
start <= it->bottom()Description
TRUEevaluated 40 times by 12 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 5 times by 4 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTreeView
&& it->bottom() <= end
it->bottom() <= endDescription
TRUEevaluated 22 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 18 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTreeWidget
5-40
375 && start <= it->top()
start <= it->top()Description
TRUEevaluated 20 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
&& it->top() <= end
it->top() <= endDescription
TRUEevaluated 20 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
FALSEnever evaluated
) {
0-20
376 deselected.append(*it);-
377 it = ranges.erase(it);-
378 }
executed 20 times by 8 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
else if (start <= it->top()
start <= it->top()Description
TRUEevaluated 15 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTreeWidget
FALSEevaluated 10 times by 4 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTreeView
&& it->top() <= end
it->top() <= endDescription
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 12 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTreeWidget
) {
3-20
379 deselected.append(QItemSelectionRange(it->topLeft(), model->index(end, it->right(), it->parent())));-
380 *it = QItemSelectionRange(model->index(end + 1, it->left(), it->parent()), it->bottomRight());-
381 ++it;-
382 }
executed 3 times by 1 test: end of block
Executed by:
  • tst_QItemSelectionModel
else if (start <= it->bottom()
start <= it->bottom()Description
TRUEevaluated 17 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTreeWidget
FALSEevaluated 5 times by 4 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTreeView
&& it->bottom() <= end
it->bottom() <= endDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 15 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTreeWidget
) {
2-17
383 deselected.append(QItemSelectionRange(model->index(start, it->left(), it->parent()), it->bottomRight()));-
384 *it = QItemSelectionRange(it->topLeft(), model->index(start - 1, it->right(), it->parent()));-
385 ++it;-
386 }
executed 2 times by 1 test: end of block
Executed by:
  • tst_QItemSelectionModel
else if (it->top() < start
it->top() < startDescription
TRUEevaluated 8 times by 4 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTreeView
FALSEevaluated 12 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTreeWidget
&& end < it->bottom()
end < it->bottom()Description
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 5 times by 4 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTreeView
) {
2-12
387-
388-
389-
390-
391 const QItemSelectionRange removedRange(model->index(start, it->left(), it->parent()),-
392 model->index(end, it->right(), it->parent()));-
393 deselected.append(removedRange);-
394 QItemSelection::split(*it, removedRange, &newParts);-
395 it = ranges.erase(it);-
396 }
executed 3 times by 1 test: end of block
Executed by:
  • tst_QItemSelectionModel
else
3
397 ++
executed 17 times by 9 tests: ++it;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTreeView
  • tst_QTreeWidget
it;
executed 17 times by 9 tests: ++it;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QTreeView
  • tst_QTreeWidget
17
398 }-
399 ranges.append(newParts);-
400-
401 if (!deselected.isEmpty()
!deselected.isEmpty()Description
TRUEevaluated 30 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 3558 times by 24 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
)
30-3558
402 q->selectionChanged(QItemSelection(), deselected);
executed 30 times by 8 tests: q->selectionChanged(QItemSelection(), deselected);
Executed by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
30
403}
executed 3588 times by 24 tests: end of block
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
3588
404-
405-
406-
407-
408void QItemSelectionModelPrivate::_q_columnsAboutToBeRemoved(const QModelIndex &parent,-
409 int start, int end)-
410{-
411 QItemSelectionModel * const q = q_func();-
412-
413-
414 if (currentIndex.isValid()
currentIndex.isValid()Description
TRUEevaluated 11 times by 5 tests
Evaluated by:
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QHeaderView
  • tst_QListView
  • tst_QTableView
FALSEevaluated 287 times by 10 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
&& parent == currentIndex.parent()
parent == curr...Index.parent()Description
TRUEevaluated 11 times by 5 tests
Evaluated by:
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QHeaderView
  • tst_QListView
  • tst_QTableView
FALSEnever evaluated
0-287
415 && currentIndex.column() >= start
currentIndex.column() >= startDescription
TRUEevaluated 8 times by 4 tests
Evaluated by:
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QHeaderView
  • tst_QListView
FALSEevaluated 3 times by 2 tests
Evaluated by:
  • tst_QHeaderView
  • tst_QTableView
&& currentIndex.column() <= end
currentIndex.column() <= endDescription
TRUEevaluated 3 times by 2 tests
Evaluated by:
  • tst_QHeaderView
  • tst_QListView
FALSEevaluated 5 times by 2 tests
Evaluated by:
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
) {
3-8
416 QModelIndex old = currentIndex;-
417 if (start > 0
start > 0Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QListView
FALSEevaluated 2 times by 2 tests
Evaluated by:
  • tst_QHeaderView
  • tst_QListView
)
1-2
418 currentIndex = model->index(old.row(), start - 1, parent);
executed 1 time by 1 test: currentIndex = model->index(old.row(), start - 1, parent);
Executed by:
  • tst_QListView
1
419 else if (model && end < model->columnCount() - 1
end < model->columnCount() - 1Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QListView
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QHeaderView
)
1
420 currentIndex = model->index(old.row(), end + 1, parent);
executed 1 time by 1 test: currentIndex = model->index(old.row(), end + 1, parent);
Executed by:
  • tst_QListView
1
421 else-
422 currentIndex = QModelIndex();
executed 1 time by 1 test: currentIndex = QModelIndex();
Executed by:
  • tst_QHeaderView
1
423 q->currentChanged(currentIndex, old);-
424 if (currentIndex.row() != old.row()
currentIndex.r...) != old.row()Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QHeaderView
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_QListView
)
1-2
425 q->currentRowChanged(currentIndex, old);
executed 1 time by 1 test: q->currentRowChanged(currentIndex, old);
Executed by:
  • tst_QHeaderView
1
426 q->currentColumnChanged(currentIndex, old);-
427 }
executed 3 times by 2 tests: end of block
Executed by:
  • tst_QHeaderView
  • tst_QListView
3
428-
429-
430 QModelIndex tl = model->index(0, start, parent);-
431 QModelIndex br = model->index(model->rowCount(parent) - 1, end, parent);-
432 q->select(QItemSelection(tl, br), QItemSelectionModel::Deselect);-
433 finalize();-
434}
executed 298 times by 11 tests: end of block
Executed by:
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
298
435-
436-
437-
438-
439-
440-
441void QItemSelectionModelPrivate::_q_columnsAboutToBeInserted(const QModelIndex &parent,-
442 int start, int end)-
443{-
444 (void)end;;-
445 finalize();-
446 QList<QItemSelectionRange> split;-
447 QList<QItemSelectionRange>::iterator it = ranges.begin();-
448 for (; it != ranges.end()
it != ranges.end()Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QAccessibility
FALSEevaluated 871 times by 12 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
; ) {
1-871
449 if ((*
(*it).isValid()Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QAccessibility
FALSEnever evaluated
it).isValid()
(*it).isValid()Description
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QAccessibility
FALSEnever evaluated
&& (*
(*it).parent() == parentDescription
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QAccessibility
FALSEnever evaluated
it).parent() == parent
(*it).parent() == parentDescription
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QAccessibility
FALSEnever evaluated
0-1
450 && (*
(*it).left() < startDescription
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QAccessibility
FALSEnever evaluated
it).left() < start
(*it).left() < startDescription
TRUEevaluated 1 time by 1 test
Evaluated by:
  • tst_QAccessibility
FALSEnever evaluated
&& (*
(*it).right() >= startDescription
TRUEnever evaluated
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QAccessibility
it).right() >= start
(*it).right() >= startDescription
TRUEnever evaluated
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QAccessibility
) {
0-1
451 QModelIndex bottomMiddle = model->index((*it).bottom(), start - 1, (*it).parent());-
452 QItemSelectionRange left((*it).topLeft(), bottomMiddle);-
453 QModelIndex topMiddle = model->index((*it).top(), start, (*it).parent());-
454 QItemSelectionRange right(topMiddle, (*it).bottomRight());-
455 it = ranges.erase(it);-
456 split.append(left);-
457 split.append(right);-
458 }
never executed: end of block
else {
0
459 ++it;-
460 }
executed 1 time by 1 test: end of block
Executed by:
  • tst_QAccessibility
1
461 }-
462 ranges += split;-
463}
executed 871 times by 12 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
871
464-
465-
466-
467-
468-
469-
470void QItemSelectionModelPrivate::_q_rowsAboutToBeInserted(const QModelIndex &parent,-
471 int start, int end)-
472{-
473 (void)end;;-
474 finalize();-
475 QList<QItemSelectionRange> split;-
476 QList<QItemSelectionRange>::iterator it = ranges.begin();-
477 for (; it != ranges.end()
it != ranges.end()Description
TRUEevaluated 3042 times by 11 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 202721 times by 31 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QPrinter
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QStandardItemModel
  • tst_QStyleSheetStyle
  • ...
; ) {
3042-202721
478 if ((*
(*it).isValid()Description
TRUEevaluated 3042 times by 11 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEnever evaluated
it).isValid()
(*it).isValid()Description
TRUEevaluated 3042 times by 11 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEnever evaluated
&& (*
(*it).parent() == parentDescription
TRUEevaluated 284 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 2758 times by 7 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
it).parent() == parent
(*it).parent() == parentDescription
TRUEevaluated 284 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 2758 times by 7 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
0-3042
479 && (*
(*it).top() < startDescription
TRUEevaluated 276 times by 8 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 8 times by 4 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QItemSelectionModel
it).top() < start
(*it).top() < startDescription
TRUEevaluated 276 times by 8 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 8 times by 4 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QItemSelectionModel
&& (*
(*it).bottom() >= startDescription
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 273 times by 8 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
it).bottom() >= start
(*it).bottom() >= startDescription
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 273 times by 8 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
) {
3-276
480 QModelIndex middleRight = model->index(start - 1, (*it).right(), (*it).parent());-
481 QItemSelectionRange top((*it).topLeft(), middleRight);-
482 QModelIndex middleLeft = model->index(start, (*it).left(), (*it).parent());-
483 QItemSelectionRange bottom(middleLeft, (*it).bottomRight());-
484 it = ranges.erase(it);-
485 split.append(top);-
486 split.append(bottom);-
487 }
executed 3 times by 1 test: end of block
Executed by:
  • tst_QItemSelectionModel
else {
3
488 ++it;-
489 }
executed 3039 times by 11 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
3039
490 }-
491 ranges += split;-
492}
executed 202721 times by 31 tests: end of block
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QPrinter
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QStandardItemModel
  • tst_QStyleSheetStyle
  • ...
202721
493void QItemSelectionModelPrivate::_q_layoutAboutToBeChanged(const QList<QPersistentModelIndex> &, QAbstractItemModel::LayoutChangeHint hint)-
494{-
495 savedPersistentIndexes.clear();-
496 savedPersistentCurrentIndexes.clear();-
497 savedPersistentRowLengths.clear();-
498 savedPersistentCurrentRowLengths.clear();-
499-
500-
501-
502 if (ranges.isEmpty()
ranges.isEmpty()Description
TRUEevaluated 2919 times by 20 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
FALSEevaluated 36 times by 6 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTreeWidget
&& currentSelection.count() == 1
currentSelection.count() == 1Description
TRUEevaluated 14 times by 6 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableWidget
FALSEevaluated 2905 times by 19 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
) {
14-2919
503 QItemSelectionRange range = currentSelection.constFirst();-
504 QModelIndex parent = range.parent();-
505 tableRowCount = model->rowCount(parent);-
506 tableColCount = model->columnCount(parent);-
507 if (tableRowCount * tableColCount > 1000
tableRowCount ...olCount > 1000Description
TRUEnever evaluated
FALSEevaluated 14 times by 6 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableWidget
0-14
508 && range.top() == 0
range.top() == 0Description
TRUEnever evaluated
FALSEnever evaluated
0
509 && range.left() == 0
range.left() == 0Description
TRUEnever evaluated
FALSEnever evaluated
0
510 && range.bottom() == tableRowCount - 1
range.bottom()...leRowCount - 1Description
TRUEnever evaluated
FALSEnever evaluated
0
511 && range.right() == tableColCount - 1
range.right() ...leColCount - 1Description
TRUEnever evaluated
FALSEnever evaluated
) {
0
512 tableSelected = true;-
513 tableParent = parent;-
514 return;
never executed: return;
0
515 }-
516 }
executed 14 times by 6 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableWidget
14
517 tableSelected = false;-
518-
519 if (hint == QAbstractItemModel::VerticalSortHint
hint == QAbstr...rticalSortHintDescription
TRUEevaluated 125 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QHeaderView
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QTableView
  • tst_QTreeView
FALSEevaluated 2830 times by 16 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
) {
125-2830
520-
521-
522-
523-
524-
525 savedPersistentRowLengths = qSelectionPersistentRowLengths(ranges);-
526 savedPersistentCurrentRowLengths = qSelectionPersistentRowLengths(currentSelection);-
527 }
executed 125 times by 9 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QHeaderView
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QTableView
  • tst_QTreeView
else {
125
528 savedPersistentIndexes = qSelectionIndexes<QVector<QPersistentModelIndex>>(ranges);-
529 savedPersistentCurrentIndexes = qSelectionIndexes<QVector<QPersistentModelIndex>>(currentSelection);-
530 }
executed 2830 times by 16 tests: end of block
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
2830
531}-
532-
533-
534-
535static QItemSelection mergeRowLengths(const QVector<QPair<QPersistentModelIndex, uint> > &rowLengths)-
536{-
537 if (rowLengths.isEmpty()
rowLengths.isEmpty()Description
TRUEevaluated 8 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEevaluated 12 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
)
8-12
538 return
executed 8 times by 2 tests: return QItemSelection();
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
QItemSelection();
executed 8 times by 2 tests: return QItemSelection();
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
8
539-
540 QItemSelection result;-
541 int i = 0;-
542 while (i < rowLengths.count()
i < rowLengths.count()Description
TRUEevaluated 13 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEevaluated 12 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
) {
12-13
543 const QPersistentModelIndex &tl = rowLengths.at(i).first;-
544 if (!tl.isValid()
!tl.isValid()Description
TRUEnever evaluated
FALSEevaluated 13 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
) {
0-13
545 ++i;-
546 continue;
never executed: continue;
0
547 }-
548 QPersistentModelIndex br = tl;-
549 const uint length = rowLengths.at(i).second;-
550 while (++
++i < rowLengths.count()Description
TRUEevaluated 11 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEevaluated 12 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
i < rowLengths.count()
++i < rowLengths.count()Description
TRUEevaluated 11 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEevaluated 12 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
) {
11-12
551 const QPersistentModelIndex &next = rowLengths.at(i).first;-
552 if (!next.isValid()
!next.isValid()Description
TRUEnever evaluated
FALSEevaluated 11 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
)
0-11
553 continue;
never executed: continue;
0
554 const uint nextLength = rowLengths.at(i).second;-
555 if ((
(nextLength == length)Description
TRUEevaluated 11 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEnever evaluated
nextLength == length)
(nextLength == length)Description
TRUEevaluated 11 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEnever evaluated
0-11
556 && (
(next.row() == br.row() + 1)Description
TRUEevaluated 10 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QItemSelectionModel
next.row() == br.row() + 1)
(next.row() == br.row() + 1)Description
TRUEevaluated 10 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEevaluated 1 time by 1 test
Evaluated by:
  • tst_QItemSelectionModel
1-10
557 && (
(next.parent() == br.parent())Description
TRUEevaluated 10 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEnever evaluated
next.parent() == br.parent())
(next.parent() == br.parent())Description
TRUEevaluated 10 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEnever evaluated
) {
0-10
558 br = next;-
559 }
executed 10 times by 2 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
else {
10
560 break;
executed 1 time by 1 test: break;
Executed by:
  • tst_QItemSelectionModel
1
561 }-
562 }-
563 result.append(QItemSelectionRange(tl, br.sibling(br.row(), length - 1)));-
564 }
executed 13 times by 2 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
13
565 return
executed 12 times by 2 tests: return result;
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
result;
executed 12 times by 2 tests: return result;
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
12
566}-
567-
568-
569-
570-
571-
572-
573-
574static QItemSelection mergeIndexes(const QVector<QPersistentModelIndex> &indexes)-
575{-
576 QItemSelection colSpans;-
577-
578 int i = 0;-
579 while (i < indexes.count()
i < indexes.count()Description
TRUEevaluated 110 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
FALSEevaluated 80 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
) {
80-110
580 const QPersistentModelIndex &tl = indexes.at(i);-
581 if (!tl.isValid()
!tl.isValid()Description
TRUEnever evaluated
FALSEevaluated 110 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
) {
0-110
582 ++i;-
583 continue;
never executed: continue;
0
584 }-
585 QPersistentModelIndex br = tl;-
586 QModelIndex brParent = br.parent();-
587 int brRow = br.row();-
588 int brColumn = br.column();-
589 while (++
++i < indexes.count()Description
TRUEevaluated 585 times by 7 tests
Evaluated by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
FALSEevaluated 48 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
i < indexes.count()
++i < indexes.count()Description
TRUEevaluated 585 times by 7 tests
Evaluated by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
FALSEevaluated 48 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
) {
48-585
590 const QPersistentModelIndex &next = indexes.at(i);-
591 if (!next.isValid()
!next.isValid()Description
TRUEnever evaluated
FALSEevaluated 585 times by 7 tests
Evaluated by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
)
0-585
592 continue;
never executed: continue;
0
593 const QModelIndex nextParent = next.parent();-
594 const int nextRow = next.row();-
595 const int nextColumn = next.column();-
596 if ((
(nextParent == brParent)Description
TRUEevaluated 543 times by 7 tests
Evaluated by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
FALSEevaluated 42 times by 2 tests
Evaluated by:
  • tst_QFiledialog
  • tst_QStandardItemModel
nextParent == brParent)
(nextParent == brParent)Description
TRUEevaluated 543 times by 7 tests
Evaluated by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
FALSEevaluated 42 times by 2 tests
Evaluated by:
  • tst_QFiledialog
  • tst_QStandardItemModel
42-543
597 && (
(nextRow == brRow)Description
TRUEevaluated 523 times by 7 tests
Evaluated by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
FALSEevaluated 20 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
nextRow == brRow)
(nextRow == brRow)Description
TRUEevaluated 523 times by 7 tests
Evaluated by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
FALSEevaluated 20 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
20-523
598 && (
(nextColumn == brColumn + 1)Description
TRUEevaluated 523 times by 7 tests
Evaluated by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
FALSEnever evaluated
nextColumn == brColumn + 1)
(nextColumn == brColumn + 1)Description
TRUEevaluated 523 times by 7 tests
Evaluated by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
FALSEnever evaluated
) {
0-523
599 br = next;-
600 brParent = nextParent;-
601 brRow = nextRow;-
602 brColumn = nextColumn;-
603 }
executed 523 times by 7 tests: end of block
Executed by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
else {
523
604 break;
executed 62 times by 3 tests: break;
Executed by:
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
62
605 }-
606 }-
607 colSpans.append(QItemSelectionRange(tl, br));-
608 }
executed 110 times by 8 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
110
609-
610 QItemSelection rowSpans;-
611 i = 0;-
612 while (i < colSpans.count()
i < colSpans.count()Description
TRUEevaluated 104 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
FALSEevaluated 80 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
) {
80-104
613 QModelIndex tl = colSpans.at(i).topLeft();-
614 QModelIndex br = colSpans.at(i).bottomRight();-
615 QModelIndex prevTl = tl;-
616 while (++
++i < colSpans.count()Description
TRUEevaluated 62 times by 3 tests
Evaluated by:
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
FALSEevaluated 48 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
i < colSpans.count()
++i < colSpans.count()Description
TRUEevaluated 62 times by 3 tests
Evaluated by:
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
FALSEevaluated 48 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
) {
48-62
617 QModelIndex nextTl = colSpans.at(i).topLeft();-
618 QModelIndex nextBr = colSpans.at(i).bottomRight();-
619-
620 if (nextTl.parent() != tl.parent()
nextTl.parent() != tl.parent()Description
TRUEevaluated 42 times by 2 tests
Evaluated by:
  • tst_QFiledialog
  • tst_QStandardItemModel
FALSEevaluated 20 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
)
20-42
621 break;
executed 42 times by 2 tests: break;
Executed by:
  • tst_QFiledialog
  • tst_QStandardItemModel
42
622-
623 if ((
(nextTl.column...evTl.column())Description
TRUEevaluated 20 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
FALSEnever evaluated
nextTl.column() == prevTl.column())
(nextTl.column...evTl.column())Description
TRUEevaluated 20 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
FALSEnever evaluated
&& (
(nextBr.column...= br.column())Description
TRUEevaluated 20 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
FALSEnever evaluated
nextBr.column() == br.column())
(nextBr.column...= br.column())Description
TRUEevaluated 20 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
FALSEnever evaluated
0-20
624 && (
(nextTl.row() ...vTl.row() + 1)Description
TRUEevaluated 6 times by 1 test
Evaluated by:
  • tst_QStandardItemModel
FALSEevaluated 14 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
nextTl.row() == prevTl.row() + 1)
(nextTl.row() ...vTl.row() + 1)Description
TRUEevaluated 6 times by 1 test
Evaluated by:
  • tst_QStandardItemModel
FALSEevaluated 14 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
&& (
(nextBr.row() == br.row() + 1)Description
TRUEevaluated 6 times by 1 test
Evaluated by:
  • tst_QStandardItemModel
FALSEnever evaluated
nextBr.row() == br.row() + 1)
(nextBr.row() == br.row() + 1)Description
TRUEevaluated 6 times by 1 test
Evaluated by:
  • tst_QStandardItemModel
FALSEnever evaluated
) {
0-14
625 br = nextBr;-
626 prevTl = nextTl;-
627 }
executed 6 times by 1 test: end of block
Executed by:
  • tst_QStandardItemModel
else {
6
628 break;
executed 14 times by 1 test: break;
Executed by:
  • tst_QItemSelectionModel
14
629 }-
630 }-
631 rowSpans.append(QItemSelectionRange(tl, br));-
632 }
executed 104 times by 8 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
104
633 return
executed 80 times by 8 tests: return rowSpans;
Executed by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
rowSpans;
executed 80 times by 8 tests: return rowSpans;
Executed by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
80
634}-
635static bool qt_PersistentModelIndexLessThan(const QPersistentModelIndex &i1, const QPersistentModelIndex &i2)-
636{-
637 const QModelIndex parent1 = i1.parent();-
638 const QModelIndex parent2 = i2.parent();-
639 return
executed 2243 times by 7 tests: return parent1 == parent2 ? i1 < i2 : parent1 < parent2;
Executed by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
parent1 == parent2 ? i1 < i2 : parent1 < parent2;
executed 2243 times by 7 tests: return parent1 == parent2 ? i1 < i2 : parent1 < parent2;
Executed by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
2243
640}-
641-
642-
643-
644-
645-
646-
647void QItemSelectionModelPrivate::_q_layoutChanged(const QList<QPersistentModelIndex> &, QAbstractItemModel::LayoutChangeHint hint)-
648{-
649-
650 if (tableSelected
tableSelectedDescription
TRUEnever evaluated
FALSEevaluated 2956 times by 20 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
&& tableColCount == model->columnCount(tableParent)
tableColCount ...t(tableParent)Description
TRUEnever evaluated
FALSEnever evaluated
0-2956
651 && tableRowCount == model->rowCount(tableParent)
tableRowCount ...t(tableParent)Description
TRUEnever evaluated
FALSEnever evaluated
) {
0
652 ranges.clear();-
653 currentSelection.clear();-
654 int bottom = tableRowCount - 1;-
655 int right = tableColCount - 1;-
656 QModelIndex tl = model->index(0, 0, tableParent);-
657 QModelIndex br = model->index(bottom, right, tableParent);-
658 currentSelection << QItemSelectionRange(tl, br);-
659 tableParent = QModelIndex();-
660 tableSelected = false;-
661 return;
never executed: return;
0
662 }-
663-
664 if ((hint != QAbstractItemModel::VerticalSortHint
hint != QAbstr...rticalSortHintDescription
TRUEevaluated 2831 times by 17 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
FALSEevaluated 125 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QHeaderView
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QTableView
  • tst_QTreeView
&& savedPersistentCurrentIndexes.isEmpty()
savedPersisten...exes.isEmpty()Description
TRUEevaluated 2814 times by 16 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
FALSEevaluated 17 times by 5 tests
Evaluated by:
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableWidget
&& savedPersistentIndexes.isEmpty()
savedPersisten...exes.isEmpty()Description
TRUEevaluated 2791 times by 16 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
FALSEevaluated 23 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QStandardItemModel
  • tst_QTreeWidget
)
17-2831
665 || (hint == QAbstractItemModel::VerticalSortHint
hint == QAbstr...rticalSortHintDescription
TRUEevaluated 125 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QHeaderView
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QTableView
  • tst_QTreeView
FALSEevaluated 40 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
&& savedPersistentRowLengths.isEmpty()
savedPersisten...gths.isEmpty()Description
TRUEevaluated 120 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QHeaderView
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QTableView
  • tst_QTreeView
FALSEevaluated 5 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
&& savedPersistentCurrentRowLengths.isEmpty()
savedPersisten...gths.isEmpty()Description
TRUEevaluated 115 times by 7 tests
Evaluated by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QHeaderView
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QTableView
  • tst_QTreeView
FALSEevaluated 5 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
)) {
5-125
666-
667-
668 return;
executed 2906 times by 19 tests: return;
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemModel
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QSqlQueryModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
2906
669 }-
670-
671-
672 ranges.clear();-
673 currentSelection.clear();-
674-
675 if (hint != QAbstractItemModel::VerticalSortHint
hint != QAbstr...rticalSortHintDescription
TRUEevaluated 40 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
FALSEevaluated 10 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
) {
10-40
676-
677 std::stable_sort(savedPersistentIndexes.begin(), savedPersistentIndexes.end(),-
678 qt_PersistentModelIndexLessThan);-
679 std::stable_sort(savedPersistentCurrentIndexes.begin(), savedPersistentCurrentIndexes.end(),-
680 qt_PersistentModelIndexLessThan);-
681-
682-
683 ranges = mergeIndexes(savedPersistentIndexes);-
684 currentSelection = mergeIndexes(savedPersistentCurrentIndexes);-
685-
686-
687 savedPersistentIndexes.clear();-
688 savedPersistentCurrentIndexes.clear();-
689 }
executed 40 times by 8 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QStandardItemModel
  • tst_QTableWidget
  • tst_QTreeWidget
else {
40
690-
691 std::stable_sort(savedPersistentRowLengths.begin(), savedPersistentRowLengths.end());-
692 std::stable_sort(savedPersistentCurrentRowLengths.begin(), savedPersistentCurrentRowLengths.end());-
693-
694-
695 ranges = mergeRowLengths(savedPersistentRowLengths);-
696 currentSelection = mergeRowLengths(savedPersistentCurrentRowLengths);-
697-
698-
699 savedPersistentRowLengths.clear();-
700 savedPersistentCurrentRowLengths.clear();-
701 }
executed 10 times by 2 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
10
702}-
703QItemSelectionModel::QItemSelectionModel(QAbstractItemModel *model)-
704 : QObject(*new QItemSelectionModelPrivate, model)-
705{-
706 d_func()->initModel(model);-
707}
executed 93 times by 8 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QColumnView
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTreeView
  • tst_QTreeWidget
93
708-
709-
710-
711-
712QItemSelectionModel::QItemSelectionModel(QAbstractItemModel *model, QObject *parent)-
713 : QObject(*new QItemSelectionModelPrivate, parent)-
714{-
715 d_func()->initModel(model);-
716}
executed 4915 times by 42 tests: end of block
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
4915
717-
718-
719-
720-
721QItemSelectionModel::QItemSelectionModel(QItemSelectionModelPrivate &dd, QAbstractItemModel *model)-
722 : QObject(dd, model)-
723{-
724 dd.initModel(model);-
725}
never executed: end of block
0
726-
727-
728-
729-
730QItemSelectionModel::~QItemSelectionModel()-
731{-
732}-
733-
734-
735-
736-
737-
738-
739-
740void QItemSelectionModel::select(const QModelIndex &index, QItemSelectionModel::SelectionFlags command)-
741{-
742 QItemSelection selection(index, index);-
743 select(selection, command);-
744}
executed 3834 times by 27 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
3834
745void QItemSelectionModel::select(const QItemSelection &selection, QItemSelectionModel::SelectionFlags command)-
746{-
747 QItemSelectionModelPrivate * const d = d_func();-
748 if (!d->model
!d->modelDescription
TRUEnever evaluated
FALSEevaluated 7345 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
) {
0-7345
749 QMessageLogger(__FILE__, 1251, __PRETTY_FUNCTION__).warning("QItemSelectionModel: Selecting when no model has been set will result in a no-op.");-
750 return;
never executed: return;
0
751 }-
752 if (command == NoUpdate
command == NoUpdateDescription
TRUEevaluated 45 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTreeWidget
FALSEevaluated 7300 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
)
45-7300
753 return;
executed 45 times by 5 tests: return;
Executed by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTreeWidget
45
754-
755-
756 QItemSelection sel = selection;-
757-
758-
759-
760-
761-
762 QItemSelection::iterator it = d->ranges.begin();-
763 while (it != d->ranges.end()
it != d->ranges.end()Description
TRUEevaluated 1187 times by 15 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 7300 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
) {
1187-7300
764 if (!it->isValid()
!it->isValid()Description
TRUEevaluated 24 times by 4 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 1163 times by 15 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
)
24-1163
765 it = d->ranges.erase(it);
executed 24 times by 4 tests: it = d->ranges.erase(it);
Executed by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
24
766 else-
767 ++
executed 1163 times by 15 tests: ++it;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
it;
executed 1163 times by 15 tests: ++it;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
1163
768 }-
769-
770 QItemSelection old = d->ranges;-
771 old.merge(d->currentSelection, d->currentCommand);-
772-
773-
774 if (command & Rows || command & Columns)-
775 sel = d->expandSelection(sel, command);
executed 555 times by 14 tests: sel = d->expandSelection(sel, command);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
555
776-
777-
778 if (command & Clear
command & ClearDescription
TRUEevaluated 5312 times by 27 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
FALSEevaluated 1988 times by 26 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • ...
) {
1988-5312
779 d->ranges.clear();-
780 d->currentSelection.clear();-
781 }
executed 5312 times by 27 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
5312
782-
783-
784 if (!(command & Current)
!(command & Current)Description
TRUEevaluated 6537 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
FALSEevaluated 763 times by 12 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QDateTimeEdit
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
)
763-6537
785 d->finalize();
executed 6537 times by 29 tests: d->finalize();
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
6537
786-
787-
788 if (command & Toggle || command & Select || command & Deselect) {-
789 d->currentCommand = command;-
790 d->currentSelection = sel;-
791 }
executed 5792 times by 29 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
5792
792-
793-
794 QItemSelection newSelection = d->ranges;-
795 newSelection.merge(d->currentSelection, d->currentCommand);-
796 emitSelectionChanged(newSelection, old);-
797}
executed 7300 times by 29 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
7300
798-
799-
800-
801-
802void QItemSelectionModel::clear()-
803{-
804 clearSelection();-
805 clearCurrentIndex();-
806}
executed 12275 times by 43 tests: end of block
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
12275
807-
808-
809-
810-
811void QItemSelectionModel::clearCurrentIndex()-
812{-
813 QItemSelectionModelPrivate * const d = d_func();-
814 QModelIndex previous = d->currentIndex;-
815 d->currentIndex = QModelIndex();-
816 if (previous.isValid()
previous.isValid()Description
TRUEevaluated 880 times by 12 tests
Evaluated by:
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QListWidget
  • tst_QSidebar
  • tst_QTreeWidget
  • tst_languageChange
FALSEevaluated 11398 times by 43 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
) {
880-11398
817 currentChanged(d->currentIndex, previous);-
818 currentRowChanged(d->currentIndex, previous);-
819 currentColumnChanged(d->currentIndex, previous);-
820 }
executed 880 times by 12 tests: end of block
Executed by:
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QListWidget
  • tst_QSidebar
  • tst_QTreeWidget
  • tst_languageChange
880
821}
executed 12278 times by 43 tests: end of block
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
12278
822-
823-
824-
825-
826void QItemSelectionModel::reset()-
827{-
828 const QSignalBlocker blocker(this);-
829 clear();-
830}
executed 9635 times by 43 tests: end of block
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
9635
831-
832-
833-
834-
835-
836void QItemSelectionModel::clearSelection()-
837{-
838 QItemSelectionModelPrivate * const d = d_func();-
839 if (d->ranges.count() == 0
d->ranges.count() == 0Description
TRUEevaluated 12268 times by 43 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
FALSEevaluated 66 times by 9 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QDateTimeEdit
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
&& d->currentSelection.count() == 0
d->currentSele...n.count() == 0Description
TRUEevaluated 10878 times by 43 tests
Evaluated by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
FALSEevaluated 1390 times by 22 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
)
66-12268
840 return;
executed 10878 times by 43 tests: return;
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
10878
841-
842 select(QItemSelection(), Clear);-
843}
executed 1456 times by 23 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
1456
844void QItemSelectionModel::setCurrentIndex(const QModelIndex &index, QItemSelectionModel::SelectionFlags command)-
845{-
846 QItemSelectionModelPrivate * const d = d_func();-
847 if (!d->model
!d->modelDescription
TRUEnever evaluated
FALSEevaluated 4212 times by 28 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTableWidget
  • ...
) {
0-4212
848 QMessageLogger(__FILE__, 1362, __PRETTY_FUNCTION__).warning("QItemSelectionModel: Setting the current index when no model has been set will result in a no-op.");-
849 return;
never executed: return;
0
850 }-
851 if (index == d->currentIndex
index == d->currentIndexDescription
TRUEevaluated 255 times by 17 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 3957 times by 28 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTableWidget
  • ...
) {
255-3957
852 if (command != NoUpdate
command != NoUpdateDescription
TRUEevaluated 145 times by 15 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 110 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QItemView
  • tst_QListView
  • tst_QTreeView
  • tst_QTreeWidget
)
110-145
853 select(index, command);
executed 145 times by 15 tests: select(index, command);
Executed by:
  • tst_QAbstractItemView
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
145
854 return;
executed 255 times by 17 tests: return;
Executed by:
  • tst_QAbstractItemView
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
255
855 }-
856 QPersistentModelIndex previous = d->currentIndex;-
857 d->currentIndex = index;-
858 if (command != NoUpdate
command != NoUpdateDescription
TRUEevaluated 2956 times by 25 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
FALSEevaluated 1001 times by 21 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
)
1001-2956
859 select(d->currentIndex, command);
executed 2956 times by 25 tests: select(d->currentIndex, command);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
2956
860 currentChanged(d->currentIndex, previous);-
861 if (d->currentIndex.row() != previous.row()
d->currentInde...previous.row()Description
TRUEevaluated 3320 times by 26 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • ...
FALSEevaluated 637 times by 14 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QColumnView
  • tst_QComboBox
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
||
637-3320
862 d->currentIndex.parent() != previous.parent()
d->currentInde...vious.parent()Description
TRUEevaluated 50 times by 5 tests
Evaluated by:
  • tst_QColumnView
  • tst_QComboBox
  • tst_QItemSelectionModel
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 587 times by 11 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
)
50-587
863 currentRowChanged(d->currentIndex, previous);
executed 3370 times by 26 tests: currentRowChanged(d->currentIndex, previous);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • ...
3370
864 if (d->currentIndex.column() != previous.column()
d->currentInde...vious.column()Description
TRUEevaluated 2038 times by 26 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • ...
FALSEevaluated 1919 times by 21 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
||
1919-2038
865 d->currentIndex.parent() != previous.parent()
d->currentInde...vious.parent()Description
TRUEevaluated 76 times by 7 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QColumnView
  • tst_QComboBox
  • tst_QItemSelectionModel
  • tst_QSortFilterProxyModel
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 1843 times by 21 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
)
76-1843
866 currentColumnChanged(d->currentIndex, previous);
executed 2114 times by 26 tests: currentColumnChanged(d->currentIndex, previous);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • ...
2114
867}
executed 3957 times by 28 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTableWidget
  • ...
3957
868-
869-
870-
871-
872-
873QModelIndex QItemSelectionModel::currentIndex() const-
874{-
875 return
executed 38936 times by 42 tests: return static_cast<QModelIndex>(d_func()->currentIndex);
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
static_cast<QModelIndex>(d_func()->currentIndex);
executed 38936 times by 42 tests: return static_cast<QModelIndex>(d_func()->currentIndex);
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
38936
876}-
877-
878-
879-
880-
881bool QItemSelectionModel::isSelected(const QModelIndex &index) const-
882{-
883 const QItemSelectionModelPrivate * const d = d_func();-
884 if (d->model != index.model()
d->model != index.model()Description
TRUEevaluated 20 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QTreeView
FALSEevaluated 28592 times by 26 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
|| !index.isValid()
!index.isValid()Description
TRUEnever evaluated
FALSEevaluated 28592 times by 26 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
)
0-28592
885 return
executed 20 times by 5 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QTreeView
false;
executed 20 times by 5 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QTreeView
20
886-
887 bool selected = false;-
888-
889 QList<QItemSelectionRange>::const_iterator it = d->ranges.begin();-
890 for (; it != d->ranges.end()
it != d->ranges.end()Description
TRUEevaluated 5490 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QTableView
  • tst_QTreeView
FALSEevaluated 28034 times by 26 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
; ++it) {
5490-28034
891 if ((*
(*it).isValid()Description
TRUEevaluated 5490 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QTableView
  • tst_QTreeView
FALSEnever evaluated
it).isValid()
(*it).isValid()Description
TRUEevaluated 5490 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QTableView
  • tst_QTreeView
FALSEnever evaluated
&& (*
(*it).contains(index)Description
TRUEevaluated 558 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QTableView
  • tst_QTreeView
FALSEevaluated 4932 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListWidget
  • tst_QTableView
it).contains(index)
(*it).contains(index)Description
TRUEevaluated 558 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QTableView
  • tst_QTreeView
FALSEevaluated 4932 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListWidget
  • tst_QTableView
) {
0-5490
892 selected = true;-
893 break;
executed 558 times by 9 tests: break;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QTableView
  • tst_QTreeView
558
894 }-
895 }
executed 4932 times by 8 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListWidget
  • tst_QTableView
4932
896-
897-
898 if (d->currentSelection.count()
d->currentSelection.count()Description
TRUEevaluated 9209 times by 21 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 19383 times by 22 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
) {
9209-19383
899 if ((d->currentCommand & Deselect) && selected
selectedDescription
TRUEevaluated 185 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 90 times by 3 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
)
90-185
900 selected = !d->currentSelection.contains(index);
executed 185 times by 5 tests: selected = !d->currentSelection.contains(index);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
185
901 else if (d->currentCommand & Toggle
d->currentCommand & ToggleDescription
TRUEevaluated 75 times by 2 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
FALSEevaluated 8949 times by 21 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
)
75-8949
902 selected ^= d->currentSelection.contains(index);
executed 75 times by 2 tests: selected ^= d->currentSelection.contains(index);
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
75
903 else if ((d->currentCommand & Select) && !selected
!selectedDescription
TRUEevaluated 8702 times by 21 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 157 times by 6 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListWidget
  • tst_QTableView
  • tst_QTreeView
)
157-8702
904 selected = d->currentSelection.contains(index);
executed 8702 times by 21 tests: selected = d->currentSelection.contains(index);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
8702
905 }
executed 9209 times by 21 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
9209
906-
907 if (selected
selectedDescription
TRUEevaluated 1826 times by 21 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 26766 times by 24 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
) {
1826-26766
908 Qt::ItemFlags flags = d->model->flags(index);-
909 return
executed 1826 times by 21 tests: return (flags & Qt::ItemIsSelectable);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
(flags & Qt::ItemIsSelectable);
executed 1826 times by 21 tests: return (flags & Qt::ItemIsSelectable);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
1826
910 }-
911-
912 return
executed 26766 times by 24 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
false;
executed 26766 times by 24 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
26766
913}-
914bool QItemSelectionModel::isRowSelected(int row, const QModelIndex &parent) const-
915{-
916 const QItemSelectionModelPrivate * const d = d_func();-
917 if (!d->model
!d->modelDescription
TRUEnever evaluated
FALSEevaluated 1940 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
)
0-1940
918 return
never executed: return false;
false;
never executed: return false;
0
919 if (parent.isValid()
parent.isValid()Description
TRUEevaluated 849 times by 4 tests
Evaluated by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTreeView
FALSEevaluated 1091 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
&& d->model != parent.model()
d->model != parent.model()Description
TRUEnever evaluated
FALSEevaluated 849 times by 4 tests
Evaluated by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTreeView
)
0-1091
920 return
never executed: return false;
false;
never executed: return false;
0
921-
922-
923 if (d->currentCommand & Deselect && d->currentSelection.count()
d->currentSelection.count()Description
TRUEevaluated 81 times by 3 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemView
  • tst_QTableView
FALSEnever evaluated
) {
0-81
924 for (int i=0; i<d->currentSelection.count()
i<d->currentSelection.count()Description
TRUEevaluated 81 times by 3 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 60 times by 2 tests
Evaluated by:
  • tst_QItemView
  • tst_QTableView
; ++i) {
60-81
925 if (d->currentSelection.at(i).parent() == parent
d->currentSele...nt() == parentDescription
TRUEevaluated 81 times by 3 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemView
  • tst_QTableView
FALSEnever evaluated
&&
0-81
926 row >= d->currentSelection.at(i).top()
row >= d->curr...on.at(i).top()Description
TRUEevaluated 49 times by 3 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 32 times by 2 tests
Evaluated by:
  • tst_QItemView
  • tst_QTableView
&&
32-49
927 row <= d->currentSelection.at(i).bottom()
row <= d->curr...at(i).bottom()Description
TRUEevaluated 21 times by 3 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 28 times by 1 test
Evaluated by:
  • tst_QItemView
)
21-28
928 return
executed 21 times by 3 tests: return false;
Executed by:
  • tst_QAccessibility
  • tst_QItemView
  • tst_QTableView
false;
executed 21 times by 3 tests: return false;
Executed by:
  • tst_QAccessibility
  • tst_QItemView
  • tst_QTableView
21
929 }
executed 60 times by 2 tests: end of block
Executed by:
  • tst_QItemView
  • tst_QTableView
60
930 }
executed 60 times by 2 tests: end of block
Executed by:
  • tst_QItemView
  • tst_QTableView
60
931-
932-
933 if (d->currentCommand & Toggle && d->currentSelection.count()
d->currentSelection.count()Description
TRUEevaluated 22 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QItemSelectionModel
FALSEnever evaluated
) {
0-22
934 for (int i=0; i<d->currentSelection.count()
i<d->currentSelection.count()Description
TRUEevaluated 22 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QItemSelectionModel
FALSEevaluated 22 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QItemSelectionModel
; ++i)
22
935 if (d->currentSelection.at(i).top() <= row
d->currentSele...).top() <= rowDescription
TRUEevaluated 12 times by 3 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QItemSelectionModel
FALSEevaluated 10 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
&&
10-12
936 d->currentSelection.at(i).bottom() >= row
d->currentSele...ottom() >= rowDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_QAbstractItemView
FALSEevaluated 10 times by 2 tests
Evaluated by:
  • tst_QFiledialog
  • tst_QItemSelectionModel
)
2-10
937 for (int j=0; j<d->ranges.count()
j<d->ranges.count()Description
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_QAbstractItemView
; ++j)
0-2
938 if (d->ranges.at(j).top() <= row
d->ranges.at(j).top() <= rowDescription
TRUEnever evaluated
FALSEnever evaluated
&& d->ranges.at(j).bottom() >= row
d->ranges.at(j...ottom() >= rowDescription
TRUEnever evaluated
FALSEnever evaluated
0
939 && d->currentSelection.at(i).intersected(d->ranges.at(j)).isValid()
d->currentSele...(j)).isValid()Description
TRUEnever evaluated
FALSEnever evaluated
)
0
940 return
never executed: return false;
false;
never executed: return false;
0
941 }
executed 22 times by 3 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QFiledialog
  • tst_QItemSelectionModel
22
942-
943 QList<QItemSelectionRange>::const_iterator it;-
944 QList<QItemSelectionRange> joined = d->ranges;-
945 if (d->currentSelection.count()
d->currentSelection.count()Description
TRUEevaluated 1237 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
FALSEevaluated 682 times by 5 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemView
  • tst_QTreeWidget
)
682-1237
946 joined += d->currentSelection;
executed 1237 times by 9 tests: joined += d->currentSelection;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
1237
947 int colCount = d->model->columnCount(parent);-
948 for (int column = 0; column < colCount
column < colCountDescription
TRUEevaluated 2117 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 1027 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
; ++column) {
1027-2117
949 for (it = joined.constBegin(); it != joined.constEnd()
it != joined.constEnd()Description
TRUEevaluated 5428 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 892 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
; ++it) {
892-5428
950 if ((*
(*it).contains...olumn, parent)Description
TRUEevaluated 1235 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 4193 times by 7 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
it).contains(row, column, parent)
(*it).contains...olumn, parent)Description
TRUEevaluated 1235 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 4193 times by 7 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
) {
1235-4193
951 bool selectable = false;-
952 for (int i = column; !selectable
!selectableDescription
TRUEevaluated 1246 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 1225 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
&& i <= (*it).right()
i <= (*it).right()Description
TRUEevaluated 1236 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 10 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
; ++i) {
10-1246
953 Qt::ItemFlags flags = d->model->index(row, i, parent).flags();-
954 selectable = flags & Qt::ItemIsSelectable;-
955 }
executed 1236 times by 10 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
1236
956 if (selectable
selectableDescription
TRUEevaluated 1225 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 10 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
){
10-1225
957 column = qMax(column, (*it).right());-
958 break;
executed 1225 times by 10 tests: break;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
1225
959 }-
960 }
executed 10 times by 1 test: end of block
Executed by:
  • tst_QItemSelectionModel
10
961 }
executed 4203 times by 7 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
4203
962 if (it == joined.constEnd()
it == joined.constEnd()Description
TRUEevaluated 892 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 1225 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
)
892-1225
963 return
executed 892 times by 5 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
false;
executed 892 times by 5 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
892
964 }
executed 1225 times by 10 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
1225
965 return
executed 1027 times by 9 tests: return colCount > 0;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
colCount > 0;
executed 1027 times by 9 tests: return colCount > 0;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
1027
966}-
967bool QItemSelectionModel::isColumnSelected(int column, const QModelIndex &parent) const-
968{-
969 const QItemSelectionModelPrivate * const d = d_func();-
970 if (!d->model
!d->modelDescription
TRUEnever evaluated
FALSEevaluated 1030 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
)
0-1030
971 return
never executed: return false;
false;
never executed: return false;
0
972 if (parent.isValid()
parent.isValid()Description
TRUEevaluated 60 times by 3 tests
Evaluated by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
FALSEevaluated 970 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
&& d->model != parent.model()
d->model != parent.model()Description
TRUEnever evaluated
FALSEevaluated 60 times by 3 tests
Evaluated by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
)
0-970
973 return
never executed: return false;
false;
never executed: return false;
0
974-
975-
976 if (d->currentCommand & Deselect && d->currentSelection.count()
d->currentSelection.count()Description
TRUEevaluated 46 times by 2 tests
Evaluated by:
  • tst_QItemView
  • tst_QTableView
FALSEnever evaluated
) {
0-46
977 for (int i = 0; i < d->currentSelection.count()
i < d->current...ection.count()Description
TRUEevaluated 46 times by 2 tests
Evaluated by:
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 27 times by 2 tests
Evaluated by:
  • tst_QItemView
  • tst_QTableView
; ++i) {
27-46
978 if (d->currentSelection.at(i).parent() == parent
d->currentSele...nt() == parentDescription
TRUEevaluated 46 times by 2 tests
Evaluated by:
  • tst_QItemView
  • tst_QTableView
FALSEnever evaluated
&&
0-46
979 column >= d->currentSelection.at(i).left()
column >= d->c...n.at(i).left()Description
TRUEevaluated 34 times by 2 tests
Evaluated by:
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 12 times by 2 tests
Evaluated by:
  • tst_QItemView
  • tst_QTableView
&&
12-34
980 column <= d->currentSelection.at(i).right()
column <= d->c....at(i).right()Description
TRUEevaluated 19 times by 2 tests
Evaluated by:
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 15 times by 1 test
Evaluated by:
  • tst_QItemView
)
15-19
981 return
executed 19 times by 2 tests: return false;
Executed by:
  • tst_QItemView
  • tst_QTableView
false;
executed 19 times by 2 tests: return false;
Executed by:
  • tst_QItemView
  • tst_QTableView
19
982 }
executed 27 times by 2 tests: end of block
Executed by:
  • tst_QItemView
  • tst_QTableView
27
983 }
executed 27 times by 2 tests: end of block
Executed by:
  • tst_QItemView
  • tst_QTableView
27
984-
985-
986 if (d->currentCommand & Toggle && d->currentSelection.count()
d->currentSelection.count()Description
TRUEevaluated 6 times by 1 test
Evaluated by:
  • tst_QAbstractItemView
FALSEnever evaluated
) {
0-6
987 for (int i = 0; i < d->currentSelection.count()
i < d->current...ection.count()Description
TRUEevaluated 6 times by 1 test
Evaluated by:
  • tst_QAbstractItemView
FALSEevaluated 6 times by 1 test
Evaluated by:
  • tst_QAbstractItemView
; ++i) {
6
988 if (d->currentSelection.at(i).left() <= column
d->currentSele...ft() <= columnDescription
TRUEevaluated 6 times by 1 test
Evaluated by:
  • tst_QAbstractItemView
FALSEnever evaluated
&&
0-6
989 d->currentSelection.at(i).right() >= column
d->currentSele...ht() >= columnDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_QAbstractItemView
FALSEevaluated 4 times by 1 test
Evaluated by:
  • tst_QAbstractItemView
) {
2-4
990 for (int j = 0; j < d->ranges.count()
j < d->ranges.count()Description
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_QAbstractItemView
; ++j) {
0-2
991 if (d->ranges.at(j).left() <= column
d->ranges.at(j...ft() <= columnDescription
TRUEnever evaluated
FALSEnever evaluated
&& d->ranges.at(j).right() >= column
d->ranges.at(j...ht() >= columnDescription
TRUEnever evaluated
FALSEnever evaluated
0
992 && d->currentSelection.at(i).intersected(d->ranges.at(j)).isValid()
d->currentSele...(j)).isValid()Description
TRUEnever evaluated
FALSEnever evaluated
) {
0
993 return
never executed: return false;
false;
never executed: return false;
0
994 }-
995 }
never executed: end of block
0
996 }
executed 2 times by 1 test: end of block
Executed by:
  • tst_QAbstractItemView
2
997 }
executed 6 times by 1 test: end of block
Executed by:
  • tst_QAbstractItemView
6
998 }
executed 6 times by 1 test: end of block
Executed by:
  • tst_QAbstractItemView
6
999-
1000 QList<QItemSelectionRange>::const_iterator it;-
1001 QList<QItemSelectionRange> joined = d->ranges;-
1002 if (d->currentSelection.count()
d->currentSelection.count()Description
TRUEevaluated 825 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 186 times by 4 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemView
)
186-825
1003 joined += d->currentSelection;
executed 825 times by 10 tests: joined += d->currentSelection;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
825
1004 int rowCount = d->model->rowCount(parent);-
1005 for (int row = 0; row < rowCount
row < rowCountDescription
TRUEevaluated 1093 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 130 times by 6 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
; ++row) {
130-1093
1006 for (it = joined.constBegin(); it != joined.constEnd()
it != joined.constEnd()Description
TRUEevaluated 1762 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 881 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
; ++it) {
881-1762
1007 if ((*
(*it).contains...olumn, parent)Description
TRUEevaluated 216 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 1546 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
it).contains(row, column, parent)
(*it).contains...olumn, parent)Description
TRUEevaluated 216 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 1546 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
) {
216-1546
1008 Qt::ItemFlags flags = d->model->index(row, column, parent).flags();-
1009 if ((flags & Qt::ItemIsSelectable) && (flags & Qt::ItemIsEnabled)) {-
1010 row = qMax(row, (*it).bottom());-
1011 break;
executed 212 times by 9 tests: break;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
212
1012 }-
1013 }
executed 4 times by 1 test: end of block
Executed by:
  • tst_QItemView
4
1014 }
executed 1550 times by 9 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
1550
1015 if (it == joined.constEnd()
it == joined.constEnd()Description
TRUEevaluated 881 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 212 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
)
212-881
1016 return
executed 881 times by 9 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
false;
executed 881 times by 9 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
881
1017 }
executed 212 times by 9 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
212
1018 return
executed 130 times by 6 tests: return rowCount > 0;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
rowCount > 0;
executed 130 times by 6 tests: return rowCount > 0;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
130
1019}-
1020-
1021-
1022-
1023-
1024-
1025bool QItemSelectionModel::rowIntersectsSelection(int row, const QModelIndex &parent) const-
1026{-
1027 const QItemSelectionModelPrivate * const d = d_func();-
1028 if (!d->model
!d->modelDescription
TRUEnever evaluated
FALSEevaluated 1349 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QStyleSheetStyle
  • tst_QTableView
)
0-1349
1029 return
never executed: return false;
false;
never executed: return false;
0
1030 if (parent.isValid()
parent.isValid()Description
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 1346 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QStyleSheetStyle
  • tst_QTableView
&& d->model != parent.model()
d->model != parent.model()Description
TRUEnever evaluated
FALSEevaluated 3 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
)
0-1346
1031 return
never executed: return false;
false;
never executed: return false;
0
1032-
1033 QItemSelection sel = d->ranges;-
1034 sel.merge(d->currentSelection, d->currentCommand);-
1035 for (int i = 0; i < sel.count()
i < sel.count()Description
TRUEevaluated 976 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 1075 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QStyleSheetStyle
  • tst_QTableView
; ++i) {
976-1075
1036 QItemSelectionRange range = sel.at(i);-
1037 if (range.parent() != parent
range.parent() != parentDescription
TRUEevaluated 3 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
FALSEevaluated 973 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
)
3-973
1038 return
executed 3 times by 1 test: return false;
Executed by:
  • tst_QItemSelectionModel
false;
executed 3 times by 1 test: return false;
Executed by:
  • tst_QItemSelectionModel
3
1039 int top = range.top();-
1040 int bottom = range.bottom();-
1041 int left = range.left();-
1042 int right = range.right();-
1043 if (top <= row
top <= rowDescription
TRUEevaluated 673 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 300 times by 4 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
&& bottom >= row
bottom >= rowDescription
TRUEevaluated 301 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 372 times by 4 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
) {
300-673
1044 for (int j = left; j <= right
j <= rightDescription
TRUEevaluated 317 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 30 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QItemView
; j++) {
30-317
1045 const Qt::ItemFlags flags = d->model->index(row, j, parent).flags();-
1046 if ((flags & Qt::ItemIsSelectable) && (flags & Qt::ItemIsEnabled))-
1047 return
executed 271 times by 5 tests: return true;
Executed by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
true;
executed 271 times by 5 tests: return true;
Executed by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
271
1048 }
executed 46 times by 2 tests: end of block
Executed by:
  • tst_QItemSelectionModel
  • tst_QItemView
46
1049 }
executed 30 times by 2 tests: end of block
Executed by:
  • tst_QItemSelectionModel
  • tst_QItemView
30
1050 }
executed 702 times by 4 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
702
1051-
1052 return
executed 1075 times by 8 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QStyleSheetStyle
  • tst_QTableView
false;
executed 1075 times by 8 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QStyleSheetStyle
  • tst_QTableView
1075
1053}-
1054-
1055-
1056-
1057-
1058-
1059bool QItemSelectionModel::columnIntersectsSelection(int column, const QModelIndex &parent) const-
1060{-
1061 const QItemSelectionModelPrivate * const d = d_func();-
1062 if (!d->model
!d->modelDescription
TRUEnever evaluated
FALSEevaluated 682 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QStyleSheetStyle
  • tst_QTableView
)
0-682
1063 return
never executed: return false;
false;
never executed: return false;
0
1064 if (parent.isValid()
parent.isValid()Description
TRUEnever evaluated
FALSEevaluated 682 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QStyleSheetStyle
  • tst_QTableView
&& d->model != parent.model()
d->model != parent.model()Description
TRUEnever evaluated
FALSEnever evaluated
)
0-682
1065 return
never executed: return false;
false;
never executed: return false;
0
1066-
1067 QItemSelection sel = d->ranges;-
1068 sel.merge(d->currentSelection, d->currentCommand);-
1069 for (int i = 0; i < sel.count()
i < sel.count()Description
TRUEevaluated 396 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 455 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QStyleSheetStyle
  • tst_QTableView
; ++i) {
396-455
1070 int left = sel.at(i).left();-
1071 int right = sel.at(i).right();-
1072 int top = sel.at(i).top();-
1073 int bottom = sel.at(i).bottom();-
1074 if (left <= column
left <= columnDescription
TRUEevaluated 337 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 59 times by 4 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
&& right >= column
right >= columnDescription
TRUEevaluated 233 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 104 times by 4 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
) {
59-337
1075 for (int j = top; j <= bottom
j <= bottomDescription
TRUEevaluated 245 times by 5 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
FALSEevaluated 6 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QItemView
; j++) {
6-245
1076 const Qt::ItemFlags flags = d->model->index(j, column, parent).flags();-
1077 if ((flags & Qt::ItemIsSelectable) && (flags & Qt::ItemIsEnabled))-
1078 return
executed 227 times by 5 tests: return true;
Executed by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
true;
executed 227 times by 5 tests: return true;
Executed by:
  • tst_QAbstractItemView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
227
1079 }
executed 18 times by 2 tests: end of block
Executed by:
  • tst_QItemSelectionModel
  • tst_QItemView
18
1080 }
executed 6 times by 2 tests: end of block
Executed by:
  • tst_QItemSelectionModel
  • tst_QItemView
6
1081 }
executed 169 times by 4 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
169
1082-
1083 return
executed 455 times by 8 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QStyleSheetStyle
  • tst_QTableView
false;
executed 455 times by 8 tests: return false;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QStyleSheetStyle
  • tst_QTableView
455
1084}-
1085-
1086-
1087-
1088-
1089-
1090-
1091-
1092bool QItemSelectionModel::hasSelection() const-
1093{-
1094 const QItemSelectionModelPrivate * const d = d_func();-
1095 if (d->currentCommand & (Toggle | Deselect)
d->currentComm...le | Deselect)Description
TRUEevaluated 64 times by 6 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeWidget
FALSEevaluated 1121 times by 17 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
) {
64-1121
1096 QItemSelection sel = d->ranges;-
1097 sel.merge(d->currentSelection, d->currentCommand);-
1098 return
executed 64 times by 6 tests: return !sel.isEmpty();
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeWidget
!sel.isEmpty();
executed 64 times by 6 tests: return !sel.isEmpty();
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeWidget
64
1099 } else {-
1100 return
executed 1121 times by 17 tests: return !(d->ranges.isEmpty() && d->currentSelection.isEmpty());
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
!(d->ranges.isEmpty() && d->currentSelection.isEmpty());
executed 1121 times by 17 tests: return !(d->ranges.isEmpty() && d->currentSelection.isEmpty());
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QSortFilterProxyModel
  • tst_QStyleSheetStyle
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
1121
1101 }-
1102}-
1103-
1104-
1105-
1106-
1107-
1108QModelIndexList QItemSelectionModel::selectedIndexes() const-
1109{-
1110 const QItemSelectionModelPrivate * const d = d_func();-
1111 QItemSelection selected = d->ranges;-
1112 selected.merge(d->currentSelection, d->currentCommand);-
1113 return
executed 588 times by 15 tests: return selected.indexes();
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
selected.indexes();
executed 588 times by 15 tests: return selected.indexes();
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
588
1114}-
1115QModelIndexList QItemSelectionModel::selectedRows(int column) const-
1116{-
1117 QModelIndexList indexes;-
1118-
1119-
1120 QSet< QPair<QModelIndex, int> > rowsSeen;-
1121-
1122 const QItemSelection ranges = selection();-
1123 for (int i = 0; i < ranges.count()
i < ranges.count()Description
TRUEevaluated 866 times by 6 tests
Evaluated by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 1145 times by 9 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
; ++i) {
866-1145
1124 const QItemSelectionRange &range = ranges.at(i);-
1125 QModelIndex parent = range.parent();-
1126 for (int row = range.top(); row <= range.bottom()
row <= range.bottom()Description
TRUEevaluated 911 times by 6 tests
Evaluated by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 866 times by 6 tests
Evaluated by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
; row++) {
866-911
1127 QPair<QModelIndex, int> rowDef = qMakePair(parent, row);-
1128 if (!rowsSeen.contains(rowDef)
!rowsSeen.contains(rowDef)Description
TRUEevaluated 911 times by 6 tests
Evaluated by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEnever evaluated
) {
0-911
1129 rowsSeen << rowDef;-
1130 if (isRowSelected(row, parent)
isRowSelected(row, parent)Description
TRUEevaluated 901 times by 6 tests
Evaluated by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 10 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
) {
10-901
1131 indexes.append(model()->index(row, column, parent));-
1132 }
executed 901 times by 6 tests: end of block
Executed by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
901
1133 }
executed 911 times by 6 tests: end of block
Executed by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
911
1134 }
executed 911 times by 6 tests: end of block
Executed by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
911
1135 }
executed 866 times by 6 tests: end of block
Executed by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
866
1136-
1137 return
executed 1145 times by 9 tests: return indexes;
Executed by:
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
indexes;
executed 1145 times by 9 tests: return indexes;
Executed by:
  • tst_QAccessibility
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
1145
1138}-
1139QModelIndexList QItemSelectionModel::selectedColumns(int row) const-
1140{-
1141 QModelIndexList indexes;-
1142-
1143-
1144 QSet< QPair<QModelIndex, int> > columnsSeen;-
1145-
1146 const QItemSelection ranges = selection();-
1147 for (int i = 0; i < ranges.count()
i < ranges.count()Description
TRUEevaluated 22 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QTableView
FALSEevaluated 11 times by 3 tests
Evaluated by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QTableView
; ++i) {
11-22
1148 const QItemSelectionRange &range = ranges.at(i);-
1149 QModelIndex parent = range.parent();-
1150 for (int column = range.left(); column <= range.right()
column <= range.right()Description
TRUEevaluated 59 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QTableView
FALSEevaluated 22 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QTableView
; column++) {
22-59
1151 QPair<QModelIndex, int> columnDef = qMakePair(parent, column);-
1152 if (!columnsSeen.contains(columnDef)
!columnsSeen.c...ins(columnDef)Description
TRUEevaluated 59 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QTableView
FALSEnever evaluated
) {
0-59
1153 columnsSeen << columnDef;-
1154 if (isColumnSelected(column, parent)
isColumnSelect...olumn, parent)Description
TRUEevaluated 29 times by 2 tests
Evaluated by:
  • tst_QItemSelectionModel
  • tst_QTableView
FALSEevaluated 30 times by 1 test
Evaluated by:
  • tst_QTableView
) {
29-30
1155 indexes.append(model()->index(row, column, parent));-
1156 }
executed 29 times by 2 tests: end of block
Executed by:
  • tst_QItemSelectionModel
  • tst_QTableView
29
1157 }
executed 59 times by 2 tests: end of block
Executed by:
  • tst_QItemSelectionModel
  • tst_QTableView
59
1158 }
executed 59 times by 2 tests: end of block
Executed by:
  • tst_QItemSelectionModel
  • tst_QTableView
59
1159 }
executed 22 times by 2 tests: end of block
Executed by:
  • tst_QItemSelectionModel
  • tst_QTableView
22
1160-
1161 return
executed 11 times by 3 tests: return indexes;
Executed by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QTableView
indexes;
executed 11 times by 3 tests: return indexes;
Executed by:
  • tst_QAccessibility
  • tst_QItemSelectionModel
  • tst_QTableView
11
1162}-
1163-
1164-
1165-
1166-
1167const QItemSelection QItemSelectionModel::selection() const-
1168{-
1169 const QItemSelectionModelPrivate * const d = d_func();-
1170 QItemSelection selected = d->ranges;-
1171 selected.merge(d->currentSelection, d->currentCommand);-
1172-
1173-
1174 auto isNotValid = [](const QItemSelectionRange& range) {-
1175 return
executed 1284 times by 12 tests: return !range.isValid();
Executed by:
  • tst_QAbstractItemView
  • tst_QColumnView
  • tst_QComboBox
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
!range.isValid();
executed 1284 times by 12 tests: return !range.isValid();
Executed by:
  • tst_QAbstractItemView
  • tst_QColumnView
  • tst_QComboBox
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QListView
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
1284
1176 };-
1177-
1178 selected.erase(std::remove_if(selected.begin(), selected.end(),-
1179 isNotValid),-
1180 selected.end());-
1181 return
executed 11454 times by 42 tests: return selected;
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
selected;
executed 11454 times by 42 tests: return selected;
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
11454
1182}-
1183QAbstractItemModel *QItemSelectionModel::model()-
1184{-
1185 return
executed 12802 times by 42 tests: return d_func()->model;
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
d_func()->model;
executed 12802 times by 42 tests: return d_func()->model;
Executed by:
  • tst_ModelTest
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDataWidgetMapper
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFileSystemModel
  • tst_QFiledialog
  • tst_QFontComboBox
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QInputDialog
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QLineEdit
  • tst_QListView
  • tst_QListWidget
  • ...
12802
1186}-
1187-
1188-
1189-
1190-
1191const QAbstractItemModel *QItemSelectionModel::model() const-
1192{-
1193 return
executed 930 times by 6 tests: return d_func()->model;
Executed by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
d_func()->model;
executed 930 times by 6 tests: return d_func()->model;
Executed by:
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
930
1194}-
1195void QItemSelectionModel::setModel(QAbstractItemModel *model)-
1196{-
1197 QItemSelectionModelPrivate * const d = d_func();-
1198 if (d->model == model
d->model == modelDescription
TRUEnever evaluated
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_QItemSelectionModel
)
0-2
1199 return;
never executed: return;
0
1200-
1201 d->initModel(model);-
1202 modelChanged(model);-
1203}
executed 2 times by 1 test: end of block
Executed by:
  • tst_QItemSelectionModel
2
1204-
1205-
1206-
1207-
1208-
1209void QItemSelectionModel::emitSelectionChanged(const QItemSelection &newSelection,-
1210 const QItemSelection &oldSelection)-
1211{-
1212-
1213 if ((oldSelection.isEmpty()
oldSelection.isEmpty()Description
TRUEevaluated 2621 times by 29 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • ...
FALSEevaluated 4679 times by 26 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • ...
&& newSelection.isEmpty()
newSelection.isEmpty()Description
TRUEevaluated 636 times by 24 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFontDialog
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 1985 times by 27 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
) ||
636-4679
1214 oldSelection == newSelection
oldSelection == newSelectionDescription
TRUEevaluated 1043 times by 22 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 5621 times by 27 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
)
1043-5621
1215 return;
executed 1679 times by 26 tests: return;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QHeaderView
  • tst_QItemDelegate
  • tst_QItemModel
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
1679
1216-
1217-
1218 if (oldSelection.isEmpty()
oldSelection.isEmpty()Description
TRUEevaluated 1985 times by 27 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
FALSEevaluated 3636 times by 25 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
  • tst_languageChange
|| newSelection.isEmpty()
newSelection.isEmpty()Description
TRUEevaluated 1248 times by 19 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QDateTimeEdit
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSidebar
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_languageChange
FALSEevaluated 2388 times by 19 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
) {
1248-3636
1219 selectionChanged(newSelection, oldSelection);-
1220 return;
executed 3233 times by 27 tests: return;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QCalendarWidget
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QDateTimeEdit
  • tst_QDirModel
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QGraphicsProxyWidget
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QMenu
  • tst_QSidebar
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTableWidget
  • tst_QTreeView
  • tst_QTreeWidget
  • ...
3233
1221 }-
1222-
1223 QItemSelection deselected = oldSelection;-
1224 QItemSelection selected = newSelection;-
1225-
1226-
1227 bool advance;-
1228 for (int o = 0; o < deselected.count()
o < deselected.count()Description
TRUEevaluated 2550 times by 19 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 2388 times by 19 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
; ++o) {
2388-2550
1229 advance = true;-
1230 for (int s = 0; s < selected.count()
s < selected.count()Description
TRUEevaluated 3478 times by 19 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 2338 times by 17 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
&& o < deselected.count()
o < deselected.count()Description
TRUEevaluated 3266 times by 19 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 212 times by 14 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
;) {
212-3478
1231 if (deselected.at(o) == selected.at(s)
deselected.at(...selected.at(s)Description
TRUEevaluated 717 times by 14 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 2549 times by 17 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
) {
717-2549
1232 deselected.removeAt(o);-
1233 selected.removeAt(s);-
1234 advance = false;-
1235 }
executed 717 times by 14 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
else {
717
1236 ++s;-
1237 }
executed 2549 times by 17 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
2549
1238 }-
1239 if (advance
advanceDescription
TRUEevaluated 2264 times by 17 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 286 times by 14 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
)
286-2264
1240 ++
executed 2264 times by 17 tests: ++o;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
o;
executed 2264 times by 17 tests: ++o;
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
2264
1241 }
executed 2550 times by 19 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
2550
1242-
1243-
1244 QItemSelection intersections;-
1245 for (int o = 0; o < deselected.count()
o < deselected.count()Description
TRUEevaluated 2458 times by 17 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 2388 times by 19 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
; ++o) {
2388-2458
1246 for (int s = 0; s < selected.count()
s < selected.count()Description
TRUEevaluated 2680 times by 17 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
FALSEevaluated 2458 times by 17 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
; ++s) {
2458-2680
1247 if (deselected.at(o).intersects(selected.at(s))
deselected.at(...elected.at(s))Description
TRUEevaluated 252 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeWidget
FALSEevaluated 2428 times by 17 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
)
252-2428
1248 intersections.append(deselected.at(o).intersected(selected.at(s)));
executed 252 times by 10 tests: intersections.append(deselected.at(o).intersected(selected.at(s)));
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeWidget
252
1249 }
executed 2680 times by 17 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
2680
1250 }
executed 2458 times by 17 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
2458
1251-
1252-
1253 for (int i = 0; i < intersections.count()
i < intersections.count()Description
TRUEevaluated 252 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeWidget
FALSEevaluated 2388 times by 19 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
; ++i) {
252-2388
1254-
1255 for (int o = 0; o < deselected.count()
o < deselected.count()Description
TRUEevaluated 655 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeWidget
FALSEevaluated 252 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeWidget
;) {
252-655
1256 if (deselected.at(o).intersects(intersections.at(i))
deselected.at(...ections.at(i))Description
TRUEevaluated 252 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeWidget
FALSEevaluated 403 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeWidget
) {
252-403
1257 QItemSelection::split(deselected.at(o), intersections.at(i), &deselected);-
1258 deselected.removeAt(o);-
1259 }
executed 252 times by 10 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeWidget
else {
252
1260 ++o;-
1261 }
executed 403 times by 8 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeWidget
403
1262 }-
1263-
1264 for (int s = 0; s < selected.count()
s < selected.count()Description
TRUEevaluated 639 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeWidget
FALSEevaluated 252 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeWidget
;) {
252-639
1265 if (selected.at(s).intersects(intersections.at(i))
selected.at(s)...ections.at(i))Description
TRUEevaluated 262 times by 10 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeWidget
FALSEevaluated 377 times by 7 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
) {
262-377
1266 QItemSelection::split(selected.at(s), intersections.at(i), &selected);-
1267 selected.removeAt(s);-
1268 }
executed 262 times by 10 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeWidget
else {
262
1269 ++s;-
1270 }
executed 377 times by 7 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
377
1271 }-
1272 }
executed 252 times by 10 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QTableView
  • tst_QTreeWidget
252
1273-
1274 if (!selected.isEmpty()
!selected.isEmpty()Description
TRUEevaluated 2293 times by 19 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
FALSEevaluated 95 times by 9 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeWidget
|| !deselected.isEmpty()
!deselected.isEmpty()Description
TRUEevaluated 85 times by 8 tests
Evaluated by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QFiledialog
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QTableView
  • tst_QTreeWidget
FALSEevaluated 10 times by 3 tests
Evaluated by:
  • tst_QItemDelegate
  • tst_QItemView
  • tst_QTableView
)
10-2293
1275 selectionChanged(selected, deselected);
executed 2378 times by 19 tests: selectionChanged(selected, deselected);
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
2378
1276}
executed 2388 times by 19 tests: end of block
Executed by:
  • tst_QAbstractItemView
  • tst_QAccessibility
  • tst_QColumnView
  • tst_QComboBox
  • tst_QCompleter
  • tst_QFileDialog2
  • tst_QFiledialog
  • tst_QFontDialog
  • tst_QItemDelegate
  • tst_QItemSelectionModel
  • tst_QItemView
  • tst_QListView
  • tst_QListWidget
  • tst_QSortFilterProxyModel
  • tst_QStandardItemModel
  • tst_QTableView
  • tst_QTreeView
  • tst_QTreeWidget
  • tst_QTreeWidgetItemIterator
2388
1277-
1278-
1279QDebug operator<<(QDebug dbg, const QItemSelectionRange &range)-
1280{-
1281 QDebugStateSaver saver(dbg);-
1282 dbg.nospace() << "QItemSelectionRange(" << range.topLeft()-
1283 << ',' << range.bottomRight() << ')';-
1284 return
never executed: return dbg;
dbg;
never executed: return dbg;
0
1285}-
1286-
1287-
1288-
1289-
Switch to Source codePreprocessed file

Generated by Squish Coco Non-Commercial 4.3.0-BETA-master-30-08-2018-4cb69e9