|
Hotspot DblClick |
Posted by Sergey on Apr-20-2015 14:13 |
|
How to handle mouse double click on the chart? The MFC c++ application. In the message map created ON_BN_DOUBLECLICKED(IDC_CHART, OnDblClickChartViewer), but it does not work... |
Re: Hotspot DblClick |
Posted by Peter Kwan on Apr-20-2015 23:51 |
|
Hi Sergey,
The ON_BN_DOUBLECLICKED is for handling double click for a CButton control, so it is not
applicable to CChartViewer (which is a subclass of CStatic).
You can handle mouse double click using the standard method for MFC CStatic control.
(a) Create a derived class from the control (derived from CChartViewer)
(b) Configure the derived class to listen to handle WM_LBUTTONDBLCLK message.
(c) You can now override the OnLButtonDblClk(UINT nFlags, CPoint point) of your derived
class to handle the double click.
Hope this can help.
Regards
Peter Kwan |
|