Some clean up with events and listeners in main class