Refactored events, now instead of instance.events.eventname it is instance.onEventname
temp
Removed temporary keyboard arrow events; Added pausing when browser tab is not active