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

Method parent

kdevplatform/shell/problemmodel.cpp:181–195  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

179}
180
181QModelIndex ProblemModel::parent(const QModelIndex& index) const
182{
183 auto *node = reinterpret_cast<ProblemStoreNode*>(index.internalPointer());
184 if (!node) {
185 return {};
186 }
187
188 ProblemStoreNode *parent = node->parent();
189 if (!parent || parent->isRoot()) {
190 return {};
191 }
192
193 int idx = parent->index();
194 return createIndex(idx, 0, parent);
195}
196
197QModelIndex ProblemModel::index(int row, int column, const QModelIndex& parent) const
198{

Callers 7

addRuntimesMethod · 0.45
unloadMethod · 0.45
prettyFilePathMethod · 0.45
mapSourceBuildMethod · 0.45
pluginForIndexMethod · 0.45
initProjectFilesMethod · 0.45
openMethod · 0.45

Calls 2

createIndexFunction · 0.85
indexMethod · 0.45

Tested by

no test coverage detected