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
71ecb556
Commit
71ecb556
authored
Oct 27, 2013
by
Nikolay Sivov
Committed by
Alexandre Julliard
Oct 28, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wshom.ocx: Implement IWshShell3::ExpandEnvironmentStrings().
parent
f3c805be
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
29 additions
and
3 deletions
+29
-3
shell.c
dlls/wshom.ocx/shell.c
+19
-3
wshom.c
dlls/wshom.ocx/tests/wshom.c
+10
-0
No files found.
dlls/wshom.ocx/shell.c
View file @
71ecb556
...
...
@@ -745,10 +745,26 @@ static HRESULT WINAPI WshShell3_CreateShortcut(IWshShell3 *iface, BSTR PathLink,
return
WshShortcut_Create
(
PathLink
,
Shortcut
);
}
static
HRESULT
WINAPI
WshShell3_ExpandEnvironmentStrings
(
IWshShell3
*
iface
,
BSTR
Src
,
BSTR
*
out_
Dst
)
static
HRESULT
WINAPI
WshShell3_ExpandEnvironmentStrings
(
IWshShell3
*
iface
,
BSTR
Src
,
BSTR
*
Dst
)
{
FIXME
(
"(%s %p): stub
\n
"
,
debugstr_w
(
Src
),
out_Dst
);
return
E_NOTIMPL
;
DWORD
ret
;
TRACE
(
"(%s %p)
\n
"
,
debugstr_w
(
Src
),
Dst
);
if
(
!
Src
||
!
Dst
)
return
E_POINTER
;
ret
=
ExpandEnvironmentStringsW
(
Src
,
NULL
,
0
);
*
Dst
=
SysAllocStringLen
(
NULL
,
ret
);
if
(
!*
Dst
)
return
E_OUTOFMEMORY
;
if
(
ExpandEnvironmentStringsW
(
Src
,
*
Dst
,
ret
))
return
S_OK
;
else
{
SysFreeString
(
*
Dst
);
*
Dst
=
NULL
;
return
HRESULT_FROM_WIN32
(
GetLastError
());
}
}
static
HRESULT
WINAPI
WshShell3_RegRead
(
IWshShell3
*
iface
,
BSTR
Name
,
VARIANT
*
out_Value
)
...
...
dlls/wshom.ocx/tests/wshom.c
View file @
71ecb556
...
...
@@ -35,6 +35,7 @@ static void test_wshshell(void)
{
static
const
WCHAR
desktopW
[]
=
{
'D'
,
'e'
,
's'
,
'k'
,
't'
,
'o'
,
'p'
,
0
};
static
const
WCHAR
lnk1W
[]
=
{
'f'
,
'i'
,
'l'
,
'e'
,
'.'
,
'l'
,
'n'
,
'k'
,
0
};
static
const
WCHAR
pathW
[]
=
{
'%'
,
'P'
,
'A'
,
'T'
,
'H'
,
'%'
,
0
};
IWshShell3
*
sh3
;
IDispatchEx
*
dispex
;
IWshCollection
*
coll
;
...
...
@@ -113,6 +114,15 @@ static void test_wshshell(void)
IUnknown_Release
(
unk
);
IDispatch_Release
(
shortcut
);
/* ExpandEnvironmentStrings */
hr
=
IWshShell3_ExpandEnvironmentStrings
(
sh3
,
NULL
,
NULL
);
ok
(
hr
==
E_POINTER
,
"got 0x%08x
\n
"
,
hr
);
str
=
SysAllocString
(
pathW
);
hr
=
IWshShell3_ExpandEnvironmentStrings
(
sh3
,
str
,
NULL
);
ok
(
hr
==
E_POINTER
,
"got 0x%08x
\n
"
,
hr
);
SysFreeString
(
str
);
IWshCollection_Release
(
coll
);
IDispatch_Release
(
disp
);
IWshShell3_Release
(
sh3
);
...
...
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