Let's move all below to be AppWindow.prototype.leaveTaskManager(); and call it here.