#include <UiIconBar.h>
继承自UiWin。
公有成员 | |
int | CalcIndexOfPos (int x, int y) |
void | EnableButton (int nIndex, bool bEnable) |
int | GetButtonCount () |
int | GetIconBarType () |
bool | IsButtonEnabled (int nIndex) |
bool | IsButtonShow (int nIndex) |
void | LoadButtonIcon (int nIndex, HINSTANCE hInst, LPCWSTR lpResType, LPCWSTR lpResName) |
void | LoadButtonIcon_Disabled (int nIndex, HINSTANCE hInst, LPCWSTR lpResType, LPCWSTR lpResName) |
从资源中加载指定按钮的图标(禁用状态的) | |
void | LoadButtonIcon_Pressed (int nIndex, HINSTANCE hInst, LPCWSTR lpResType, LPCWSTR lpResName) |
从资源中加载指定按钮的图标(按下状态的) | |
virtual int | OnLButtonDown (UINT fwKeys, int xPos, int yPos) |
当控件被左键按下时,此函数会被调用. | |
virtual int | OnLButtonUp (UINT fwKeys, int xPos, int yPos) |
当控件被左键放开时,此函数会被调用. | |
virtual void | PaintWin (HDC hdcDst, RECT *prcWin, RECT *prcUpdate) |
绘制控件 | |
void | SetButtonCount (int nCount) |
void | SetButtonIcon (int nIndex, ImagingHelper *img, ImagingHelper *imgHL, ImagingHelper *imgDis) |
UIICONBAR_IMAGE_POINTER:. | |
void | SetIconBarType (int nType) |
void | SetImageLoadMode (int nMode) |
void | ShowButton (int nIndex, bool bShow) |
UiIconBar (void) | |
~UiIconBar (void) | |
保护属性 | |
bool | m_bButtonEnable [UIICONBAR_MAX_ICON_COUNT] |
bool | m_bButtonShows [UIICONBAR_MAX_ICON_COUNT] |
int | m_nButtonCount |
int | m_nButtonType |
int | m_nHighLightIndex |
int | m_nImageMode |
int | m_nLButtonDown_Index |
ImagingHelper * | m_pImg [UIICONBAR_MAX_ICON_COUNT] |
ImagingHelper * | m_pImgDis [UIICONBAR_MAX_ICON_COUNT] |
ImagingHelper | m_pImgDisable [UIICONBAR_MAX_ICON_COUNT] |
ImagingHelper * | m_pImgHL [UIICONBAR_MAX_ICON_COUNT] |
ImagingHelper | m_pImgNormal [UIICONBAR_MAX_ICON_COUNT] |
ImagingHelper | m_pImgPRESSED [UIICONBAR_MAX_ICON_COUNT] |
UiIconBar::UiIconBar | ( | void | ) |
UiIconBar::~UiIconBar | ( | void | ) |
int UiIconBar::CalcIndexOfPos | ( | int | x, | |
int | y | |||
) |
void UiIconBar::EnableButton | ( | int | nIndex, | |
bool | bEnable | |||
) |
int UiIconBar::GetButtonCount | ( | ) |
int UiIconBar::GetIconBarType | ( | ) |
bool UiIconBar::IsButtonEnabled | ( | int | nIndex | ) |
bool UiIconBar::IsButtonShow | ( | int | nIndex | ) |
void UiIconBar::LoadButtonIcon | ( | int | nIndex, | |
HINSTANCE | hInst, | |||
LPCWSTR | lpResType, | |||
LPCWSTR | lpResName | |||
) |
UIICONBAR_IMAGE_LOAD: 两种接口不可混合使用 从资源中加载指定按钮的图标
void UiIconBar::LoadButtonIcon_Disabled | ( | int | nIndex, | |
HINSTANCE | hInst, | |||
LPCWSTR | lpResType, | |||
LPCWSTR | lpResName | |||
) |
从资源中加载指定按钮的图标(禁用状态的)
void UiIconBar::LoadButtonIcon_Pressed | ( | int | nIndex, | |
HINSTANCE | hInst, | |||
LPCWSTR | lpResType, | |||
LPCWSTR | lpResName | |||
) |
从资源中加载指定按钮的图标(按下状态的)
virtual int UiIconBar::OnLButtonDown | ( | UINT | fwKeys, | |
int | xPos, | |||
int | yPos | |||
) | [virtual] |
当控件被左键按下时,此函数会被调用.
重载UiWin。
virtual int UiIconBar::OnLButtonUp | ( | UINT | fwKeys, | |
int | xPos, | |||
int | yPos | |||
) | [virtual] |
当控件被左键放开时,此函数会被调用.
重载UiWin。
virtual void UiIconBar::PaintWin | ( | HDC | hdcDst, | |
RECT * | prcWin, | |||
RECT * | prcUpdate | |||
) | [virtual] |
绘制控件
重载此函数可以自定义控件的绘制
hdcDst | 目的DC | |
prcWin | 控件所在区域(以HDC的左上角为原点) | |
prcUpdate | 需要更新的区域(以HDC的左上角为原点) |
重载UiWin。
void UiIconBar::SetButtonCount | ( | int | nCount | ) |
void UiIconBar::SetButtonIcon | ( | int | nIndex, | |
ImagingHelper * | img, | |||
ImagingHelper * | imgHL, | |||
ImagingHelper * | imgDis | |||
) |
UIICONBAR_IMAGE_POINTER:.
void UiIconBar::SetIconBarType | ( | int | nType | ) |
void UiIconBar::SetImageLoadMode | ( | int | nMode | ) |
void UiIconBar::ShowButton | ( | int | nIndex, | |
bool | bShow | |||
) |
bool UiIconBar::m_bButtonEnable[UIICONBAR_MAX_ICON_COUNT] [protected] |
bool UiIconBar::m_bButtonShows[UIICONBAR_MAX_ICON_COUNT] [protected] |
int UiIconBar::m_nButtonCount [protected] |
int UiIconBar::m_nButtonType [protected] |
int UiIconBar::m_nHighLightIndex [protected] |
int UiIconBar::m_nImageMode [protected] |
int UiIconBar::m_nLButtonDown_Index [protected] |
ImagingHelper* UiIconBar::m_pImg[UIICONBAR_MAX_ICON_COUNT] [protected] |
ImagingHelper* UiIconBar::m_pImgDis[UIICONBAR_MAX_ICON_COUNT] [protected] |
ImagingHelper UiIconBar::m_pImgDisable[UIICONBAR_MAX_ICON_COUNT] [protected] |
ImagingHelper* UiIconBar::m_pImgHL[UIICONBAR_MAX_ICON_COUNT] [protected] |
ImagingHelper UiIconBar::m_pImgNormal[UIICONBAR_MAX_ICON_COUNT] [protected] |
ImagingHelper UiIconBar::m_pImgPRESSED[UIICONBAR_MAX_ICON_COUNT] [protected] |