added maximize method to maximize the window