Added window resize support to Main in Application.