Beispiel #1
0
func trackUnderMouse() (uint8, bool) {
	//
	if scr.UnderMouse(l0, 0, cs+5, uint(cdker.NTracks())) {
		l, _ := scr.MousePos()
		return uint8(l) - l0, true
	}
	return 0, false
}
Beispiel #2
0
func timeUnderMouse() (bool, uint, bool) {
	//
	for i := uint(0); i < 2; i++ {
		if scr.UnderMouse(lt[i], cr, wr, 2) {
			var n uint
			timeBar[i].Edit(&n)
			return i != 0, n, true
		}
	}
	return false, 0, false
}
Beispiel #3
0
func controlUnderMouse(c *cdker.Controller) (uint, bool) {
	//
	for i := cdker.Controller(0); i < cdker.NCtrl; i++ {
		if scr.UnderMouse(lv[i], cr, wr, 2) {
			var n uint
			ctrlBar[i].Edit(&n)
			*c = i
			return n, true
		}
	}
	return 0, false
}