renamed and changed functions in window.h as agreed upon