Compatability updates

I added your script to my xbmc instance and noticed that it wasn't working properly with the Aeon Nox skin. I've made some changes and it runs properly now for me.