Authors: Klemens Friedl <frik85@hotmail.com>, Martin Fuchs <martin-fuchs@gmx.net>

- drive icon artwork
- display different drive icons depending on the drive type
This commit is contained in:
Alexandre Julliard 2004-09-29 21:13:58 +00:00
parent 57cb25c008
commit 72c9008e73
4 changed files with 9072 additions and 169 deletions

View File

@ -1,11 +1,16 @@
Makefile
authors.c
cdrom.ico
desktop.ico
document.ico
drive.ico
floppy.ico
folder.ico
folder_open.ico
mycomputer.ico
netdrive.ico
netdrive2.ico
ramdisk.ico
shell.spec.c
shell32.dll.dbg.c
shell32.spec.def

View File

@ -51,12 +51,17 @@ C_SRCS = \
RC_SRCS = shres.rc version.rc
RC_BINSRC = shres.rc
RC_BINARIES = \
cdrom.ico \
desktop.ico \
document.ico \
drive.ico \
floppy.ico \
folder.ico \
folder_open.ico \
mycomputer.ico
mycomputer.ico \
netdrive.ico \
netdrive2.ico \
ramdisk.ico
C_SRCS16 = shell.c
RC_SRCS16 = version16.rc

View File

@ -263,14 +263,35 @@ static HRESULT WINAPI IExtractIconW_fnGetIconLocation(
{
static const WCHAR drive[] = { 'D','r','i','v','e',0 };
if (HCR_GetDefaultIconW(drive, szIconFile, cchMax, &dwNr))
int icon_idx = -1;
if (_ILGetDrive(pSimplePidl, sTemp, MAX_PATH))
{
*piIndex = dwNr;
switch(GetDriveTypeA(sTemp))
{
case DRIVE_REMOVABLE: icon_idx = 5; break;
case DRIVE_CDROM: icon_idx = 11; break;
case DRIVE_REMOTE: icon_idx = 9; break;
case DRIVE_RAMDISK: icon_idx = 12; break;
}
}
if (icon_idx != -1)
{
lstrcpynW(szIconFile, swShell32Name, cchMax);
*piIndex = icon_idx;
}
else
{
lstrcpynW(szIconFile, swShell32Name, cchMax);
*piIndex = 8;
if (HCR_GetDefaultIconW(drive, szIconFile, cchMax, &dwNr))
{
*piIndex = dwNr;
}
else
{
lstrcpynW(szIconFile, swShell32Name, cchMax);
*piIndex = 8;
}
}
}
else if (_ILIsFolder (pSimplePidl))

File diff suppressed because it is too large Load Diff