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
b5a04332
Commit
b5a04332
authored
Jul 21, 2005
by
Phil Krylov
Committed by
Alexandre Julliard
Jul 21, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow NULL parameter for WM_SETTEXT in RichEdit.
parent
b676b622
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
5 deletions
+14
-5
editor.c
dlls/riched20/editor.c
+14
-5
No files found.
dlls/riched20/editor.c
View file @
b5a04332
...
...
@@ -1180,12 +1180,21 @@ LRESULT WINAPI RichEditANSIWndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lP
}
case
WM_SETTEXT
:
{
LPWSTR
wszText
=
ME_ToUnicode
(
hWnd
,
(
void
*
)
lParam
);
TRACE
(
"WM_SETTEXT - %s
\n
"
,
(
char
*
)(
wszText
));
/* debugstr_w() */
ME_InternalDeleteText
(
editor
,
0
,
ME_GetTextLength
(
editor
));
/* uses default style! */
ME_InsertTextFromCursor
(
editor
,
0
,
wszText
,
-
1
,
editor
->
pBuffer
->
pDefaultStyle
);
ME_EndToUnicode
(
hWnd
,
wszText
);
if
(
lParam
)
{
LPWSTR
wszText
=
ME_ToUnicode
(
hWnd
,
(
void
*
)
lParam
);
TRACE
(
"WM_SETTEXT lParam==%lx
\n
"
,
lParam
);
TRACE
(
"WM_SETTEXT - %s
\n
"
,
debugstr_w
(
wszText
));
/* debugstr_w() */
if
(
lstrlenW
(
wszText
)
>
0
)
{
/* uses default style! */
ME_InsertTextFromCursor
(
editor
,
0
,
wszText
,
-
1
,
editor
->
pBuffer
->
pDefaultStyle
);
}
ME_EndToUnicode
(
hWnd
,
wszText
);
}
else
TRACE
(
"WM_SETTEXT - NULL
\n
"
);
ME_CommitUndo
(
editor
);
ME_EmptyUndoStack
(
editor
);
ME_UpdateRepaint
(
editor
);
...
...
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