// PtzButton.cpp : implementation file
//

#include "stdafx.h"
#include "NetSdkDemo.h"
#include "PtzButton.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CPtzButton

CPtzButton::CPtzButton()
{
}

CPtzButton::~CPtzButton()
{
}


BEGIN_MESSAGE_MAP(CPtzButton, CButton)
	//{{AFX_MSG_MAP(CPtzButton)
	ON_WM_LBUTTONDOWN()
	ON_WM_LBUTTONUP()
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CPtzButton message handlers
void CPtzButton::OnLButtonDown(UINT nFlags, CPoint point) 
{
	// TODO: Add your message handler code here and/or call default
	GetParent()->PostMessage(WM_COMMAND, (BN_PUSHED << 16) | GetDlgCtrlID(), (LPARAM)m_hWnd);
	CButton::OnLButtonDown(nFlags, point);
}

void CPtzButton::OnLButtonUp(UINT nFlags, CPoint point) 
{
	// TODO: Add your message handler code here and/or call default
	GetParent()->PostMessage(WM_COMMAND, (BN_UNPUSHED << 16) | GetDlgCtrlID(), (LPARAM)m_hWnd);
	CButton::OnLButtonUp(nFlags, point);
}

