forked from SomeSupport/eMule
-
Notifications
You must be signed in to change notification settings - Fork 97
/
ClosableTabCtrl.h
43 lines (36 loc) · 1.33 KB
/
ClosableTabCtrl.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#pragma once
class CClosableTabCtrl : public CTabCtrl
{
DECLARE_DYNAMIC(CClosableTabCtrl)
public:
CClosableTabCtrl();
virtual ~CClosableTabCtrl();
BOOL DeleteItem(int nItem);
bool m_bCloseable;
protected:
CImageList m_ImgLstCloseButton;
IMAGEINFO m_iiCloseButton;
CPoint m_ptCtxMenu;
void InternalInit();
void SetAllIcons();
void GetCloseButtonRect(int iItem, const CRect& rcItem, CRect& rcCloseButton, bool bItemSelected, bool bVistaThemeActive);
int GetTabUnderContextMenu() const;
int GetTabUnderPoint(CPoint point) const;
bool SetDefaultContextMenuPos();
virtual void PreSubclassWindow();
virtual void DrawItem(LPDRAWITEMSTRUCT lpDrawItemStruct);
virtual BOOL OnCommand(WPARAM wParam, LPARAM lParam);
DECLARE_MESSAGE_MAP()
afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
afx_msg void OnMButtonUp(UINT nFlags, CPoint point);
afx_msg void OnLButtonDblClk(UINT nFlags, CPoint point);
afx_msg void OnSysColorChange();
afx_msg void OnContextMenu(CWnd* pWnd, CPoint point);
afx_msg LRESULT _OnThemeChanged();
afx_msg HBRUSH CtlColor(CDC* /*pDC*/, UINT /*nCtlColor*/);
afx_msg HBRUSH OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor);
afx_msg BOOL OnEraseBkgnd(CDC* pDC);
afx_msg void OnMeasureItem(int, LPMEASUREITEMSTRUCT);
afx_msg void MeasureItem(LPMEASUREITEMSTRUCT);
};