Author: ekohl Date: Fri Jan 1 15:44:06 2010 New Revision: 44854
URL: http://svn.reactos.org/svn/reactos?rev=44854&view=rev Log: [devmgr] - Add missing string resources and translate the german ones. - Set the focus to the combobox when the details page is opened. - Don't display an error message when a property is not set for the selected device. - Display 'Capabilities' and 'Config Flags' as DWORD values.
Ooops! These should have been committed as well.
Modified: trunk/reactos/dll/win32/devmgr/advprop.c trunk/reactos/dll/win32/devmgr/resource.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] Fri Jan 1 15:44:06 2010 @@ -470,15 +470,16 @@ UINT Properties[] = { IDS_PROP_DEVICEID, - IDS_PROP_HARDWAREID, + IDS_PROP_HARDWAREIDS, IDS_PROP_COMPATIBLEIDS, IDS_PROP_MATCHINGDEVICEID, IDS_PROP_SERVICE, IDS_PROP_ENUMERATOR, + IDS_PROP_CAPABILITIES, IDS_PROP_DEVNODEFLAGS, IDS_PROP_CONFIGFLAGS, IDS_PROP_CSCONFIGFLAGS, - IDS_PROP_EJECTRELATIONS, + IDS_PROP_EJECTIONRELATIONS, IDS_PROP_REMOVALRELATIONS, IDS_PROP_BUSRELATIONS, IDS_PROP_DEVUPPERFILTERS, @@ -487,7 +488,11 @@ IDS_PROP_CLASSLOWERFILTERS, IDS_PROP_CLASSINSTALLER, IDS_PROP_CLASSCOINSTALLER, - IDS_PROP_DEVICECOINSTALLER + IDS_PROP_DEVICECOINSTALLER, + IDS_PROP_FIRMWAREREVISION, + IDS_PROP_CURRENTPOWERSTATE, + IDS_PROP_POWERCAPABILITIES, + IDS_PROP_POWERSTATEMAPPINGS };
@@ -543,6 +548,8 @@ 0);
SetListViewText(hwndListView, 0, dap->szDeviceID); + + SetFocus(hwndComboBox); }
@@ -573,16 +580,19 @@
dwSize = 0; SetupDiGetDeviceRegistryProperty(DeviceInfoSet, - DeviceInfoData, - dwProperty, - &dwType, - NULL, - 0, - &dwSize); + DeviceInfoData, + dwProperty, + &dwType, + NULL, + 0, + &dwSize); if (dwSize == 0) { - swprintf(dap->szTemp, L"Error: Getting the size failed! (Error: %ld)", GetLastError()); - SetListViewText(hwndListView, 0, dap->szTemp); + if (GetLastError() != ERROR_FILE_NOT_FOUND) + { + swprintf(dap->szTemp, L"Error: Getting the size failed! (Error: %ld)", GetLastError()); + SetListViewText(hwndListView, 0, dap->szTemp); + } return; }
@@ -621,6 +631,11 @@ index++; } } + else if (dwType == REG_DWORD) + { + swprintf(dap->szTemp, L"0x%08x", *lpBuffer); + SetListViewText(hwndListView, 0, dap->szTemp); + } else { SetListViewText(hwndListView, 0, L"Error: Unsupported value type!"); @@ -674,6 +689,11 @@ SPDRP_COMPATIBLEIDS); break;
+#if 0 + case 3: /* Matching ID */ + break; +#endif + case 4: /* Service */ SetDevicePropertyText(dap, hwndListView, @@ -686,13 +706,35 @@ SPDRP_ENUMERATOR_NAME); break;
- case 12: /* Upper Filters */ + case 6: /* Capabilities */ + SetDevicePropertyText(dap, + hwndListView, + SPDRP_CAPABILITIES); + break; + +#if 0 + case 7: /* Devnode Flags */ + break; +#endif + + case 8: /* Config Flags */ + SetDevicePropertyText(dap, + hwndListView, + SPDRP_CONFIGFLAGS); + break; + +#if 0 + case 9: /* CSConfig Flags */ + break; +#endif + + case 13: /* Upper Filters */ SetDevicePropertyText(dap, hwndListView, SPDRP_UPPERFILTERS); break;
- case 13: /* Lower Filters */ + case 14: /* Lower Filters */ SetDevicePropertyText(dap, hwndListView, SPDRP_LOWERFILTERS);
Modified: trunk/reactos/dll/win32/devmgr/resource.h URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/devmgr/resource.h... ============================================================================== --- trunk/reactos/dll/win32/devmgr/resource.h [iso-8859-1] (original) +++ trunk/reactos/dll/win32/devmgr/resource.h [iso-8859-1] Fri Jan 1 15:44:06 2010 @@ -124,24 +124,29 @@ #define IDS_DEV_SETPROPERTIES_FAILED 0x238
#define IDS_PROP_DEVICEID 0x300 -#define IDS_PROP_HARDWAREID 0x301 +#define IDS_PROP_HARDWAREIDS 0x301 #define IDS_PROP_COMPATIBLEIDS 0x302 #define IDS_PROP_MATCHINGDEVICEID 0x303 #define IDS_PROP_SERVICE 0x304 #define IDS_PROP_ENUMERATOR 0x305 -#define IDS_PROP_DEVNODEFLAGS 0x306 -#define IDS_PROP_CONFIGFLAGS 0x307 -#define IDS_PROP_CSCONFIGFLAGS 0x308 -#define IDS_PROP_EJECTRELATIONS 0x309 -#define IDS_PROP_REMOVALRELATIONS 0x30A -#define IDS_PROP_BUSRELATIONS 0x30B -#define IDS_PROP_DEVUPPERFILTERS 0x30C -#define IDS_PROP_DEVLOWERFILTERS 0x30D -#define IDS_PROP_CLASSUPPERFILTERS 0x30E -#define IDS_PROP_CLASSLOWERFILTERS 0x30F -#define IDS_PROP_CLASSINSTALLER 0x310 -#define IDS_PROP_CLASSCOINSTALLER 0x311 -#define IDS_PROP_DEVICECOINSTALLER 0x312 +#define IDS_PROP_CAPABILITIES 0x306 +#define IDS_PROP_DEVNODEFLAGS 0x307 +#define IDS_PROP_CONFIGFLAGS 0x308 +#define IDS_PROP_CSCONFIGFLAGS 0x309 +#define IDS_PROP_EJECTIONRELATIONS 0x30A +#define IDS_PROP_REMOVALRELATIONS 0x30B +#define IDS_PROP_BUSRELATIONS 0x30C +#define IDS_PROP_DEVUPPERFILTERS 0x30D +#define IDS_PROP_DEVLOWERFILTERS 0x30E +#define IDS_PROP_CLASSUPPERFILTERS 0x30F +#define IDS_PROP_CLASSLOWERFILTERS 0x310 +#define IDS_PROP_CLASSINSTALLER 0x311 +#define IDS_PROP_CLASSCOINSTALLER 0x312 +#define IDS_PROP_DEVICECOINSTALLER 0x313 +#define IDS_PROP_FIRMWAREREVISION 0x314 +#define IDS_PROP_CURRENTPOWERSTATE 0x315 +#define IDS_PROP_POWERCAPABILITIES 0x316 +#define IDS_PROP_POWERSTATEMAPPINGS 0x317
#endif /* __DEVMGR_RESOURCE_H */