Now I have a large C++ project which is made up of about 1400k lines of code. Now I have a requirement: Add one line of code to each class which is derived from CDialog, CWnd or CListCtrl. It's impossible for me to do this manually. I think maybe UltraEdit regular expression can give me a hand, but I can't write related regular expression by myself.
Anybody can help me?
Here is the line of code to add:
virtual ULONG GetGestureStatus(CPoint ptTouch) { return 0;}
and here is my code structure(just for a illustration):
class CRibbonAddPlaceDialog : public CDialog
{
DECLARE_DYNAMIC(CRibbonAddPlaceDialog)
public:
CRibbonAddPlaceDialog();
virtual ~CRibbonAddPlaceDialog();
enum { IDD = IDD_RIBBON_ADDPLACE };
protected:
virtual ULONG GetGestureStatus(CPoint ptTouch) { return 0;}//the line to add
virtual void DoDataExchange(CDataExchange* pDX);
DECLARE_MESSAGE_MAP()
afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
afx_msg void OnDestroy();
virtual BOOL OnInitDialog();
virtual BOOL OnCmdMsg(UINT nID, int nCode, void* pExtra, AFX_CMDHANDLERINFO* pHandlerInfo);
public:
BOOL AddButton(CFX_WideString csTitle, AddPlaceButtonProc proc, void* pClientData, CFX_DIBitmap* pButtonImage);
public:
CReader_RibbonFilePageManager* m_pRibbonFilePageMgr;
CReader_RibbonStyle_Static* m_pAddPlace;
CReader_RibbonStyle_Static* m_pAddPlaceTip;
CTypedPtrArray<CPtrArray, buttondata*> m_arButtonData;
CTypedPtrArray<CPtrArray, CBCGPButton*>m_arButton;
};