1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677 |
- #if !defined(AFX_TABSHEET_H__42EE262D_D15F_46D5_8F26_28FD049E99F4__INCLUDED_)
- #define AFX_TABSHEET_H__42EE262D_D15F_46D5_8F26_28FD049E99F4__INCLUDED_
- #if _MSC_VER > 1000
- #pragma once
- #endif // _MSC_VER > 1000
- // TabSheet.h : header file
- //
- enum ETabOrientation
- {
- e_tabTop=0,
- e_tabBottom,
- e_tabLeft,
- e_tabRight,
- e_tabNOF,
- };
- /////////////////////////////////////////////////////////////////////////////
- // CTabSheet window
- #define MAXPAGE 100
- class CTabSheet : public CTabCtrl
- {
- // Construction
- public:
- CTabSheet();
- ETabOrientation m_eTabOrientation; // current tab orientation
- // Attributes
- public:
- // Operations
- public:
- // Overrides
- // ClassWizard generated virtual function overrides
- //{{AFX_VIRTUAL(CTabSheet)
- //}}AFX_VIRTUAL
- // Implementation
- public:
- int GetCurSel();
- int SetCurSel(int nItem);
- void Show();
- void SetRect();
- BOOL AddPage(LPCTSTR title, CDialog *pDialog, UINT ID);
- virtual ~CTabSheet();
- // Generated message map functions
- protected:
- LPCTSTR m_Title[MAXPAGE];
- UINT m_IDD[MAXPAGE];
- CDialog* m_pPages[MAXPAGE];
- int m_nNumOfPages;
- int m_nCurrentPage;
- //{{AFX_MSG(CTabSheet)
- afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
- //}}AFX_MSG
- DECLARE_MESSAGE_MAP()
- public:
- afx_msg void OnPaint();
- void DrawThemesXpTabItem(CDC* pDC, int ixItem, const CRect& rcItem, UINT uiFlag);
- void DrawTabItem(CDC* pDC, int ixItem, const CRect& rcItemC, UINT uiFlags);
- };
- /////////////////////////////////////////////////////////////////////////////
- // Helper functions
- HRESULT DrawThemesPart(HDC hDC, int iPartId, int iStateId, LPCSTR uiPartNameID, LPRECT prcRcBx);
- BOOL IsThemeActiveXP();
- int DWordAlign(int n);
- template <class T> void SwapVars(T& a,T& b) { T t=a; a=b; b=t; }
- /////////////////////////////////////////////////////////////////////////////
- //{{AFX_INSERT_LOCATION}}
- // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
- #endif // !defined(AFX_TABSHEET_H__42EE262D_D15F_46D5_8F26_28FD049E99F4__INCLUDED_)
|