Bug in ListView .NET 2.0?
-
Or am I doing something wrong? I'm creating a column sortable Listview and I want to give the user some visual feedback on which column is sorted and all that stuff, aka a sorting arrow. In order to do that I'm activating OwnerDraw and then in all the protected overriden methods (OnDrawItem, OnDrawSubItem, etc) I'm setting DefaultDraw=true; The only painting I'm really handling is inside OnDrawColumnHeader. I have everything working fine with XP themes and all using the VisualStyle namespace but there's one bug I can't seem to fix: The DrawListViewColumnHeaderEventArgs has a property which gives you the ListViewItemStates of the header. The ones I'm interested in are Default, Hot and Selected. The bug is that the Hot state never seems to activate, when you mouse over the header, the e.State property does not change and remains 0 or default. This makes it imposible to correctly render a themed header as it I can't detect when I have to paint a hot header. I've tried using Rectancle.Contains(Cursor) but that runs into tons of problems when moving cursor from one header to another. Anyone know if this is a known issue or am I doing something wrong? thanks
-
Or am I doing something wrong? I'm creating a column sortable Listview and I want to give the user some visual feedback on which column is sorted and all that stuff, aka a sorting arrow. In order to do that I'm activating OwnerDraw and then in all the protected overriden methods (OnDrawItem, OnDrawSubItem, etc) I'm setting DefaultDraw=true; The only painting I'm really handling is inside OnDrawColumnHeader. I have everything working fine with XP themes and all using the VisualStyle namespace but there's one bug I can't seem to fix: The DrawListViewColumnHeaderEventArgs has a property which gives you the ListViewItemStates of the header. The ones I'm interested in are Default, Hot and Selected. The bug is that the Hot state never seems to activate, when you mouse over the header, the e.State property does not change and remains 0 or default. This makes it imposible to correctly render a themed header as it I can't detect when I have to paint a hot header. I've tried using Rectancle.Contains(Cursor) but that runs into tons of problems when moving cursor from one header to another. Anyone know if this is a known issue or am I doing something wrong? thanks
bump! Anyhelp plz?