TurboPack / MustangpeakEasyListview

TurboPack MustangpeakEasyListview is part of VirtualShellTools for the Listview but can be used for a TListview Replacement that is faster and more customizable.
Other
37 stars 22 forks source link

Custom "Draw Focus Rect" #3

Closed Dzomlija closed 4 years ago

Dzomlija commented 5 years ago

I'm currently working on a project that makes extensive use of custom Items and Views classes.

The issue I'm experiencing is with when an item draws a focus rectangle around an item. With all defined custom view classes, I override ItemRectArray and PaintBefore. I perform all necessary drawing in PaintBefore, including a custom focus rectangle that is visible even if the owner TEasyListView does not have input focus, and set handled to TRUE to avoid all other drawing ops.

The trouble arises with the "elsReport" and "elsReportThumb" views. If I do not set "Selection.UseFocusRect" to False when the listview is created, then the standard WinAPI Focus rectangle is drawn over my own. If tried to copy-paste and override "PaintFocusRect" from "TEasyViewItem", but for some strange reason that I have not yet solved, is that the standard WinAPI focus rectangle still gets drawn, even then!

romankassebaum commented 4 years ago

I'm sorry but I have no idea.