In a TDbGrid.OnColumnMoved
event handler, I adjust some column headings colors.
I also use the grid\'s OnTitleClicked
event to pop-up a (so
As mentioned in comments to the question, you would supply the 'Msg' for PeekMessage
yourself (var Msg: TMsg
). But discarding the message that triggers OnTitleClick
is not possible because it is the same message that fires both events. VCL carries out column moving in response to a WM_LBUTTONUP
message if a column has been dragged. Later during the handling of the same message OnTitleClick
is called.
IOW, while you can remove messages from the message queue with PeekMessage
, the message that triggers OnTitleClick
is already dispatched since we are in an OnColumnMoved
handler.
Easiest approach looks like setting the flag as you've told.