Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
64c456af
Commit
64c456af
authored
Dec 01, 2017
by
Zebediah Figura
Committed by
Alexandre Julliard
Dec 01, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shell32: Implement the DeleteItem() command for Progman DDE.
Signed-off-by:
Zebediah Figura
<
z.figura12@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
6e5efd00
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
4 deletions
+20
-4
dde.c
dlls/shell32/dde.c
+20
-0
progman_dde.c
dlls/shell32/tests/progman_dde.c
+0
-4
No files found.
dlls/shell32/dde.c
View file @
64c456af
...
...
@@ -126,6 +126,7 @@ static DWORD PROGMAN_OnExecute(WCHAR *command, int argc, WCHAR **argv)
static
const
WCHAR
delete_groupW
[]
=
{
'D'
,
'e'
,
'l'
,
'e'
,
't'
,
'e'
,
'G'
,
'r'
,
'o'
,
'u'
,
'p'
,
0
};
static
const
WCHAR
show_groupW
[]
=
{
'S'
,
'h'
,
'o'
,
'w'
,
'G'
,
'r'
,
'o'
,
'u'
,
'p'
,
0
};
static
const
WCHAR
add_itemW
[]
=
{
'A'
,
'd'
,
'd'
,
'I'
,
't'
,
'e'
,
'm'
,
0
};
static
const
WCHAR
delete_itemW
[]
=
{
'D'
,
'e'
,
'l'
,
'e'
,
't'
,
'e'
,
'I'
,
't'
,
'e'
,
'm'
,
0
};
static
const
WCHAR
dotexeW
[]
=
{
'.'
,
'e'
,
'x'
,
'e'
,
0
};
static
const
WCHAR
dotlnkW
[]
=
{
'.'
,
'l'
,
'n'
,
'k'
,
0
};
...
...
@@ -254,6 +255,25 @@ static DWORD PROGMAN_OnExecute(WCHAR *command, int argc, WCHAR **argv)
if
(
FAILED
(
hres
))
return
DDE_FNOTPROCESSED
;
}
else
if
(
!
strcmpiW
(
command
,
delete_itemW
))
{
WCHAR
*
name
;
BOOL
ret
;
if
(
argc
<
1
)
return
DDE_FNOTPROCESSED
;
name
=
HeapAlloc
(
GetProcessHeap
(),
0
,
(
strlenW
(
last_group
)
+
1
+
strlenW
(
argv
[
0
])
+
5
)
*
sizeof
(
*
name
));
lstrcpyW
(
name
,
last_group
);
lstrcatW
(
name
,
slashW
);
lstrcatW
(
name
,
argv
[
0
]);
lstrcatW
(
name
,
dotlnkW
);
ret
=
DeleteFileW
(
name
);
HeapFree
(
GetProcessHeap
(),
0
,
name
);
if
(
!
ret
)
return
DDE_FNOTPROCESSED
;
}
else
{
FIXME
(
"unhandled command %s
\n
"
,
debugstr_w
(
command
));
...
...
dlls/shell32/tests/progman_dde.c
View file @
64c456af
...
...
@@ -296,10 +296,8 @@ static void test_progman_dde(DWORD instance, HCONV hConv)
ok
(
check_exists
(
"Group1/f2g1Name.lnk"
),
"link not created
\n
"
);
error
=
dde_execute
(
instance
,
hConv
,
"[DeleteItem(f2g1Name)]"
);
todo_wine
{
ok
(
error
==
DMLERR_NO_ERROR
,
"expected DMLERR_NO_ERROR, got %u
\n
"
,
error
);
ok
(
!
check_exists
(
"Group1/f2g1Name.lnk"
),
"link should not exist
\n
"
);
}
sprintf
(
itemtext
,
"[AddItem(%s,f3g1Name)]"
,
f3g1
);
error
=
dde_execute
(
instance
,
hConv
,
itemtext
);
...
...
@@ -322,10 +320,8 @@ static void test_progman_dde(DWORD instance, HCONV hConv)
ok
(
error
==
DMLERR_NOTPROCESSED
,
"expected DMLERR_NOTPROCESSED, got %u
\n
"
,
error
);
error
=
dde_execute
(
instance
,
hConv
,
"[DeleteItem(f3g1Name)]"
);
todo_wine
{
ok
(
error
==
DMLERR_NO_ERROR
,
"expected DMLERR_NO_ERROR, got %u
\n
"
,
error
);
ok
(
!
check_exists
(
"Group1/f3g1Name.lnk"
),
"link should not exist
\n
"
);
}
error
=
dde_execute
(
instance
,
hConv
,
"[ShowGroup(Startup, 0)]"
);
ok
(
error
==
DMLERR_NO_ERROR
,
"expected DMLERR_NO_ERROR, got %u
\n
"
,
error
);
...
...
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