Author: cwittich
Date: Wed Apr 1 12:03:12 2015
New Revision: 67005
URL:
http://svn.reactos.org/svn/reactos?rev=67005&view=rev
Log:
[DEVMGR]
don't show an empty list when no driver files are required
CORE-3341
Modified:
trunk/reactos/dll/win32/devmgr/advprop.c
trunk/reactos/dll/win32/devmgr/hwpage.c
trunk/reactos/dll/win32/devmgr/precomp.h
Modified: trunk/reactos/dll/win32/devmgr/advprop.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/devmgr/advprop.c…
==============================================================================
--- trunk/reactos/dll/win32/devmgr/advprop.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/devmgr/advprop.c [iso-8859-1] Wed Apr 1 12:03:12 2015
@@ -319,6 +319,7 @@
{
LV_COLUMN lvc;
HWND hDriversListView;
+ WCHAR szBuffer[260];
dap = (PDEVADVPROP_INFO)lParam;
if (dap != NULL)
@@ -341,6 +342,13 @@
UpdateDriverDetailsDlg(hwndDlg,
hDriversListView,
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;
Modified: trunk/reactos/dll/win32/devmgr/hwpage.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/devmgr/hwpage.c?…
==============================================================================
--- trunk/reactos/dll/win32/devmgr/hwpage.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/devmgr/hwpage.c [iso-8859-1] Wed Apr 1 12:03:12 2015
@@ -962,8 +962,8 @@
case WM_DESTROY:
{
- /* 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);
+ /* 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);
/* free devices list */
FreeDevicesList(hpd);
Modified: trunk/reactos/dll/win32/devmgr/precomp.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/devmgr/precomp.h…
==============================================================================
--- trunk/reactos/dll/win32/devmgr/precomp.h [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/devmgr/precomp.h [iso-8859-1] Wed Apr 1 12:03:12 2015
@@ -2,6 +2,7 @@
#define __DEVMGR_H
#include <stdarg.h>
+#include <stdlib.h>
#define WIN32_NO_STATUS
#include <windef.h>