Is there any easy way to prevent songs from starting to play automatically when clicking on them or pressing next?
I’m hoping to use Amplitude in an event production setting where the standard practice is to queue up the next track, make sure the performer is ready, then press play.
Using callbacks, I have accomplished this by toggling a flag whenever there is a “song_change” and then testing for the flag whenever I see “playing” and then if it’s set, I immediately stop playback and change the appearance of the play-pause button. This is kind of a hack and does result in the play-pause button flickering.
I’ve gone as far as to look into the source code and I think I could accomplish this by testing for a flag before calling Core.play() in four places within utilities/audioNavigation (setNext, setNextPlaylist, setPrevious, setPreviousPlaylist) and then a few places within events/play and events/playPause (handlePlaylistPlay/PlayPause, handleSongPlay/PlayPause, handleSongInPlaylistPlay/PlayPause) but I don’t want to hack on your code if I don’t have to.
Thanks in advance!