mirror of
https://github.com/reactos/reactos.git
synced 2025-02-23 00:45:24 +00:00
[DEVMGR]
Display device relations. svn path=/trunk/; revision=68084
This commit is contained in:
parent
e2952ec3d1
commit
98710e2c01
1 changed files with 61 additions and 2 deletions
|
@ -1328,6 +1328,58 @@ DisplayClassProperties(IN PDEVADVPROP_INFO dap,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static VOID
|
||||||
|
DisplayDeviceRelations(
|
||||||
|
IN PDEVADVPROP_INFO dap,
|
||||||
|
IN HWND hwndListView,
|
||||||
|
IN ULONG ulFlags)
|
||||||
|
{
|
||||||
|
ULONG ulLength = 0;
|
||||||
|
LPWSTR pszBuffer = NULL, pszStr;
|
||||||
|
INT index = 0, len;
|
||||||
|
|
||||||
|
CONFIGRET ret;
|
||||||
|
|
||||||
|
ret = CM_Get_Device_ID_List_Size_ExW(&ulLength,
|
||||||
|
dap->szDeviceID,
|
||||||
|
ulFlags,
|
||||||
|
NULL);
|
||||||
|
if (ret != CR_SUCCESS)
|
||||||
|
return;
|
||||||
|
|
||||||
|
pszBuffer = HeapAlloc(GetProcessHeap(),
|
||||||
|
HEAP_ZERO_MEMORY,
|
||||||
|
ulLength);
|
||||||
|
if (pszBuffer == NULL)
|
||||||
|
return;
|
||||||
|
|
||||||
|
ret = CM_Get_Device_ID_List_ExW(dap->szDeviceID,
|
||||||
|
pszBuffer,
|
||||||
|
ulLength,
|
||||||
|
ulFlags,
|
||||||
|
NULL);
|
||||||
|
if (ret != CR_SUCCESS)
|
||||||
|
{
|
||||||
|
HeapFree(GetProcessHeap(), 0, pszBuffer);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
pszStr = pszBuffer;
|
||||||
|
index = 0;
|
||||||
|
while (*pszStr != 0)
|
||||||
|
{
|
||||||
|
len = wcslen(pszStr) + 1;
|
||||||
|
|
||||||
|
SetListViewText(hwndListView, index, pszStr);
|
||||||
|
|
||||||
|
pszStr += len;
|
||||||
|
index++;
|
||||||
|
}
|
||||||
|
|
||||||
|
HeapFree(GetProcessHeap(), 0, pszBuffer);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
static VOID
|
static VOID
|
||||||
DisplayDeviceProperties(IN PDEVADVPROP_INFO dap,
|
DisplayDeviceProperties(IN PDEVADVPROP_INFO dap,
|
||||||
IN HWND hwndComboBox,
|
IN HWND hwndComboBox,
|
||||||
|
@ -1400,16 +1452,23 @@ DisplayDeviceProperties(IN PDEVADVPROP_INFO dap,
|
||||||
hwndListView);
|
hwndListView);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
#if 0
|
|
||||||
case 10: /* Ejection relation */
|
case 10: /* Ejection relation */
|
||||||
|
DisplayDeviceRelations(dap,
|
||||||
|
hwndListView,
|
||||||
|
CM_GETIDLIST_FILTER_EJECTRELATIONS);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 11: /* Removal relations */
|
case 11: /* Removal relations */
|
||||||
|
DisplayDeviceRelations(dap,
|
||||||
|
hwndListView,
|
||||||
|
CM_GETIDLIST_FILTER_REMOVALRELATIONS);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 12: /* Bus relation */
|
case 12: /* Bus relation */
|
||||||
|
DisplayDeviceRelations(dap,
|
||||||
|
hwndListView,
|
||||||
|
CM_GETIDLIST_FILTER_BUSRELATIONS);
|
||||||
break;
|
break;
|
||||||
#endif
|
|
||||||
|
|
||||||
case 13: /* Device Upper Filters */
|
case 13: /* Device Upper Filters */
|
||||||
DisplayDevicePropertyText(dap,
|
DisplayDevicePropertyText(dap,
|
||||||
|
|
Loading…
Reference in a new issue