Added a method to close the splash screen