{
LPENUM_SERVICE_STATUSW lpServiceStatus;
LPTSTR lpNoDepends;
DWORDcount, i;
BOOL bHasChildren;
/* Get a list of service dependents */
lpServiceStatus = TV2_GetDependants(lpServiceName, &count);
if (lpServiceStatus)
{
for (i = 0; i < count; i++)
{
/* Does this item need a +/- box? */
bHasChildren = TV2_HasDependantServices(lpServiceStatus[i].lpServiceName);
/* Add it */AddItemToTreeView(pDlgInfo->hDependsTreeView2,
hParent,
lpServiceStatus[i].lpDisplayName,
lpServiceStatus[i].lpServiceName,
lpServiceStatus[i].ServiceStatus.dwServiceType,
bHasChildren);
}
HeapFree(GetProcessHeap(),
0,
lpServiceStatus);
}
else
{
/* If there is no parent, set the tree to 'no dependencies' */if (!hParent)
{
/* Load the 'No dependencies' string */AllocAndLoadString(&lpNoDepends, hInstance, IDS_NO_DEPENDS);
AddItemToTreeView(pDlgInfo->hDependsTreeView2,
NULL,
lpNoDepends,
NULL,
0,
FALSE);
HeapFree(ProcessHeap,
0,
lpNoDepends);
/* Disable the window */EnableWindow(pDlgInfo->hDependsTreeView2, FALSE);
}
}
}
Generated on Sat May 26 2012 04:40:10 for ReactOS by
1.7.6.1
ReactOS is a registered trademark or a trademark of ReactOS Foundation in the United States and other countries.