comctl32: listview: Store the iSubItem in header's lParam in LVM_INSERTCOLUMN.

This commit is contained in:
Mikołaj Zalewski 2006-05-13 21:34:57 +02:00 committed by Alexandre Julliard
parent 74c3b366d3
commit 700dd456e9
1 changed files with 10 additions and 0 deletions

View File

@ -6545,6 +6545,16 @@ static INT LISTVIEW_InsertColumnT(LISTVIEW_INFO *infoPtr, INT nColumn,
ZeroMemory(&hdi, sizeof(HDITEMW));
column_fill_hditem(infoPtr, &hdi, nColumn, lpColumn, isW);
/*
* when the iSubItem is available Windows copies it to the header lParam. It seems
* to happen only in LVM_INSERTCOLUMN - not in LVM_SETCOLUMN
*/
if (lpColumn->mask & LVCF_SUBITEM)
{
hdi.mask |= HDI_LPARAM;
hdi.lParam = lpColumn->iSubItem;
}
/* insert item in header control */
nNewColumn = SendMessageW(infoPtr->hwndHeader,