if(mediaPlayer != null) {
mediaPlayer.stop();
}
mediaPlayer = MediaPlayerBuilder.create().media(arg2).build();
MediaView mediaView = MediaViewBuilder.create().mediaPlayer(mediaPlayer).build();
mediaView.fitHeightProperty().bind(heightProperty());
mediaView.fitWidthProperty().bind(widthProperty());
setGraphic(mediaView);
}
});
}