Added media keys fixed some bugs

As above.