activeBeatsChanged
Description​
This event is fired when the currently active beats across all tracks change. Unlike the playedBeatChanged
event this event contains the beats of all tracks and voices independent of them being rendered.
- JavaScript
- C#
- Kotlin
readonly activeBeatsChanged: IEventEmitterOfT<ActiveBeatsChangedEventArgs>;
IEventEmitterOfT<ActiveBeatsChangedEventArgs> ActiveBeatsChanged { get; }
val activeBeatsChanged: IEventEmitterOfT<ActiveBeatsChangedEventArgs>
Examples​
- JavaScript
- C#
- Android
const api = new alphaTab.AlphaTabApi(document.querySelector('#alphaTab'));
api.activeBeatsChanged.on(args => {
updateHighlights(args.activeBeats);
});
var api = new AlphaTabApi<MyControl>(...);
api.ActiveBeatsChanged.On(args =>
{
UpdateHighlights(args.ActiveBeats);
});
val api = AlphaTabApi<MyControl>(...)
api.activeBeatsChanged.on { args ->
updateHighlights(args.activeBeats)
}