LAPTOP-T815PCOQ\25526
2025-01-13 647d047c43cfff577cca024214e3f181202f876c
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
#if !defined(AFX_BLBUTTON_H__16C6D980_BD45_11D3_BDA3_00104B133581__INCLUDED_)
#define AFX_BLBUTTON_H__16C6D980_BD45_11D3_BDA3_00104B133581__INCLUDED_
 
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// BLButton.h : header file
//
 
/////////////////////////////////////////////////////////////////////////////
// CBLButton by Niek Albers
// Thanks to some people for the tooltip.
// A cool CBitmapButton derived class with 3 states,
// Up/Down/BL.
class AFX_EXT_CLASS CBLButton : public CBitmapButton
{
    DECLARE_DYNAMIC(CBLButton);
 
    // Construction
public:
    CBLButton();
    void SetToolTipText(CString* spText, BOOL bActivate = TRUE);
    void SetToolTipText(int nId, BOOL bActivate = TRUE);
    void SetWindowText(CString strText);
    void SetFontSize(int nSize);
    void SetTextColor(COLORREF rgbNormal, COLORREF rgbDisable);
    void SetBLButtonStyle(UINT uID, int nImgCount);
    void SetBLButtonStyle(UINT uID, int nImgCount, CString spTipText);
    void SetBLButtonStyle(UINT uID, int nImgCount, CString spTipText, CString spBtnText, int nFontSize);
 
    CString m_strText;
    CDC      m_gMemDC;
 
// Attributes
protected:
    void fPaint(CDC* pDC);
    void ActivateTooltip(BOOL bActivate = TRUE);
    BOOL m_bBL;                        // indicates if mouse is over the button
    CSize m_ButtonSize;                    // width and height of the button
    CBitmap m_Bitmap;
    BOOL m_bTracking;
 
// Overrides
    // ClassWizard generated virtual function overrides
    //{{AFX_VIRTUAL(CBLButton)
    protected:
    virtual BOOL PreTranslateMessage(MSG* pMsg);
    virtual void DrawItem(LPDRAWITEMSTRUCT lpDrawItemStruct);
    //}}AFX_VIRTUAL
 
// Implementation
public:
    BOOL LoadBitmap(UINT bitmapid, UINT uiImageCount);
    virtual ~CBLButton();
 
    // Generated message map functions
protected:
    CToolTipCtrl m_ToolTip;
    void InitToolTip();
    //{{AFX_MSG(CBLButton)
    afx_msg void OnMouseMove(UINT nFlags, CPoint point);
    afx_msg LRESULT OnMouseLeave(WPARAM wparam, LPARAM lparam);
    afx_msg LRESULT OnMouseHOver(WPARAM wparam, LPARAM lparam) ;
    //}}AFX_MSG
 
    DECLARE_MESSAGE_MAP()
 
private:
    UINT m_uiImageCount;
    CFont    m_Font;
    LOGFONT        m_lf;
    COLORREF m_RGBTextNormal;
    COLORREF m_RGBTextDisable;
    BOOL m_bIsDisable;    // DisableÀÏ ¶§´Â ±ÛÀÚ»öÀ» ¹Ù²Ù±â À§ÇØ.
};
 
/////////////////////////////////////////////////////////////////////////////
 
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
 
#endif // !defined(AFX_BLBUTTON_H__16C6D980_BD45_11D3_BDA3_00104B133581__INCLUDED_)