我想做一个有特效的按钮,如当鼠标按下时使按钮上的图片变淡
LRESULT OnLButtonDown(UINT msg, WPARAM wParam, LPARAM lParam, BOOL& bHandled) 
{
bHandled = FALSE;
alpha(lParam, 0, 168, 68);
return 0;
}

LRESULT CBeepButton::OnDrawItem(UINT /*uMsg*/, WPARAM /*wParam*/, LPARAM lParam, BOOL& /*bHandled*/)
{
LPDRAWITEMSTRUCT lpdis = (LPDRAWITEMSTRUCT)lParam;
HDC hdcMem = CreateCompatibleDC(lpdis->hDC); m_hbmp = LoadBitmap(hInst, MAKEINTRESOURCE(IDB_BITMAP1));
SelectObject(hdcMem, m_hbmp);
BitBlt(lpdis->hDC, 0, 0, 168, 68, hdcMem, 0, 0, SRCCOPY); return 0;
}void CBeepButton::alpha(LPARAM lParam, BYTE nLevel, int width, int heigh)
{
LPDRAWITEMSTRUCT lpdis = (LPDRAWITEMSTRUCT)lParam;
HDC hdc = CreateCompatibleDC(lpdis->hDC);
BLENDFUNCTION rBlendProps; rBlendProps.BlendOp = AC_SRC_OVER;
rBlendProps.BlendFlags = 0;
rBlendProps.AlphaFormat = 0;
rBlendProps.SourceConstantAlpha = nLevel; SelectObject(hdc, m_hbmp);
AlphaBlend(lpdis->hDC, 0, 0, width, heigh, hdc, 0, 0, width, heigh, rBlendProps); Invalidate();
}为什么没效果?