Changed event handler functions to be more like methods
Moved self pointer to initial parameter
Removed unnecessary parameter from handler functions