Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
0f3d8bf5
Commit
0f3d8bf5
authored
Jan 21, 2004
by
Martin Fuchs
Committed by
Alexandre Julliard
Jan 21, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use full paths instead of only filenames in icon cache to distinguish
between different files with the same name.
parent
74bcd4e4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
19 additions
and
5 deletions
+19
-5
folders.c
dlls/shell32/folders.c
+5
-1
iconcache.c
dlls/shell32/iconcache.c
+6
-4
shell32_main.c
dlls/shell32/shell32_main.c
+5
-0
shell32_main.h
dlls/shell32/shell32_main.h
+3
-0
No files found.
dlls/shell32/folders.c
View file @
0f3d8bf5
...
@@ -17,6 +17,9 @@
...
@@ -17,6 +17,9 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
*/
#include "config.h"
#include "wine/port.h"
#include <stdlib.h>
#include <stdlib.h>
#include <stdarg.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdio.h>
...
@@ -147,7 +150,8 @@ static ULONG WINAPI IExtractIconW_fnRelease(IExtractIconW * iface)
...
@@ -147,7 +150,8 @@ static ULONG WINAPI IExtractIconW_fnRelease(IExtractIconW * iface)
return
This
->
ref
;
return
This
->
ref
;
}
}
static
WCHAR
swShell32Name
[]
=
{
's'
,
'h'
,
'e'
,
'l'
,
'l'
,
'3'
,
'2'
,
'.'
,
'd'
,
'l'
,
'l'
,
0
};
WCHAR
swShell32Name
[
MAX_PATH
];
char
sShell32Name
[
MAX_PATH
];
/**************************************************************************
/**************************************************************************
* IExtractIconW_GetIconLocation
* IExtractIconW_GetIconLocation
...
...
dlls/shell32/iconcache.c
View file @
0f3d8bf5
...
@@ -97,12 +97,12 @@ static INT CALLBACK SIC_CompareEntries( LPVOID p1, LPVOID p2, LPARAM lparam)
...
@@ -97,12 +97,12 @@ static INT CALLBACK SIC_CompareEntries( LPVOID p1, LPVOID p2, LPARAM lparam)
static
INT
SIC_IconAppend
(
LPCSTR
sSourceFile
,
INT
dwSourceIndex
,
HICON
hSmallIcon
,
HICON
hBigIcon
)
static
INT
SIC_IconAppend
(
LPCSTR
sSourceFile
,
INT
dwSourceIndex
,
HICON
hSmallIcon
,
HICON
hBigIcon
)
{
LPSIC_ENTRY
lpsice
;
{
LPSIC_ENTRY
lpsice
;
INT
ret
,
index
,
index1
;
INT
ret
,
index
,
index1
;
char
*
path
;
char
path
[
MAX_PATH
]
;
TRACE
(
"%s %i %p %p
\n
"
,
sSourceFile
,
dwSourceIndex
,
hSmallIcon
,
hBigIcon
);
TRACE
(
"%s %i %p %p
\n
"
,
sSourceFile
,
dwSourceIndex
,
hSmallIcon
,
hBigIcon
);
lpsice
=
(
LPSIC_ENTRY
)
SHAlloc
(
sizeof
(
SIC_ENTRY
));
lpsice
=
(
LPSIC_ENTRY
)
SHAlloc
(
sizeof
(
SIC_ENTRY
));
path
=
PathFindFileNameA
(
sSourceFile
);
GetFullPathNameA
(
sSourceFile
,
MAX_PATH
,
path
,
NULL
);
lpsice
->
sSourceFile
=
HeapAlloc
(
GetProcessHeap
(),
0
,
strlen
(
path
)
+
1
);
lpsice
->
sSourceFile
=
HeapAlloc
(
GetProcessHeap
(),
0
,
strlen
(
path
)
+
1
);
strcpy
(
lpsice
->
sSourceFile
,
path
);
strcpy
(
lpsice
->
sSourceFile
,
path
);
...
@@ -167,10 +167,12 @@ static INT SIC_LoadIcon (LPCSTR sSourceFile, INT dwSourceIndex)
...
@@ -167,10 +167,12 @@ static INT SIC_LoadIcon (LPCSTR sSourceFile, INT dwSourceIndex)
INT
SIC_GetIconIndex
(
LPCSTR
sSourceFile
,
INT
dwSourceIndex
)
INT
SIC_GetIconIndex
(
LPCSTR
sSourceFile
,
INT
dwSourceIndex
)
{
SIC_ENTRY
sice
;
{
SIC_ENTRY
sice
;
INT
ret
,
index
=
INVALID_INDEX
;
INT
ret
,
index
=
INVALID_INDEX
;
char
path
[
MAX_PATH
];
TRACE
(
"%s %i
\n
"
,
sSourceFile
,
dwSourceIndex
);
TRACE
(
"%s %i
\n
"
,
sSourceFile
,
dwSourceIndex
);
sice
.
sSourceFile
=
PathFindFileNameA
(
sSourceFile
);
GetFullPathNameA
(
sSourceFile
,
MAX_PATH
,
path
,
NULL
);
sice
.
sSourceFile
=
path
;
sice
.
dwSourceIndex
=
dwSourceIndex
;
sice
.
dwSourceIndex
=
dwSourceIndex
;
EnterCriticalSection
(
&
SHELL32_SicCS
);
EnterCriticalSection
(
&
SHELL32_SicCS
);
...
@@ -257,7 +259,7 @@ BOOL SIC_Initialize(void)
...
@@ -257,7 +259,7 @@ BOOL SIC_Initialize(void)
hSm
=
LoadImageA
(
shell32_hInstance
,
MAKEINTRESOURCEA
(
0
),
IMAGE_ICON
,
16
,
16
,
LR_SHARED
);
hSm
=
LoadImageA
(
shell32_hInstance
,
MAKEINTRESOURCEA
(
0
),
IMAGE_ICON
,
16
,
16
,
LR_SHARED
);
hLg
=
LoadImageA
(
shell32_hInstance
,
MAKEINTRESOURCEA
(
0
),
IMAGE_ICON
,
32
,
32
,
LR_SHARED
);
hLg
=
LoadImageA
(
shell32_hInstance
,
MAKEINTRESOURCEA
(
0
),
IMAGE_ICON
,
32
,
32
,
LR_SHARED
);
}
}
SIC_IconAppend
(
"shell32.dll"
,
index
,
hSm
,
hLg
);
SIC_IconAppend
(
sShell32Name
,
index
,
hSm
,
hLg
);
}
}
TRACE
(
"hIconSmall=%p hIconBig=%p
\n
"
,
ShellSmallIconList
,
ShellBigIconList
);
TRACE
(
"hIconSmall=%p hIconBig=%p
\n
"
,
ShellSmallIconList
,
ShellBigIconList
);
...
...
dlls/shell32/shell32_main.c
View file @
0f3d8bf5
...
@@ -904,6 +904,11 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID fImpLoad)
...
@@ -904,6 +904,11 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID fImpLoad)
{
{
case
DLL_PROCESS_ATTACH
:
case
DLL_PROCESS_ATTACH
:
shell32_hInstance
=
hinstDLL
;
shell32_hInstance
=
hinstDLL
;
/* get full path to this DLL for IExtractIconW_fnGetIconLocation() */
GetModuleFileNameW
(
hinstDLL
,
swShell32Name
,
MAX_PATH
);
WideCharToMultiByte
(
CP_ACP
,
0
,
swShell32Name
,
-
1
,
sShell32Name
,
MAX_PATH
,
NULL
,
NULL
);
hComctl32
=
GetModuleHandleA
(
"COMCTL32.DLL"
);
hComctl32
=
GetModuleHandleA
(
"COMCTL32.DLL"
);
DisableThreadLibraryCalls
(
shell32_hInstance
);
DisableThreadLibraryCalls
(
shell32_hInstance
);
...
...
dlls/shell32/shell32_main.h
View file @
0f3d8bf5
...
@@ -236,4 +236,7 @@ inline static WCHAR * __SHCloneStrAtoW(WCHAR ** target, const char * source)
...
@@ -236,4 +236,7 @@ inline static WCHAR * __SHCloneStrAtoW(WCHAR ** target, const char * source)
typedef
UINT
(
*
SHELL_ExecuteW32
)(
WCHAR
*
lpCmd
,
void
*
env
,
LPSHELLEXECUTEINFOW
sei
,
BOOL
shWait
);
typedef
UINT
(
*
SHELL_ExecuteW32
)(
WCHAR
*
lpCmd
,
void
*
env
,
LPSHELLEXECUTEINFOW
sei
,
BOOL
shWait
);
BOOL
WINAPI
ShellExecuteExW32
(
LPSHELLEXECUTEINFOW
sei
,
SHELL_ExecuteW32
execfunc
);
BOOL
WINAPI
ShellExecuteExW32
(
LPSHELLEXECUTEINFOW
sei
,
SHELL_ExecuteW32
execfunc
);
extern
WCHAR
swShell32Name
[
MAX_PATH
];
extern
char
sShell32Name
[
MAX_PATH
];
#endif
#endif
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment