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
3ac601d5
Commit
3ac601d5
authored
Oct 07, 2002
by
Dimitrie O. Paun
Committed by
Alexandre Julliard
Oct 07, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix silly bug in SetItemPosition (we should set it, not create a new
one).
parent
b9cacc43
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
2 deletions
+12
-2
listview.c
dlls/comctl32/listview.c
+12
-2
No files found.
dlls/comctl32/listview.c
View file @
3ac601d5
...
...
@@ -6800,6 +6800,7 @@ static BOOL LISTVIEW_SetItemCount(LISTVIEW_INFO *infoPtr, INT nItems, DWORD dwFl
static
BOOL
LISTVIEW_SetItemPosition
(
LISTVIEW_INFO
*
infoPtr
,
INT
nItem
,
POINT
pt
)
{
UINT
uView
=
infoPtr
->
dwStyle
&
LVS_TYPEMASK
;
POINT
old
;
TRACE
(
"(nItem=%d, &pt=%s
\n
"
,
nItem
,
debugpoint
(
&
pt
));
...
...
@@ -6817,10 +6818,19 @@ static BOOL LISTVIEW_SetItemPosition(LISTVIEW_INFO *infoPtr, INT nItem, POINT pt
pt
.
y
-=
ICON_TOP_PADDING
;
}
/* save the old position */
old
.
x
=
(
LONG
)
DPA_GetPtr
(
infoPtr
->
hdpaPosX
,
nItem
);
old
.
y
=
(
LONG
)
DPA_GetPtr
(
infoPtr
->
hdpaPosY
,
nItem
);
/* Is the position changing? */
if
(
pt
.
x
==
old
.
x
&&
pt
.
y
==
old
.
y
)
return
TRUE
;
/* FIXME: shouldn't we invalidate, as the item moved? */
/* Allocating a POINTER for every item is too resource intensive,
* so we'll keep the (x,y) in different arrays */
if
(
DPA_
InsertPtr
(
infoPtr
->
hdpaPosX
,
nItem
,
(
void
*
)
pt
.
x
)
==
nItem
&&
DPA_
InsertPtr
(
infoPtr
->
hdpaPosY
,
nItem
,
(
void
*
)
pt
.
y
)
==
nItem
)
if
(
DPA_
SetPtr
(
infoPtr
->
hdpaPosX
,
nItem
,
(
void
*
)
pt
.
x
)
&&
DPA_
SetPtr
(
infoPtr
->
hdpaPosY
,
nItem
,
(
void
*
)
pt
.
y
)
)
return
TRUE
;
ERR
(
"We should never fail here (nItem=%d, pt=%s), please report.
\n
"
,
...
...
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