LRESULT CRTCAVSession::OnHScroll(UINT uMsg, WPARAM wParam, LPARAM lParam)
{
    if ((LOWORD(wParam) == SB_THUMBPOSITION) ||
        (LOWORD(wParam) == SB_THUMBTRACK))
    {
        if ((HWND)lParam == m_hSpkVol)
        {
            // Speaker volume adjusted
            DoVolume(RTCAD_SPEAKER, HIWORD(wParam));
        }
        else if ((HWND)lParam == m_hMicVol)
        {
            // Microphone volume adjusted
            DoVolume(RTCAD_MICROPHONE, HIWORD(wParam));
        }
    }

    return 0;
}
Esempio n. 2
0
static void click_PlayerWin(Point p, short /*modifiers*/)
{
		if( PtInRect(p, &rStop)){ mac_rc=RC_QUIT; ctl_current_time(0,0); }
	else	if( PtInRect(p, &rPlay)){ mac_rc=RC_CONTINUE; }
	else	if( PtInRect(p, &rPause)){ mac_rc=RC_TOGGLE_PAUSE; }
	else	if( PtInRect(p, &rPrevious)){ mac_rc=RC_PREVIOUS;  }
	else	if( PtInRect(p, &rForward)){ mac_rc=RC_NEXT; }
	else	if( PtInRect(p, &rEject)){
				if( skin_state==PLAYING ) mac_rc=RC_QUIT;
				skin_state=WAITING; mac_n_files=nPlaying=0; fileStr[0]=timeStr[0]=0;
				init_ListWin();
				update_PlayerWin();
			}
	else	if( PtInRect(p, &rLoop)){ skin_f_repeat=!skin_f_repeat; SetPortWindowPort(win.ref);
									InvalRect(&rLoop); return; } /* don't call mac_HandleControl();*/
	else	if( PtInRect(p, &rVol))	DoVolume();
	else	return; /* no button click*/
	
	/* if button clicked */
	mac_HandleControl();
}