mirror of
https://github.com/reactos/reactos.git
synced 2025-05-23 02:56:09 +00:00
[DEVMGR]
- Hide legacy devices and volumes by default - Patch by Eric Kohl CORE-10396 svn path=/trunk/; revision=69704
This commit is contained in:
parent
dbff9a412d
commit
4b92ce00d5
2 changed files with 18 additions and 1 deletions
|
@ -196,9 +196,14 @@ CDeviceNode::IsHidden()
|
|||
NULL);
|
||||
if (cr == CR_SUCCESS)
|
||||
{
|
||||
return ((m_Status & DN_NO_SHOW_IN_DM) != 0);
|
||||
if (m_Status & DN_NO_SHOW_IN_DM)
|
||||
return true;
|
||||
}
|
||||
|
||||
if (IsEqualGUID(*GetClassGuid(), GUID_DEVCLASS_LEGACYDRIVER) ||
|
||||
IsEqualGUID(*GetClassGuid(), GUID_DEVCLASS_VOLUME))
|
||||
return true;
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -460,6 +460,18 @@ CDeviceView::ListDevicesByType()
|
|||
if (IsEqualGUID(ClassGuid, GUID_DEVCLASS_UNKNOWN))
|
||||
bClassUnknown = true;
|
||||
|
||||
// Check if this is a hidden class
|
||||
if (IsEqualGUID(ClassGuid, GUID_DEVCLASS_LEGACYDRIVER) ||
|
||||
IsEqualGUID(ClassGuid, GUID_DEVCLASS_VOLUME))
|
||||
{
|
||||
// Ignore this device if we aren't displaying hidden devices
|
||||
if (m_ShowHidden == FALSE)
|
||||
{
|
||||
ClassIndex++;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
do
|
||||
{
|
||||
// Get a handle to all the devices in this class
|
||||
|
|
Loading…
Reference in a new issue