Author: dgorbachev
Date: Thu May 28 23:13:59 2009
New Revision: 41188
URL:
http://svn.reactos.org/svn/reactos?rev=41188&view=rev
Log:
Show CDROM as CDROM in "Properties for Local Disk" dialog. Marcus Boillat, bug
#4552.
Modified:
trunk/reactos/dll/win32/shell32/drive.c
Modified: trunk/reactos/dll/win32/shell32/drive.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/drive.c?…
==============================================================================
--- trunk/reactos/dll/win32/shell32/drive.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/drive.c [iso-8859-1] Thu May 28 23:13:59 2009
@@ -327,7 +327,7 @@
FillRect(drawItem->hDC, &drawItem->rcItem, hBrush);
DeleteObject((HGDIOBJ)hBrush);
}
- }
+ }
else if (drawItem->CtlID == 14014)
{
hBrush = CreateSolidBrush(RGB(255, 0, 255));
@@ -435,9 +435,16 @@
Result = LargeIntegerSubtract(ConvertUlongToLargeInteger(100), Result);
swprintf(szResult, L"%02d%%", Result.QuadPart);
SendDlgItemMessageW(hwndDlg, 14004, WM_SETTEXT, (WPARAM)0, (LPARAM)szResult);
- if (LoadStringW(shell32_hInstance, IDS_DRIVE_FIXED, szBuffer, sizeof(szBuffer) /
sizeof(WCHAR)))
- SendDlgItemMessageW(hwndDlg, 14001, WM_SETTEXT, (WPARAM)0,
(LPARAM)szBuffer);
-
+ if (DriveType == DRIVE_FIXED)
+ {
+ if (LoadStringW(shell32_hInstance, IDS_DRIVE_FIXED, szBuffer,
sizeof(szBuffer) / sizeof(WCHAR)))
+ SendDlgItemMessageW(hwndDlg, 14001, WM_SETTEXT, (WPARAM)0,
(LPARAM)szBuffer);
+ }
+ else /* DriveType == DRIVE_CDROM) */
+ {
+ if (LoadStringW(shell32_hInstance, IDS_DRIVE_CDROM, szBuffer,
sizeof(szBuffer) / sizeof(WCHAR)))
+ SendDlgItemMessageW(hwndDlg, 14001, WM_SETTEXT, (WPARAM)0,
(LPARAM)szBuffer);
+ }
}
}
/* set drive description */