Skip to main content

beatMouseDown

since 0.9.7

Description​

This event is fired whenever a the user presses the mouse button on a beat.

beatMouseDownJavaScript
alphaTab.beatMouseDownjQuery
alphaTab.beatMouseDownHTML
BeatMouseDown.net
beatMouseDownAndroid

Types​

function(beat, originalEvent)JavaScript
Action<AlphaTab.Model.Beat>.net
(beat: alphaTab.model.Beat) -> UnitAndroid

Parameters​

ParametersTypeSummary
beatJavaScriptalphaTab.model.Beat

The new beat that is now being played..

originalEventJavaScript & jQueryMouseEvent

The original mouse event that lead to trigger of the beat event. For the DOM event it is stored in the event.originalEvent.

beat.netAlphaTab.Model.Beat

The new beat that is now being played.

beatAndroidalphaTab.model.Beat

The new beat that is now being played.

Examples​

const api = new alphaTab.AlphaTabApi(document.querySelector('#alphaTab'));
api.beatMouseDown.on((beat) => {
startSelectionOnBeat(beat);
});