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
6055d04f
Commit
6055d04f
authored
May 24, 2007
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
May 24, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comctl32/tests: Fix some problems revealed by compilation in 64-bit mode.
parent
2d830632
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
45 additions
and
52 deletions
+45
-52
datetime.c
dlls/comctl32/tests/datetime.c
+4
-4
header.c
dlls/comctl32/tests/header.c
+4
-4
listview.c
dlls/comctl32/tests/listview.c
+14
-14
monthcal.c
dlls/comctl32/tests/monthcal.c
+4
-4
tab.c
dlls/comctl32/tests/tab.c
+3
-3
trackbar.c
dlls/comctl32/tests/trackbar.c
+3
-3
treeview.c
dlls/comctl32/tests/treeview.c
+5
-12
updown.c
dlls/comctl32/tests/updown.c
+8
-8
No files found.
dlls/comctl32/tests/datetime.c
View file @
6055d04f
...
...
@@ -137,7 +137,7 @@ struct subclass_info
static
LRESULT
WINAPI
datetime_subclass_proc
(
HWND
hwnd
,
UINT
message
,
WPARAM
wParam
,
LPARAM
lParam
)
{
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
A
(
hwnd
,
GWL
_USERDATA
);
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
PtrA
(
hwnd
,
GWLP
_USERDATA
);
static
long
defwndproc_counter
=
0
;
LRESULT
ret
;
struct
message
msg
;
...
...
@@ -182,9 +182,9 @@ static HWND create_datetime_control(DWORD style, DWORD exstyle)
return
NULL
;
}
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
A
(
hWndDateTime
,
GWL
_WNDPROC
,
(
LONG
)
datetime_subclass_proc
);
SetWindowLong
A
(
hWndDateTime
,
GWL_USERDATA
,
(
LONG
)
info
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
PtrA
(
hWndDateTime
,
GWLP
_WNDPROC
,
(
LONG
_PTR
)
datetime_subclass_proc
);
SetWindowLong
PtrA
(
hWndDateTime
,
GWLP_USERDATA
,
(
LONG_PTR
)
info
);
return
hWndDateTime
;
}
...
...
dlls/comctl32/tests/header.c
View file @
6055d04f
...
...
@@ -402,7 +402,7 @@ struct subclass_info
static
LRESULT
WINAPI
header_subclass_proc
(
HWND
hwnd
,
UINT
message
,
WPARAM
wParam
,
LPARAM
lParam
)
{
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
A
(
hwnd
,
GWL
_USERDATA
);
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
PtrA
(
hwnd
,
GWLP
_USERDATA
);
static
long
defwndproc_counter
=
0
;
LRESULT
ret
;
struct
message
msg
;
...
...
@@ -533,9 +533,9 @@ static HWND create_custom_header_control(HWND hParent, BOOL preloadHeaderItems)
SetWindowPos
(
childHandle
,
winpos
.
hwndInsertAfter
,
winpos
.
x
,
winpos
.
y
,
winpos
.
cx
,
winpos
.
cy
,
0
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
A
(
childHandle
,
GWL
_WNDPROC
,
(
LONG
)
header_subclass_proc
);
SetWindowLong
A
(
childHandle
,
GWL_USERDATA
,
(
LONG
)
info
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
PtrA
(
childHandle
,
GWLP
_WNDPROC
,
(
LONG_PTR
)
header_subclass_proc
);
SetWindowLong
PtrA
(
childHandle
,
GWLP_USERDATA
,
(
LONG_PTR
)
info
);
return
childHandle
;
}
...
...
dlls/comctl32/tests/listview.c
View file @
6055d04f
...
...
@@ -212,7 +212,7 @@ static HWND create_parent_window(void)
static
LRESULT
WINAPI
listview_subclass_proc
(
HWND
hwnd
,
UINT
message
,
WPARAM
wParam
,
LPARAM
lParam
)
{
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
A
(
hwnd
,
GWL
_USERDATA
);
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
PtrA
(
hwnd
,
GWLP
_USERDATA
);
static
long
defwndproc_counter
=
0
;
LRESULT
ret
;
struct
message
msg
;
...
...
@@ -256,9 +256,9 @@ static HWND create_listview_control(void)
return
NULL
;
}
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
A
(
hwnd
,
GWL
_WNDPROC
,
(
LONG
)
listview_subclass_proc
);
SetWindowLong
A
(
hwnd
,
GWL_USERDATA
,
(
LONG
)
info
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
PtrA
(
hwnd
,
GWLP
_WNDPROC
,
(
LONG
_PTR
)
listview_subclass_proc
);
SetWindowLong
PtrA
(
hwnd
,
GWLP_USERDATA
,
(
LONG_PTR
)
info
);
return
hwnd
;
}
...
...
@@ -286,16 +286,16 @@ static HWND create_custom_listview_control(DWORD style)
return
NULL
;
}
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
A
(
hwnd
,
GWL
_WNDPROC
,
(
LONG
)
listview_subclass_proc
);
SetWindowLong
A
(
hwnd
,
GWL_USERDATA
,
(
LONG
)
info
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
PtrA
(
hwnd
,
GWLP
_WNDPROC
,
(
LONG
_PTR
)
listview_subclass_proc
);
SetWindowLong
PtrA
(
hwnd
,
GWLP_USERDATA
,
(
LONG_PTR
)
info
);
return
hwnd
;
}
static
LRESULT
WINAPI
header_subclass_proc
(
HWND
hwnd
,
UINT
message
,
WPARAM
wParam
,
LPARAM
lParam
)
{
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
A
(
hwnd
,
GWL
_USERDATA
);
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
PtrA
(
hwnd
,
GWLP
_USERDATA
);
static
long
defwndproc_counter
=
0
;
LRESULT
ret
;
struct
message
msg
;
...
...
@@ -326,9 +326,9 @@ static HWND subclass_header(HWND hwndListview)
return
NULL
;
hwnd
=
ListView_GetHeader
(
hwndListview
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
A
(
hwnd
,
GWL
_WNDPROC
,
(
LONG
)
header_subclass_proc
);
SetWindowLong
A
(
hwnd
,
GWL_USERDATA
,
(
LONG
)
info
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
PtrA
(
hwnd
,
GWLP
_WNDPROC
,
(
LONG
_PTR
)
header_subclass_proc
);
SetWindowLong
PtrA
(
hwnd
,
GWLP_USERDATA
,
(
LONG_PTR
)
info
);
return
hwnd
;
}
...
...
@@ -773,13 +773,13 @@ static void test_customdraw(void)
insert_column
(
hwnd
,
1
);
insert_item
(
hwnd
,
0
);
oldwndproc
=
(
WNDPROC
)
SetWindowLongPtr
(
hwndparent
,
GWL_WNDPROC
,
(
INT
_PTR
)
cd_wndproc
);
oldwndproc
=
(
WNDPROC
)
SetWindowLongPtr
(
hwndparent
,
GWL
P
_WNDPROC
,
(
LONG
_PTR
)
cd_wndproc
);
InvalidateRect
(
hwnd
,
NULL
,
TRUE
);
UpdateWindow
(
hwnd
);
SetWindowLongPtr
(
hwndparent
,
GWL
_WNDPROC
,
(
INT
_PTR
)
oldwndproc
);
SetWindowLongPtr
(
hwndparent
,
GWL
P_WNDPROC
,
(
LONG
_PTR
)
oldwndproc
);
DestroyWindow
(
hwnd
);
}
...
...
dlls/comctl32/tests/monthcal.c
View file @
6055d04f
...
...
@@ -441,7 +441,7 @@ static HWND create_parent_window(void)
static
LRESULT
WINAPI
monthcal_subclass_proc
(
HWND
hwnd
,
UINT
message
,
WPARAM
wParam
,
LPARAM
lParam
)
{
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
A
(
hwnd
,
GWL
_USERDATA
);
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
PtrA
(
hwnd
,
GWLP
_USERDATA
);
static
long
defwndproc_counter
=
0
;
LRESULT
ret
;
struct
message
msg
;
...
...
@@ -487,9 +487,9 @@ static HWND create_monthcal_control(DWORD style, HWND parent_window)
return
NULL
;
}
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
A
(
hwnd
,
GWL
_WNDPROC
,
(
LONG
)
monthcal_subclass_proc
);
SetWindowLong
A
(
hwnd
,
GWL_USERDATA
,
(
LONG
)
info
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
PtrA
(
hwnd
,
GWLP
_WNDPROC
,
(
LONG
_PTR
)
monthcal_subclass_proc
);
SetWindowLong
PtrA
(
hwnd
,
GWLP_USERDATA
,
(
LONG_PTR
)
info
);
return
hwnd
;
}
...
...
dlls/comctl32/tests/tab.c
View file @
6055d04f
...
...
@@ -343,7 +343,7 @@ struct subclass_info
static
LRESULT
WINAPI
tabSubclassProcess
(
HWND
hwnd
,
UINT
message
,
WPARAM
wParam
,
LPARAM
lParam
)
{
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
A
(
hwnd
,
GWL
_USERDATA
);
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
PtrA
(
hwnd
,
GWLP
_USERDATA
);
static
long
defwndproc_counter
=
0
;
LRESULT
ret
;
struct
message
msg
;
...
...
@@ -397,8 +397,8 @@ static HWND createFilledTabControl(HWND parent_wnd, DWORD style, DWORD mask, INT
assert
(
tabHandle
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
A
(
tabHandle
,
GWL_WNDPROC
,
(
LONG
)
tabSubclassProcess
);
SetWindowLong
A
(
tabHandle
,
GWL_USERDATA
,
(
LONG
)
info
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
PtrA
(
tabHandle
,
GWLP_WNDPROC
,
(
LONG_PTR
)
tabSubclassProcess
);
SetWindowLong
PtrA
(
tabHandle
,
GWLP_USERDATA
,
(
LONG_PTR
)
info
);
tcNewTab
.
mask
=
mask
;
...
...
dlls/comctl32/tests/trackbar.c
View file @
6055d04f
...
...
@@ -445,7 +445,7 @@ static HWND create_parent_window(void){
}
static
LRESULT
WINAPI
trackbar_subclass_proc
(
HWND
hwnd
,
UINT
message
,
WPARAM
wParam
,
LPARAM
lParam
){
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
A
(
hwnd
,
GWL
_USERDATA
);
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
PtrA
(
hwnd
,
GWLP
_USERDATA
);
static
long
defwndproc_counter
=
0
;
LRESULT
ret
;
struct
message
msg
;
...
...
@@ -485,9 +485,9 @@ static HWND create_trackbar(DWORD style, HWND parent){
return
NULL
;
}
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
A
(
hWndTrack
,
GWL_WNDPROC
,
(
LONG
)
trackbar_subclass_proc
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
PtrA
(
hWndTrack
,
GWLP_WNDPROC
,
(
LONG_PTR
)
trackbar_subclass_proc
);
SetWindowLong
A
(
hWndTrack
,
GWL_USERDATA
,
(
LONG
)
info
);
SetWindowLong
PtrA
(
hWndTrack
,
GWLP_USERDATA
,
(
LONG_PTR
)
info
);
return
hWndTrack
;
}
...
...
dlls/comctl32/tests/treeview.c
View file @
6055d04f
...
...
@@ -574,7 +574,7 @@ static LRESULT WINAPI TreeviewWndProc(HWND hwnd, UINT message, WPARAM wParam, LP
static
long
defwndproc_counter
=
0
;
LRESULT
ret
;
struct
message
msg
;
WNDPROC
*
lpOldProc
=
(
WNDPROC
*
)
GetWindowLongA
(
hwnd
,
GWL
_USERDATA
);
WNDPROC
lpOldProc
=
(
WNDPROC
)
GetWindowLongPtrA
(
hwnd
,
GWLP
_USERDATA
);
msg
.
message
=
message
;
msg
.
flags
=
sent
|
wparam
|
lparam
;
...
...
@@ -584,7 +584,7 @@ static LRESULT WINAPI TreeviewWndProc(HWND hwnd, UINT message, WPARAM wParam, LP
add_message
(
MsgSequences
,
LISTVIEW_SEQ_INDEX
,
&
msg
);
defwndproc_counter
++
;
ret
=
CallWindowProcA
(
*
lpOldProc
,
hwnd
,
message
,
wParam
,
lParam
);
ret
=
CallWindowProcA
(
lpOldProc
,
hwnd
,
message
,
wParam
,
lParam
);
defwndproc_counter
--
;
return
ret
;
...
...
@@ -592,7 +592,7 @@ static LRESULT WINAPI TreeviewWndProc(HWND hwnd, UINT message, WPARAM wParam, LP
static
LRESULT
CALLBACK
MyWndProc
(
HWND
hWnd
,
UINT
msg
,
WPARAM
wParam
,
LPARAM
lParam
)
{
WNDPROC
*
pOldWndProc
;
WNDPROC
pOldWndProc
;
switch
(
msg
)
{
...
...
@@ -604,16 +604,9 @@ static LRESULT CALLBACK MyWndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lPa
SetFocus
(
hTree
);
pOldWndProc
=
HeapAlloc
(
GetProcessHeap
(),
0
,
sizeof
(
WNDPROC
));
if
(
!
ok
(
pOldWndProc
!=
NULL
,
"Failed to allocate memory for subclass_info.
\n
"
)
)
{
PostQuitMessage
(
1
);
break
;
}
/* Record the old WNDPROC so we can call it after recording the messages */
*
pOldWndProc
=
(
WNDPROC
)
SetWindowLongA
(
hTree
,
GWL_WNDPROC
,
(
LONG
)
TreeviewWndProc
);
SetWindowLong
A
(
hTree
,
GWL_USERDATA
,
(
LONG
)
pOldWndProc
);
pOldWndProc
=
(
WNDPROC
)
SetWindowLongPtrA
(
hTree
,
GWLP_WNDPROC
,
(
LONG_PTR
)
TreeviewWndProc
);
SetWindowLong
PtrA
(
hTree
,
GWLP_USERDATA
,
(
LONG_PTR
)
pOldWndProc
);
return
0
;
}
...
...
dlls/comctl32/tests/updown.c
View file @
6055d04f
...
...
@@ -259,7 +259,7 @@ struct subclass_info
static
LRESULT
WINAPI
edit_subclass_proc
(
HWND
hwnd
,
UINT
message
,
WPARAM
wParam
,
LPARAM
lParam
)
{
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
A
(
hwnd
,
GWL
_USERDATA
);
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
PtrA
(
hwnd
,
GWLP
_USERDATA
);
static
long
defwndproc_counter
=
0
;
LRESULT
ret
;
struct
message
msg
;
...
...
@@ -298,16 +298,16 @@ static HWND create_edit_control(void)
return
NULL
;
}
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
A
(
edit
,
GWL
_WNDPROC
,
(
LONG
)
edit_subclass_proc
);
SetWindowLong
A
(
edit
,
GWL_USERDATA
,
(
LONG
)
info
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
PtrA
(
edit
,
GWLP
_WNDPROC
,
(
LONG
_PTR
)
edit_subclass_proc
);
SetWindowLong
PtrA
(
edit
,
GWLP_USERDATA
,
(
LONG_PTR
)
info
);
return
edit
;
}
static
LRESULT
WINAPI
updown_subclass_proc
(
HWND
hwnd
,
UINT
message
,
WPARAM
wParam
,
LPARAM
lParam
)
{
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
A
(
hwnd
,
GWL
_USERDATA
);
struct
subclass_info
*
info
=
(
struct
subclass_info
*
)
GetWindowLong
PtrA
(
hwnd
,
GWLP
_USERDATA
);
static
long
defwndproc_counter
=
0
;
LRESULT
ret
;
struct
message
msg
;
...
...
@@ -348,9 +348,9 @@ static HWND create_updown_control(void)
return
NULL
;
}
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
A
(
updown
,
GWL
_WNDPROC
,
(
LONG
)
updown_subclass_proc
);
SetWindowLong
A
(
updown
,
GWL_USERDATA
,
(
LONG
)
info
);
info
->
oldproc
=
(
WNDPROC
)
SetWindowLong
PtrA
(
updown
,
GWLP
_WNDPROC
,
(
LONG
_PTR
)
updown_subclass_proc
);
SetWindowLong
PtrA
(
updown
,
GWLP_USERDATA
,
(
LONG_PTR
)
info
);
return
updown
;
}
...
...
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