wahjam/wahjam — pull request #39 by stefanha (2012-03-13 09:15:42+00:00)
Title: Chat autoscroll

These patches make the chat autoscroll. Currently the chat scroll is behind one line.

Patch 1 refactors the Vote [+1] so we can make chatAddLine() autoscroll properly.

Patch 2 simply bumps us to the end of the chat each time a new line is added.

If you scroll back and a new message is received the chat will jump to the bottom again. I didn't want to add worry about this because it's a rare case. If we want to handle it nicely in the future it probably makes sense to separate out the chatOutput and chatInput widgets into a custom widget so the code doesn't spread across MainWindow.