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
45d21d00
Commit
45d21d00
authored
Mar 11, 2021
by
Huw Davies
Committed by
Alexandre Julliard
Mar 11, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
riched20: Handle EM_REPLACESEL's unicode conversion in the host.
Signed-off-by:
Huw Davies
<
huw@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
9fa99302
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
7 deletions
+15
-7
editor.c
dlls/riched20/editor.c
+4
-7
txthost.c
dlls/riched20/txthost.c
+11
-0
No files found.
dlls/riched20/editor.c
View file @
45d21d00
...
...
@@ -3883,14 +3883,11 @@ LRESULT ME_HandleMessage(ME_TextEditor *editor, UINT msg, WPARAM wParam,
}
case
EM_REPLACESEL
:
{
int
len
=
0
;
LONG
codepage
=
unicode
?
CP_UNICODE
:
CP_ACP
;
LPWSTR
wszText
=
ME_ToUnicode
(
codepage
,
(
void
*
)
lParam
,
&
len
);
WCHAR
*
text
=
(
WCHAR
*
)
lParam
;
int
len
=
text
?
lstrlenW
(
text
)
:
0
;
TRACE
(
"EM_REPLACESEL - %s
\n
"
,
debugstr_w
(
wszText
));
ME_ReplaceSel
(
editor
,
!!
wParam
,
wszText
,
len
);
ME_EndToUnicode
(
codepage
,
wszText
);
TRACE
(
"EM_REPLACESEL - %s
\n
"
,
debugstr_w
(
text
)
);
ME_ReplaceSel
(
editor
,
!!
wParam
,
text
,
len
);
return
len
;
}
case
EM_SCROLLCARET
:
...
...
dlls/riched20/txthost.c
View file @
45d21d00
...
...
@@ -849,6 +849,17 @@ static LRESULT RichEditWndProc_common( HWND hwnd, UINT msg, WPARAM wparam,
EndPaint
(
editor
->
hWnd
,
&
ps
);
return
0
;
}
case
EM_REPLACESEL
:
{
int
len
;
LONG
codepage
=
unicode
?
CP_UNICODE
:
CP_ACP
;
WCHAR
*
text
=
ME_ToUnicode
(
codepage
,
(
void
*
)
lparam
,
&
len
);
hr
=
ITextServices_TxSendMessage
(
host
->
text_srv
,
msg
,
wparam
,
(
LPARAM
)
text
,
&
res
);
ME_EndToUnicode
(
codepage
,
text
);
res
=
len
;
break
;
}
case
EM_SETOPTIONS
:
{
DWORD
style
;
...
...
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