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
abe5dee0
Commit
abe5dee0
authored
Jun 10, 2009
by
Nikolay Sivov
Committed by
Alexandre Julliard
Jun 10, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comctl32/listview: Implement callback functionality for item indentation.
parent
5e5a58b1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
3 deletions
+20
-3
listview.c
dlls/comctl32/listview.c
+19
-2
listview.c
dlls/comctl32/tests/listview.c
+1
-1
No files found.
dlls/comctl32/listview.c
View file @
abe5dee0
...
...
@@ -6,6 +6,7 @@
* Copyright 2000 Jason Mawdsley
* Copyright 2001 CodeWeavers Inc.
* Copyright 2002 Dimitrie O. Paun
* Copyright 2009 Nikolay Sivov
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
...
...
@@ -5746,6 +5747,14 @@ static BOOL LISTVIEW_GetItemT(const LISTVIEW_INFO *infoPtr, LPLVITEMW lpLVItem,
dispInfo
.
item
.
iImage
=
I_IMAGECALLBACK
;
}
/* Only items support indentation */
if
((
lpLVItem
->
mask
&
LVIF_INDENT
)
&&
lpItem
->
iIndent
==
I_INDENTCALLBACK
&&
(
isubitem
==
0
))
{
dispInfo
.
item
.
mask
|=
LVIF_INDENT
;
dispInfo
.
item
.
iIndent
=
I_INDENTCALLBACK
;
}
/* Apps depend on calling back for text if it is NULL or LPSTR_TEXTCALLBACKW */
if
((
lpLVItem
->
mask
&
LVIF_TEXT
)
&&
!
(
lpLVItem
->
mask
&
LVIF_NORECOMPUTE
)
&&
!
is_textW
(
pItemHdr
->
pszText
))
...
...
@@ -5837,8 +5846,16 @@ static BOOL LISTVIEW_GetItemT(const LISTVIEW_INFO *infoPtr, LPLVITEMW lpLVItem,
}
/* and last, but not least, the indent field */
if
(
lpLVItem
->
mask
&
LVIF_INDENT
)
lpLVItem
->
iIndent
=
lpItem
->
iIndent
;
if
(
dispInfo
.
item
.
mask
&
LVIF_INDENT
)
{
lpLVItem
->
iIndent
=
dispInfo
.
item
.
iIndent
;
if
((
dispInfo
.
item
.
mask
&
LVIF_DI_SETITEM
)
&&
lpItem
->
iIndent
==
I_INDENTCALLBACK
)
lpItem
->
iIndent
=
dispInfo
.
item
.
iIndent
;
}
else
if
(
lpLVItem
->
mask
&
LVIF_INDENT
)
{
lpLVItem
->
iIndent
=
lpItem
->
iIndent
;
}
return
TRUE
;
}
...
...
dlls/comctl32/tests/listview.c
View file @
abe5dee0
...
...
@@ -3304,7 +3304,7 @@ static void test_indentation(void)
expect
(
TRUE
,
r
);
ok_sequence
(
sequences
,
PARENT_SEQ_INDEX
,
single_getdispinfo_parent_seq
,
"get indent dispinfo"
,
TRU
E
);
"get indent dispinfo"
,
FALS
E
);
DestroyWindow
(
hwnd
);
}
...
...
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