mirror of
https://github.com/reactos/reactos.git
synced 2025-02-24 01:15:09 +00:00
[DEVMGR]
don't show an empty list when no driver files are required CORE-3341 svn path=/trunk/; revision=67005
This commit is contained in:
parent
79ca4fbf90
commit
aae247f9ff
3 changed files with 11 additions and 2 deletions
|
@ -319,6 +319,7 @@ DriverDetailsDlgProc(IN HWND hwndDlg,
|
||||||
{
|
{
|
||||||
LV_COLUMN lvc;
|
LV_COLUMN lvc;
|
||||||
HWND hDriversListView;
|
HWND hDriversListView;
|
||||||
|
WCHAR szBuffer[260];
|
||||||
|
|
||||||
dap = (PDEVADVPROP_INFO)lParam;
|
dap = (PDEVADVPROP_INFO)lParam;
|
||||||
if (dap != NULL)
|
if (dap != NULL)
|
||||||
|
@ -341,6 +342,13 @@ DriverDetailsDlgProc(IN HWND hwndDlg,
|
||||||
UpdateDriverDetailsDlg(hwndDlg,
|
UpdateDriverDetailsDlg(hwndDlg,
|
||||||
hDriversListView,
|
hDriversListView,
|
||||||
dap);
|
dap);
|
||||||
|
|
||||||
|
if (ListView_GetItemCount(hDriversListView) == 0)
|
||||||
|
{
|
||||||
|
if(LoadStringW(hDllInstance, IDS_NODRIVERS, szBuffer, _countof(szBuffer)))
|
||||||
|
MessageBoxW(hwndDlg, szBuffer, dap->szDevName, MB_OK);
|
||||||
|
EndDialog(hwndDlg, IDCANCEL);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Ret = TRUE;
|
Ret = TRUE;
|
||||||
|
|
|
@ -962,8 +962,8 @@ HardwareDlgProc(IN HWND hwndDlg,
|
||||||
|
|
||||||
case WM_DESTROY:
|
case WM_DESTROY:
|
||||||
{
|
{
|
||||||
/* zero hpd pointer in window data, because it can be used later (WM_DESTROY has not to be last message) */
|
/* zero hpd pointer in window data, because it can be used later (WM_DESTROY has not to be last message) */
|
||||||
SetWindowLongPtr(hwndDlg, DWL_USER, (DWORD_PTR)NULL);
|
SetWindowLongPtr(hwndDlg, DWL_USER, (DWORD_PTR)NULL);
|
||||||
|
|
||||||
/* free devices list */
|
/* free devices list */
|
||||||
FreeDevicesList(hpd);
|
FreeDevicesList(hpd);
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
#define __DEVMGR_H
|
#define __DEVMGR_H
|
||||||
|
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
|
||||||
#define WIN32_NO_STATUS
|
#define WIN32_NO_STATUS
|
||||||
#include <windef.h>
|
#include <windef.h>
|
||||||
|
|
Loading…
Reference in a new issue