@Override
	public void stop() {
		if (player != null) {
			// Stop is supposed to call 'seek(0)' in implementation but for some reason it is not consistent.
			// Especially if the current state is 'paused'. If we request the seek ourselves it *seems* more reliable.
			player.seek(Duration.ZERO);
			player.stop();
			player.setAudioSpectrumListener(null);
			playbackListeners.forEach(Runnable::run);

			// Reset spectrum data
			SpectrumListener listener = getSpectrumListener();
			if (listener != null && eventInstance != null) {
				Arrays.fill(eventInstance.magnitudes(), -100);
				listener.onSpectrum(eventInstance);
			}
		}
	}
A media-player using JavaFX's {@link MediaPlayer} with the use of {@link RecafURLStreamHandlerProvider}
which allows pulling audio from 'memory' via the current {@link Workspace}.

@author Matt Coley
recaf-ui/src/main/java/software/coley/recaf/ui/media/FxPlayer.java