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
ae7b2c91
Commit
ae7b2c91
authored
Dec 11, 2007
by
Alex Villacís Lasso
Committed by
Alexandre Julliard
Dec 12, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
riched32: Fix regression in WM_GETTEXTLENGTH on richedit 1.0 emulation.
parent
16cc1334
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
1 deletion
+25
-1
editor.c
dlls/riched20/editor.c
+1
-1
editor.c
dlls/riched32/tests/editor.c
+24
-0
No files found.
dlls/riched20/editor.c
View file @
ae7b2c91
...
...
@@ -1999,7 +1999,7 @@ static LRESULT RichEditWndProc_common(HWND hWnd, UINT msg, WPARAM wParam,
{
GETTEXTLENGTHEX
how
;
how
.
flags
=
GTL_CLOSE
|
GTL_USECRLF
|
GTL_NUMCHARS
;
how
.
flags
=
GTL_CLOSE
|
(
editor
->
bEmulateVersion10
?
0
:
GTL_USECRLF
)
|
GTL_NUMCHARS
;
how
.
codepage
=
unicode
?
1200
:
CP_ACP
;
return
ME_GetTextLengthEx
(
editor
,
&
how
);
}
...
...
dlls/riched32/tests/editor.c
View file @
ae7b2c91
...
...
@@ -108,6 +108,29 @@ static void test_WM_SETTEXT()
DestroyWindow
(
hwndRichEdit
);
}
static
void
test_WM_GETTEXTLENGTH
(
void
)
{
HWND
hwndRichEdit
=
new_richedit
(
NULL
);
static
const
char
text3
[]
=
"aaa
\r\n
bbb
\r\n
ccc
\r\n
ddd
\r\n
eee"
;
static
const
char
text4
[]
=
"aaa
\r\n
bbb
\r\n
ccc
\r\n
ddd
\r\n
eee
\r\n
"
;
int
result
;
/* Test for WM_GETTEXTLENGTH */
SendMessage
(
hwndRichEdit
,
WM_SETTEXT
,
0
,
(
LPARAM
)
text3
);
result
=
SendMessage
(
hwndRichEdit
,
WM_GETTEXTLENGTH
,
0
,
0
);
ok
(
result
==
strlen
(
text3
),
"WM_GETTEXTLENGTH reports incorrect length %d, expected %d
\n
"
,
result
,
strlen
(
text3
));
SendMessage
(
hwndRichEdit
,
WM_SETTEXT
,
0
,
(
LPARAM
)
text4
);
result
=
SendMessage
(
hwndRichEdit
,
WM_GETTEXTLENGTH
,
0
,
0
);
ok
(
result
==
strlen
(
text4
),
"WM_GETTEXTLENGTH reports incorrect length %d, expected %d
\n
"
,
result
,
strlen
(
text4
));
DestroyWindow
(
hwndRichEdit
);
}
START_TEST
(
editor
)
{
MSG
msg
;
...
...
@@ -119,6 +142,7 @@ START_TEST( editor )
ok
(
hmoduleRichEdit
!=
NULL
,
"error: %d
\n
"
,
(
int
)
GetLastError
());
test_WM_SETTEXT
();
test_WM_GETTEXTLENGTH
();
/* Set the environment variable WINETEST_RICHED32 to keep windows
* responsive and open for 30 seconds. This is useful for debugging.
...
...
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