Support switching to a chatbox frame.

I know this still needs improvements to support multiple chat windows, but it's good enough to let us have tests with one chat window, so I think it's already worth taking.