void CSensorGain::OnHScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar) { // TODO: Add your message handler code here and/or call default CString szBuffer; char cBuff[20] = {0}; int nTemp = 0; int nCurrentPos = 0; if (IDC_SENSORGAIN_GAPMODESLIDER == pScrollBar->GetDlgCtrlID()) { switch (nSBCode) { case TB_LINEUP: nCurrentPos = m_GapModeSlider.GetPos(); SendSensorGainCommand(nCurrentPos); break; case TB_LINEDOWN: nCurrentPos = m_GapModeSlider.GetPos(); SendSensorGainCommand(nCurrentPos); break; case TB_PAGEUP: nTemp = m_GapModeSlider.GetPos(); m_GapModeSlider.SetPos(nTemp); break; case TB_PAGEDOWN: nTemp = m_GapModeSlider.GetPos(); m_GapModeSlider.SetPos(nTemp); break; case TB_TOP: nCurrentPos = m_GapModeSlider.GetPos(); SendSensorGainCommand(nCurrentPos); break; case TB_BOTTOM: nCurrentPos = m_GapModeSlider.GetPos(); SendSensorGainCommand(nCurrentPos); break; default: break; } return ; } CDialogEx::OnHScroll(nSBCode, nPos, pScrollBar); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)