-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
eaa9e5e
commit e22f806
Showing
10 changed files
with
167 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
#include "StdAfx.h" | ||
#include "CustomTreeCtrl.h" | ||
#include "Msg.h" | ||
IMPLEMENT_DYNAMIC(CCustomTreeCtrl, CBCGPTreeCtrlEx) | ||
|
||
CCustomTreeCtrl::CCustomTreeCtrl(void) | ||
{ | ||
} | ||
|
||
|
||
CCustomTreeCtrl::~CCustomTreeCtrl(void) | ||
{ | ||
} | ||
|
||
BEGIN_MESSAGE_MAP(CCustomTreeCtrl, CBCGPTreeCtrlEx) | ||
ON_WM_LBUTTONDBLCLK() | ||
END_MESSAGE_MAP() | ||
|
||
void CCustomTreeCtrl::OnLButtonDblClk(UINT nFlags, CPoint point) | ||
{ | ||
// TODO: 在此添加消息处理程序代码和/或调用默认值 | ||
|
||
HTREEITEM hDBClikeItem = HitTest(point); | ||
|
||
if (NULL != hDBClikeItem) | ||
{ | ||
CWnd* pWnd = GetParent(); | ||
|
||
if (nullptr != pWnd) | ||
{ | ||
pWnd->PostMessage(WM_NOTIFY_TREE_CTRL_DBCLICK,(WPARAM)hDBClikeItem,0); | ||
} | ||
} | ||
|
||
CBCGPTreeCtrlEx::OnLButtonDblClk(nFlags, point); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#pragma once | ||
class CCustomTreeCtrl : public CBCGPTreeCtrlEx | ||
{ | ||
DECLARE_DYNAMIC(CCustomTreeCtrl) | ||
public: | ||
CCustomTreeCtrl(void); | ||
virtual ~CCustomTreeCtrl(void); | ||
|
||
DECLARE_MESSAGE_MAP() | ||
afx_msg void OnLButtonDblClk(UINT nFlags, CPoint point); | ||
}; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters