MCPcopy Create free account
hub / github.com/KDE/kdevelop / index

Method index

kdevplatform/util/placeholderitemproxymodel.cpp:194–204  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

192}
193
194QModelIndex PlaceholderItemProxyModel::index(int row, int column, const QModelIndex& parent) const
195{
196 Q_ASSERT(!parent.isValid());
197 Q_UNUSED(parent);
198
199 const bool isPlaceHolderRow = (sourceModel() ? row == sourceModel()->rowCount() : false);
200 if (isPlaceHolderRow) {
201 return createIndex(row, column);
202 }
203 return QIdentityProxyModel::index(row, column, parent);
204}
205
206bool PlaceholderItemProxyModel::validateRow(const QModelIndex& index, const QVariant& value) const
207{

Callers 7

viewSelectionChangedMethod · 0.45
ensureViewSelectedMethod · 0.45
setModelMethod · 0.45
setCurrentIndexMethod · 0.45
rowsAboutToBeInsertedMethod · 0.45
currentProfileMethod · 0.45
effectiveProfileNameMethod · 0.45

Calls 4

createIndexFunction · 0.85
indexFunction · 0.50
isValidMethod · 0.45
rowCountMethod · 0.45

Tested by

no test coverage detected