MCPcopy Create free account
hub / github.com/NatronGitHub/Natron / indexInParent

Method indexInParent

Engine/FileSystemModel.cpp:314–328  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

312}
313
314int
315FileSystemItem::indexInParent() const
316{
317 FileSystemItemPtr parent = _imp->parent.lock();
318
319 if (parent) {
320 for (U32 i = 0; i < parent->_imp->children.size(); ++i) {
321 if (parent->_imp->children[i].get() == this) {
322 return i;
323 }
324 }
325 }
326
327 return -1;
328}
329
330bool
331FileSystemItem::isDir() const

Callers 3

parentMethod · 0.80
indexMethod · 0.80
mkdirMethod · 0.80

Calls 3

lockMethod · 0.45
sizeMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected