Added functions to Window class.