Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Sebastian Mayr
wine
Commits
a94bc4c0
Commit
a94bc4c0
authored
18 years ago
by
Huw Davies
Committed by
Alexandre Julliard
18 years ago
Browse files
Options
Downloads
Patches
Plain Diff
oledlg: Forward OleUIPasteSpecialA -> OleUIPasteSpecialW.
parent
f08c5c2c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
dlls/oledlg/pastespl.c
+64
-4
64 additions, 4 deletions
dlls/oledlg/pastespl.c
with
64 additions
and
4 deletions
dlls/oledlg/pastespl.c
+
64
−
4
View file @
a94bc4c0
...
...
@@ -26,6 +26,7 @@
#include
"winerror.h"
#include
"wingdi.h"
#include
"winuser.h"
#include
"winnls.h"
#include
"oledlg.h"
#include
"wine/debug.h"
...
...
@@ -95,14 +96,73 @@ static void dump_pastespecial(LPOLEUIPASTESPECIALW ps)
}
static
inline
WCHAR
*
strdupAtoW
(
const
char
*
str
)
{
DWORD
len
;
WCHAR
*
ret
;
if
(
!
str
)
return
NULL
;
len
=
MultiByteToWideChar
(
CP_ACP
,
0
,
str
,
-
1
,
NULL
,
0
);
ret
=
HeapAlloc
(
GetProcessHeap
(),
0
,
len
*
sizeof
(
WCHAR
));
MultiByteToWideChar
(
CP_ACP
,
0
,
str
,
-
1
,
ret
,
len
);
return
ret
;
}
/***********************************************************************
* OleUIPasteSpecialA (OLEDLG.4)
*/
UINT
WINAPI
OleUIPasteSpecialA
(
LPOLEUIPASTESPECIALA
lpOleUIPasteSpecial
)
UINT
WINAPI
OleUIPasteSpecialA
(
LPOLEUIPASTESPECIALA
psA
)
{
FIXME
(
"(%p): stub
\n
"
,
lpOleUIPasteSpecial
);
SetLastError
(
ERROR_CALL_NOT_IMPLEMENTED
);
return
OLEUI_FALSE
;
OLEUIPASTESPECIALW
ps
;
UINT
ret
;
TRACE
(
"(%p)
\n
"
,
psA
);
memcpy
(
&
ps
,
psA
,
psA
->
cbStruct
);
ps
.
lpszCaption
=
strdupAtoW
(
psA
->
lpszCaption
);
if
(
!
IS_INTRESOURCE
(
ps
.
lpszTemplate
))
ps
.
lpszTemplate
=
strdupAtoW
(
psA
->
lpszTemplate
);
if
(
psA
->
cPasteEntries
>
0
)
{
DWORD
size
=
psA
->
cPasteEntries
*
sizeof
(
ps
.
arrPasteEntries
[
0
]);
UINT
i
;
ps
.
arrPasteEntries
=
HeapAlloc
(
GetProcessHeap
(),
0
,
size
);
memcpy
(
ps
.
arrPasteEntries
,
psA
->
arrPasteEntries
,
size
);
for
(
i
=
0
;
i
<
psA
->
cPasteEntries
;
i
++
)
{
ps
.
arrPasteEntries
[
i
].
lpstrFormatName
=
strdupAtoW
(
psA
->
arrPasteEntries
[
i
].
lpstrFormatName
);
ps
.
arrPasteEntries
[
i
].
lpstrResultText
=
strdupAtoW
(
psA
->
arrPasteEntries
[
i
].
lpstrResultText
);
}
}
ret
=
OleUIPasteSpecialW
(
&
ps
);
if
(
psA
->
cPasteEntries
>
0
)
{
UINT
i
;
for
(
i
=
0
;
i
<
psA
->
cPasteEntries
;
i
++
)
{
HeapFree
(
GetProcessHeap
(),
0
,
(
WCHAR
*
)
ps
.
arrPasteEntries
[
i
].
lpstrFormatName
);
HeapFree
(
GetProcessHeap
(),
0
,
(
WCHAR
*
)
ps
.
arrPasteEntries
[
i
].
lpstrResultText
);
}
HeapFree
(
GetProcessHeap
(),
0
,
ps
.
arrPasteEntries
);
}
if
(
!
IS_INTRESOURCE
(
ps
.
lpszTemplate
))
HeapFree
(
GetProcessHeap
(),
0
,
(
WCHAR
*
)
ps
.
lpszTemplate
);
HeapFree
(
GetProcessHeap
(),
0
,
(
WCHAR
*
)
ps
.
lpszCaption
);
/* Copy back the output fields */
psA
->
dwFlags
=
ps
.
dwFlags
;
psA
->
lpSrcDataObj
=
ps
.
lpSrcDataObj
;
psA
->
nSelectedIndex
=
ps
.
nSelectedIndex
;
psA
->
fLink
=
ps
.
fLink
;
psA
->
hMetaPict
=
ps
.
hMetaPict
;
psA
->
sizel
=
ps
.
sizel
;
return
ret
;
}
/***********************************************************************
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment