MCPcopy Create free account
hub / github.com/InteractiveComputerGraphics/SPlisHSPlasH / NFD_PathSet_GetCount

Function NFD_PathSet_GetCount

extern/nfd/nfd_win.cpp:599–613  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

597}
598
599nfdresult_t NFD_PathSet_GetCount(const nfdpathset_t* pathSet, nfdpathsetsize_t* count) {
600 assert(pathSet);
601 // const_cast because methods on IShellItemArray aren't const, but it should act like const to
602 // the caller
603 ::IShellItemArray* psiaPathSet =
604 const_cast<::IShellItemArray*>(static_cast<const ::IShellItemArray*>(pathSet));
605
606 DWORD numPaths;
607 if (!SUCCEEDED(psiaPathSet->GetCount(&numPaths))) {
608 NFDi_SetError("Could not get path count.");
609 return NFD_ERROR;
610 }
611 *count = numPaths;
612 return NFD_OKAY;
613}
614
615nfdresult_t NFD_PathSet_GetPathN(const nfdpathset_t* pathSet,
616 nfdpathsetsize_t index,

Callers 1

CountFunction · 0.50

Calls 1

NFDi_SetErrorFunction · 0.70

Tested by

no test coverage detected