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

Method setModelData

plugins/scratchpad/scratchpadview.cpp:44–50  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

42 }
43
44 void setModelData(QWidget* editor, QAbstractItemModel* model, const QModelIndex& index) const override
45 {
46 const QString previousName = index.data().toString();
47 QStyledItemDelegate::setModelData(editor, model, index);
48 const auto* proxyModel = static_cast<QAbstractProxyModel*>(model);
49 m_scratchpad->renameScratch(proxyModel->mapToSource(index), previousName);
50 }
51
52private:
53 Scratchpad* m_scratchpad;

Callers

nothing calls this directly

Calls 4

renameScratchMethod · 0.80
toStringMethod · 0.45
dataMethod · 0.45
mapToSourceMethod · 0.45

Tested by

no test coverage detected