Originally posted by: moi
I have many memory leaks using your control...
Heelp !
Reply
Originally posted by: B.U.
Need help!
ReplyOriginally posted by: StandaK
Hi,
this class is really great. But I've encountered problem when I've made my CListView virtual. The problem is that ListView flickers and is attempting to refresh all the time (-> other parts of application windows can't get drawn due to this).
The problem lines are these two in OnCustomDraw():
case CDDS_ITEMPREPAINT:
.
.
if(m_item_selected)
{
__m_ListCtrl->SetItemState(nItem,NULL,LVIS_SELECTED);
__bNotifyPostPaint = true;
}
.
.
and
case CDDS_ITEMPOSTPAINT:
.
.
if(m_item_selected)
{
__m_item_selected = false;
__m_ListCtrl->SetItemState(nItem,LVIS_SELECTED,LVIS_SELECTED);
}
.
.
when I comment out the lines with SetItemState(), everything is ok, but then I can't use SetColSelectedTxtColor() and so on...
What should I do to solve it?
Thank you for any suggestion.
Standa K.
Originally posted by: Gary
Hi,
The list control is wonderful. But, I have one problem. Just as we have CBN_SELCHANGE message in combobox to trap the change of selection event, what event shall I use in this list control? Basically, I want to display related records in a different grid when the selection in list control changes. I could not find the event to do this.
Please help me.
Thanks,
- Gary
Reply
Originally posted by: vgrigor
I create derived class in a usual way
but if content exceeds its size - Scroll bars appears,
but
no slider presented, (!)
to see position in scrolling view-
but by middle button of mouse scrolling is working.
Wh so and how to correct?
[code]
class CAlarmView : public CListCtrlStyled
{..};
class CAlarmWnd : public CFrameWnd
{
CAlarmView m_AlarmView;
};
CFrameWnd::OnCreate()
{
m_AlarmView.Create(LVS_REPORT | WS_VISIBLE | WS_CHILD | WS_BORDER |WS_VSCROLL
,CRect(0,0,0,0),this,0);
m_AlarmView.
//ModifyStyleEx
SetExtendedStyle
(
//NULL,
LVS_EX_ONECLICKACTIVATE |
LVS_EX_FULLROWSELECT |
LVS_EX_CHECKBOXES |
LVS_EX_UNDERLINEHOT |
LVS_EX_INFOTIP |
LVS_EX_FLATSB |
LVS_EX_GRIDLINES
| WS_EX_STATICEDGE
);
}
[/code]
Originally posted by: ron
when i call SetItemCountEx(), i get an error inside the
// Take Corects Structure style that we need
my same exact code works if i just change the associated
do you possibly have a fix for this? thanks!
i find your class VERY useful and i've been using it
heavily. however, i can't get it to work with the
LVS_OWNERDATA style.
CListCtrlStyled::FontForItem() function. it page faults
right at the 'lpLS_row' line where you wrote:
//
lpLS_item = lpLS_root;
lpLS_row = lpLS_root->row_style;
lpLS_col = this->columns[nSubItem];
list control class to the standard MFC CListCtrl. it page
faults right away when i switch it back to CListCtrlStyled.
Originally posted by: GabAve
Your class is very nice but... I can't use it because GetItemData() don't work!!
ReplyOriginally posted by: Moshe
Hi
This is a great code, and it's very usefull.
I would like to know if you have any code with the sameoptions for a combo box?
(I need the bold style in particular)
Thanks in advance
Moshe
Originally posted by: jiulun
Perhaps someone wants to use this in listview.
Have fun.
This is a really useful control.
You can read this article at http://www.codeguru.com/listview/ctrl_vs_view_undoc.shtml
I have tried this and it really works. If anyone need the demo project with listview, I can send it by email.
Originally posted by: s_k
I am able to set color for selected item (LVIS_SELECTED flag)(Set...SelectedColor()) but I dont know how to set color for item with LVIS_FOCUSED flag...
Thanks.
Reply