Split up drawwindow into methods