Return more items in wxListCtrl::GetColumn.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15976 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
9f79d14b31
commit
3709456403
@ -579,6 +579,8 @@ bool wxListCtrl::GetColumn(int col, wxListItem& item) const
|
||||
LV_COLUMN lvCol;
|
||||
wxZeroMemory(lvCol);
|
||||
|
||||
lvCol.mask = LVCF_WIDTH;
|
||||
|
||||
if ( item.m_mask & wxLIST_MASK_TEXT )
|
||||
{
|
||||
lvCol.mask |= LVCF_TEXT;
|
||||
@ -586,6 +588,16 @@ bool wxListCtrl::GetColumn(int col, wxListItem& item) const
|
||||
lvCol.cchTextMax = 512;
|
||||
}
|
||||
|
||||
if ( item.m_mask & wxLIST_MASK_FORMAT )
|
||||
{
|
||||
lvCol.mask |= LVCF_FMT;
|
||||
}
|
||||
|
||||
if ( item.m_mask & wxLIST_MASK_IMAGE )
|
||||
{
|
||||
lvCol.mask |= LVCF_IMAGE;
|
||||
}
|
||||
|
||||
bool success = ListView_GetColumn(GetHwnd(), col, & lvCol) != 0;
|
||||
|
||||
// item.m_subItem = lvCol.iSubItem;
|
||||
@ -607,6 +619,11 @@ bool wxListCtrl::GetColumn(int col, wxListItem& item) const
|
||||
item.m_format = wxLIST_FORMAT_CENTRE;
|
||||
}
|
||||
|
||||
if ( item.m_mask & wxLIST_MASK_IMAGE )
|
||||
{
|
||||
item.m_image = lvCol.iImage;
|
||||
}
|
||||
|
||||
return success;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user