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
80d9017e
Commit
80d9017e
authored
Jan 20, 2012
by
André Hentschel
Committed by
Alexandre Julliard
Jan 23, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comctl32: Test and fix WM_GETTEXTLENGTH for statusbars.
parent
861d4758
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
6 deletions
+14
-6
status.c
dlls/comctl32/status.c
+1
-1
status.c
dlls/comctl32/tests/status.c
+13
-5
No files found.
dlls/comctl32/status.c
View file @
80d9017e
...
...
@@ -1284,7 +1284,7 @@ StatusWindowProc (HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
return
STATUSBAR_WMGetText
(
infoPtr
,
(
INT
)
wParam
,
(
LPWSTR
)
lParam
);
case
WM_GETTEXTLENGTH
:
return
STATUSBAR_GetTextLength
(
infoPtr
,
0
);
return
LOWORD
(
STATUSBAR_GetTextLength
(
infoPtr
,
0
)
);
case
WM_LBUTTONDBLCLK
:
return
STATUSBAR_SendMouseNotify
(
infoPtr
,
NM_DBLCLK
,
msg
,
wParam
,
lParam
);
...
...
dlls/comctl32/tests/status.c
View file @
80d9017e
...
...
@@ -267,11 +267,11 @@ static void test_status_control(void)
/* Divide into parts and set text */
r
=
SendMessage
(
hWndStatus
,
SB_SETPARTS
,
3
,
(
LPARAM
)
nParts
);
expect
(
TRUE
,
r
);
r
=
SendMessage
(
hWndStatus
,
SB_SETTEXT
,
0
,
(
LPARAM
)
"First"
);
r
=
SendMessage
(
hWndStatus
,
SB_SETTEXT
,
SBT_POPOUT
|
0
,
(
LPARAM
)
"First"
);
expect
(
TRUE
,
r
);
r
=
SendMessage
(
hWndStatus
,
SB_SETTEXT
,
1
,
(
LPARAM
)
"Second"
);
r
=
SendMessage
(
hWndStatus
,
SB_SETTEXT
,
SBT_OWNERDRAW
|
1
,
(
LPARAM
)
"Second"
);
expect
(
TRUE
,
r
);
r
=
SendMessage
(
hWndStatus
,
SB_SETTEXT
,
2
,
(
LPARAM
)
"Third"
);
r
=
SendMessage
(
hWndStatus
,
SB_SETTEXT
,
SBT_NOBORDERS
|
2
,
(
LPARAM
)
"Third"
);
expect
(
TRUE
,
r
);
/* Get RECT Information */
...
...
@@ -287,13 +287,21 @@ static void test_status_control(void)
r
=
SendMessage
(
hWndStatus
,
SB_GETRECT
,
3
,
(
LPARAM
)
&
rc
);
expect
(
FALSE
,
r
);
/* Get text length and text */
r
=
SendMessage
(
hWndStatus
,
SB_GETTEXTLENGTH
,
0
,
0
);
expect
(
5
,
LOWORD
(
r
));
expect
(
SBT_POPOUT
,
HIWORD
(
r
));
r
=
SendMessageW
(
hWndStatus
,
WM_GETTEXTLENGTH
,
0
,
0
);
ok
(
r
==
5
||
broken
(
0x02000005
/* NT4 */
),
"Expected 5, got %d
\n
"
,
r
);
r
=
SendMessage
(
hWndStatus
,
SB_GETTEXTLENGTH
,
1
,
0
);
expect
(
0
,
LOWORD
(
r
));
expect
(
SBT_OWNERDRAW
,
HIWORD
(
r
));
r
=
SendMessage
(
hWndStatus
,
SB_GETTEXTLENGTH
,
2
,
0
);
expect
(
5
,
LOWORD
(
r
));
expect
(
0
,
HIWORD
(
r
));
expect
(
SBT_NOBORDERS
,
HIWORD
(
r
));
r
=
SendMessage
(
hWndStatus
,
SB_GETTEXT
,
2
,
(
LPARAM
)
charArray
);
ok
(
strcmp
(
charArray
,
"Third"
)
==
0
,
"Expected Third, got %s
\n
"
,
charArray
);
expect
(
5
,
LOWORD
(
r
));
expect
(
0
,
HIWORD
(
r
));
expect
(
SBT_NOBORDERS
,
HIWORD
(
r
));
/* Get parts and borders */
r
=
SendMessage
(
hWndStatus
,
SB_GETPARTS
,
3
,
(
LPARAM
)
checkParts
);
...
...
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