playedBeatChanged
Description​
This event is fired when the played beat changed.
playedBeatChangedJavaScript |
alphaTab.playedBeatChangedjQuery |
alphaTab.playedBeatChangedHTML |
PlayedBeatChanged.net |
playedBeatChangedAndroid |
Types​
function(beat)JavaScript |
Action<AlphaTab.Model.Beat>.net |
(beat: alphaTab.model.Beat): UnitAndroid |
Parameters​
Parameters | Type | Summary |
---|---|---|
beatJavaScript | alphaTab.model.Beat | The new beat that is now being played.. |
beat.net | AlphaTab.Model.Beat | The new beat that is now being played.. |
beatAndroid | alphaTab.model.Beat | The new beat that is now being played.. |
Examples​
- JavaScript
- HTML
- jQuery
- C#
- Android
const api = new alphaTab.AlphaTabApi(document.querySelector('#alphaTab'));
api.playedBeatChanged.on((beat) => {
updateFretboard(beat);
});
$('#alphaTab').on('alphaTab.playedBeatChanged', (e, beat) => {
updateFretboard(beat);
});
document.querySelector('#alphaTab').addEventListener('alphaTab.playedBeatChanged', (e) => {
const beat = e.detail;
updateFretboard(beat);
}, false);
var api = new AlphaTabApi<MyControl>(...);
api.PlayedBeatChanged.On(beat =>
{
UpdateFretboard(beat);
});
val api = AlphaTabApi<MyControl>(...)
api.playedBeatChanged.on { beat ->
updateFretboard(beat)
}