forked from qdtroy/DuiLib_Ultimate
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of https://github.com/napasa/DuiLib_Ultimate
- Loading branch information
Showing
12 changed files
with
152 additions
and
136 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,96 +1,96 @@ | ||
#ifndef __UIOPTION_H__ | ||
#define __UIOPTION_H__ | ||
|
||
#pragma once | ||
|
||
namespace DuiLib | ||
{ | ||
class UILIB_API COptionUI : public CButtonUI | ||
{ | ||
#ifndef __UIOPTION_H__ | ||
#define __UIOPTION_H__ | ||
|
||
#pragma once | ||
|
||
namespace DuiLib | ||
{ | ||
class UILIB_API COptionUI : public CButtonUI | ||
{ | ||
DECLARE_DUICONTROL(COptionUI) | ||
public: | ||
COptionUI(); | ||
~COptionUI(); | ||
|
||
LPCTSTR GetClass() const; | ||
LPVOID GetInterface(LPCTSTR pstrName); | ||
|
||
void SetManager(CPaintManagerUI* pManager, CControlUI* pParent, bool bInit = true); | ||
|
||
bool Activate(); | ||
void SetEnabled(bool bEnable = true); | ||
|
||
LPCTSTR GetSelectedImage(); | ||
void SetSelectedImage(LPCTSTR pStrImage); | ||
|
||
LPCTSTR GetSelectedHotImage(); | ||
void SetSelectedHotImage(LPCTSTR pStrImage); | ||
|
||
LPCTSTR GetSelectedPushedImage(); | ||
void SetSelectedPushedImage(LPCTSTR pStrImage); | ||
|
||
void SetSelectedTextColor(DWORD dwTextColor); | ||
DWORD GetSelectedTextColor(); | ||
|
||
void SetSelectedBkColor(DWORD dwBkColor); | ||
DWORD GetSelectBkColor(); | ||
|
||
LPCTSTR GetSelectedForedImage(); | ||
void SetSelectedForedImage(LPCTSTR pStrImage); | ||
|
||
public: | ||
COptionUI(); | ||
~COptionUI(); | ||
|
||
LPCTSTR GetClass() const; | ||
LPVOID GetInterface(LPCTSTR pstrName); | ||
|
||
void SetManager(CPaintManagerUI* pManager, CControlUI* pParent, bool bInit = true); | ||
|
||
bool Activate(); | ||
void SetEnabled(bool bEnable = true); | ||
|
||
LPCTSTR GetSelectedImage(); | ||
void SetSelectedImage(LPCTSTR pStrImage); | ||
|
||
LPCTSTR GetSelectedHotImage(); | ||
void SetSelectedHotImage(LPCTSTR pStrImage); | ||
|
||
LPCTSTR GetSelectedPushedImage(); | ||
void SetSelectedPushedImage(LPCTSTR pStrImage); | ||
|
||
void SetSelectedTextColor(DWORD dwTextColor); | ||
DWORD GetSelectedTextColor(); | ||
|
||
void SetSelectedBkColor(DWORD dwBkColor); | ||
DWORD GetSelectBkColor(); | ||
|
||
LPCTSTR GetSelectedForedImage(); | ||
void SetSelectedForedImage(LPCTSTR pStrImage); | ||
|
||
void SetSelectedStateCount(int nCount); | ||
int GetSelectedStateCount() const; | ||
virtual LPCTSTR GetSelectedStateImage(); | ||
virtual void SetSelectedStateImage(LPCTSTR pStrImage); | ||
|
||
LPCTSTR GetGroup() const; | ||
void SetGroup(LPCTSTR pStrGroupName = NULL); | ||
bool IsSelected() const; | ||
virtual void Selected(bool bSelected); | ||
|
||
void SetAttribute(LPCTSTR pstrName, LPCTSTR pstrValue); | ||
|
||
void PaintBkColor(HDC hDC); | ||
void PaintStatusImage(HDC hDC); | ||
void PaintForeImage(HDC hDC); | ||
void PaintText(HDC hDC); | ||
|
||
protected: | ||
bool m_bSelected; | ||
CDuiString m_sGroupName; | ||
|
||
DWORD m_dwSelectedBkColor; | ||
DWORD m_dwSelectedTextColor; | ||
|
||
CDuiString m_sSelectedImage; | ||
CDuiString m_sSelectedHotImage; | ||
CDuiString m_sSelectedPushedImage; | ||
CDuiString m_sSelectedForeImage; | ||
|
||
virtual void SetSelectedStateImage(LPCTSTR pStrImage); | ||
|
||
LPCTSTR GetGroup() const; | ||
void SetGroup(LPCTSTR pStrGroupName = NULL); | ||
bool IsSelected() const; | ||
virtual void Selected(bool bSelected); | ||
|
||
void SetAttribute(LPCTSTR pstrName, LPCTSTR pstrValue); | ||
|
||
void PaintBkColor(HDC hDC); | ||
void PaintStatusImage(HDC hDC); | ||
void PaintForeImage(HDC hDC); | ||
void PaintText(HDC hDC); | ||
|
||
protected: | ||
bool m_bSelected; | ||
CDuiString m_sGroupName; | ||
|
||
DWORD m_dwSelectedBkColor; | ||
DWORD m_dwSelectedTextColor; | ||
|
||
CDuiString m_sSelectedImage; | ||
CDuiString m_sSelectedHotImage; | ||
CDuiString m_sSelectedPushedImage; | ||
CDuiString m_sSelectedForeImage; | ||
|
||
int m_nSelectedStateCount; | ||
CDuiString m_sSelectedStateImage; | ||
}; | ||
|
||
class UILIB_API CCheckBoxUI : public COptionUI | ||
{ | ||
CDuiString m_sSelectedStateImage; | ||
}; | ||
|
||
class UILIB_API CCheckBoxUI : public COptionUI | ||
{ | ||
DECLARE_DUICONTROL(CCheckBoxUI) | ||
|
||
public: | ||
virtual LPCTSTR GetClass() const; | ||
virtual LPVOID GetInterface(LPCTSTR pstrName); | ||
|
||
void SetCheck(bool bCheck); | ||
bool GetCheck() const; | ||
protected: | ||
bool m_bAutoCheck; | ||
|
||
public: | ||
CCheckBoxUI(); | ||
virtual void SetAttribute(LPCTSTR pstrName, LPCTSTR pstrValue); | ||
void SetAutoCheck(bool bEnable); | ||
virtual void DoEvent(TEventUI& event); | ||
virtual void Selected(bool bSelected); | ||
}; | ||
} // namespace DuiLib | ||
|
||
|
||
public: | ||
virtual LPCTSTR GetClass() const; | ||
virtual LPVOID GetInterface(LPCTSTR pstrName); | ||
|
||
void SetCheck(bool bCheck); | ||
bool GetCheck() const; | ||
protected: | ||
bool m_bAutoCheck; | ||
|
||
public: | ||
CCheckBoxUI(); | ||
virtual void SetAttribute(LPCTSTR pstrName, LPCTSTR pstrValue); | ||
void SetAutoCheck(bool bEnable); | ||
virtual void DoEvent(TEventUI& event); | ||
virtual void Selected(bool bSelected); | ||
}; | ||
} // namespace DuiLib | ||
|
||
#endif // __UIOPTION_H__ |
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
Oops, something went wrong.