Added functional pause button

Added several classes in order to implement a working pause button.