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
284bcfcf
Commit
284bcfcf
authored
May 28, 2002
by
Andreas Mohr
Committed by
Alexandre Julliard
May 28, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed a memory leak in find_child_from_point().
parent
7c61a616
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
8 deletions
+12
-8
winpos.c
windows/winpos.c
+12
-8
No files found.
windows/winpos.c
View file @
284bcfcf
...
...
@@ -326,6 +326,7 @@ static HWND find_child_from_point( HWND parent, POINT pt, INT *hittest, LPARAM l
RECT
rectWindow
,
rectClient
;
WND
*
wndPtr
;
HWND
*
list
=
WIN_ListChildren
(
parent
);
HWND
retvalue
=
0
;
if
(
!
list
)
return
0
;
for
(
i
=
0
;
list
[
i
];
i
++
)
...
...
@@ -361,40 +362,43 @@ static HWND find_child_from_point( HWND parent, POINT pt, INT *hittest, LPARAM l
if
(
style
&
WS_MINIMIZE
)
{
*
hittest
=
HTCAPTION
;
return
list
[
i
];
retvalue
=
list
[
i
];
break
;
}
if
(
style
&
WS_DISABLED
)
{
*
hittest
=
HTERROR
;
return
list
[
i
];
retvalue
=
list
[
i
];
break
;
}
/* If point is in client area, explore children */
if
(
PtInRect
(
&
rectClient
,
pt
))
{
POINT
new_pt
;
HWND
ret
;
new_pt
.
x
=
pt
.
x
-
rectClient
.
left
;
new_pt
.
y
=
pt
.
y
-
rectClient
.
top
;
if
((
ret
=
find_child_from_point
(
list
[
i
],
new_pt
,
hittest
,
lparam
)))
return
ret
;
if
((
retvalue
=
find_child_from_point
(
list
[
i
],
new_pt
,
hittest
,
lparam
)))
break
;
}
/* Now it's inside window, send WM_NCCHITTEST (if same thread) */
if
(
!
WIN_IsCurrentThread
(
list
[
i
]
))
{
*
hittest
=
HTCLIENT
;
return
list
[
i
];
retvalue
=
list
[
i
];
break
;
}
if
((
res
=
SendMessageA
(
list
[
i
],
WM_NCHITTEST
,
0
,
lparam
))
!=
HTTRANSPARENT
)
{
*
hittest
=
res
;
/* Found the window */
return
list
[
i
];
retvalue
=
list
[
i
];
break
;
}
/* continue search with next sibling */
}
return
0
;
HeapFree
(
GetProcessHeap
(),
0
,
list
);
return
retvalue
;
}
...
...
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