made some changes to the windowing