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
52b732dd
Commit
52b732dd
authored
May 19, 2003
by
Ulrich Czekalla
Committed by
Alexandre Julliard
May 19, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Handle SEE_MASK_CLASSKEY case for ShellExecute.
parent
3e53d11e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
36 additions
and
4 deletions
+36
-4
classes.c
dlls/shell32/classes.c
+25
-0
shell32_main.h
dlls/shell32/shell32_main.h
+1
-0
shlexec.c
dlls/shell32/shlexec.c
+10
-4
No files found.
dlls/shell32/classes.c
View file @
52b732dd
...
...
@@ -144,6 +144,31 @@ BOOL HCR_GetExecuteCommandA(LPCSTR szClass, LPCSTR szVerb, LPSTR szDest, DWORD l
return
FALSE
;
}
BOOL
HCR_GetExecuteCommandEx
(
HKEY
hkeyClass
,
LPCSTR
szClass
,
LPCSTR
szVerb
,
LPSTR
szDest
,
DWORD
len
)
{
BOOL
ret
=
FALSE
;
TRACE
(
"%p %s %s
\n
"
,
hkeyClass
,
szClass
,
szVerb
);
if
(
szClass
)
RegOpenKeyExA
(
hkeyClass
,
szClass
,
0
,
0x02000000
,
&
hkeyClass
);
if
(
hkeyClass
)
{
char
sTemp
[
MAX_PATH
];
snprintf
(
sTemp
,
MAX_PATH
,
"shell
\\
%s
\\
command"
,
szVerb
);
ret
=
(
ERROR_SUCCESS
==
SHGetValueA
(
hkeyClass
,
sTemp
,
NULL
,
NULL
,
szDest
,
&
len
));
if
(
szClass
)
RegCloseKey
(
hkeyClass
);
}
TRACE
(
"-- %s
\n
"
,
szDest
);
return
ret
;
}
/***************************************************************************************
* HCR_GetDefaultIcon [internal]
*
...
...
dlls/shell32/shell32_main.h
View file @
52b732dd
...
...
@@ -68,6 +68,7 @@ BOOL HCR_GetExecuteCommandA(LPCSTR szClass, LPCSTR szVerb, LPSTR szDest, DWORD l
BOOL
HCR_GetDefaultIconA
(
LPCSTR
szClass
,
LPSTR
szDest
,
DWORD
len
,
LPDWORD
dwNr
);
BOOL
HCR_GetClassNameA
(
REFIID
riid
,
LPSTR
szDest
,
DWORD
len
);
BOOL
HCR_GetExecuteCommandEx
(
HKEY
hkeyClass
,
LPCSTR
szClass
,
LPCSTR
szVerb
,
LPSTR
szDest
,
DWORD
len
);
BOOL
HCR_GetFolderAttributes
(
REFIID
riid
,
LPDWORD
szDest
);
INT_PTR
CALLBACK
AboutDlgProc
(
HWND
,
UINT
,
WPARAM
,
LPARAM
);
...
...
dlls/shell32/shlexec.c
View file @
52b732dd
...
...
@@ -582,8 +582,7 @@ BOOL WINAPI ShellExecuteExA32 (LPSHELLEXECUTEINFOA sei, SHELL_ExecuteA1632 execf
if
(
sei
->
lpParameters
)
strcpy
(
szCommandline
,
sei
->
lpParameters
);
if
(
sei
->
fMask
&
((
SEE_MASK_CLASSKEY
&
~
SEE_MASK_CLASSNAME
)
|
SEE_MASK_INVOKEIDLIST
|
SEE_MASK_ICON
|
SEE_MASK_HOTKEY
|
if
(
sei
->
fMask
&
(
SEE_MASK_INVOKEIDLIST
|
SEE_MASK_ICON
|
SEE_MASK_HOTKEY
|
SEE_MASK_CONNECTNETDRV
|
SEE_MASK_FLAG_DDEWAIT
|
SEE_MASK_DOENVSUBST
|
SEE_MASK_FLAG_NO_UI
|
SEE_MASK_UNICODE
|
SEE_MASK_NO_CONSOLE
|
SEE_MASK_ASYNCOK
|
SEE_MASK_HMONITOR
))
...
...
@@ -618,12 +617,19 @@ BOOL WINAPI ShellExecuteExA32 (LPSHELLEXECUTEINFOA sei, SHELL_ExecuteA1632 execf
}
}
if
(
sei
->
fMask
&
SEE_MASK_CLASSNAME
)
if
(
sei
->
fMask
&
(
SEE_MASK_CLASSNAME
|
SEE_MASK_CLASSKEY
)
)
{
/* launch a document by fileclass like 'WordPad.Document.1' */
/* the Commandline contains 'c:\Path\wordpad.exe "%1"' */
/* FIXME: szCommandline should not be of a fixed size. Plus MAX_PATH is way too short! */
HCR_GetExecuteCommandA
(
sei
->
lpClass
,
(
sei
->
lpVerb
)
?
sei
->
lpVerb
:
"open"
,
szCommandline
,
sizeof
(
szCommandline
));
if
(
sei
->
fMask
&
SEE_MASK_CLASSKEY
)
HCR_GetExecuteCommandEx
(
sei
->
hkeyClass
,
(
sei
->
fMask
&
SEE_MASK_CLASSNAME
)
?
sei
->
lpClass
:
NULL
,
(
sei
->
lpVerb
)
?
sei
->
lpVerb
:
"open"
,
szCommandline
,
sizeof
(
szCommandline
));
else
if
(
sei
->
fMask
&
SEE_MASK_CLASSNAME
)
HCR_GetExecuteCommandA
(
sei
->
lpClass
,
(
sei
->
lpVerb
)
?
sei
->
lpVerb
:
"open"
,
szCommandline
,
sizeof
(
szCommandline
));
/* FIXME: get the extension of lpFile, check if it fits to the lpClass */
TRACE
(
"SEE_MASK_CLASSNAME->'%s', doc->'%s'
\n
"
,
szCommandline
,
szApplicationName
);
...
...
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