
				wasPlaying = wasPlaying || BassoonTracker.isPlaying();
				stopPlay();
			};
			progressBar.onchange = function(){
				// align to start of pattern
				var songPos = Math.floor((songLength*progressBar.value/100)/patternLength);
				BassoonTracker.setCurrentSongPosition(songPos);
				if (wasPlaying) togglePlay();
				wasPlaying = false;
			};

			// setup progress bar to seek into the song
			volumeBar.oninput = volumeBar.onchange = function(){
                BassoonTracker.audio.masterVolume.gain.canc