Modified the way the mediaplayer works. Fixes ui freezes.