Enhanced to show the dialog for "Clear project".
Refactored return type of the newInstance() methods.