Fix sent history (ctrl+up) browse. There was a bug when history was full and we browsed history.

This commit is contained in:
Jean-Marie Traissard 2008-03-11 23:05:56 +00:00
parent 30d86e7f8b
commit 4199789612
1 changed files with 5 additions and 2 deletions

View File

@ -637,6 +637,9 @@ class ChatControlBase(MessageControl):
for i in xrange(0, size - 1):
self.sent_history[i] = self.sent_history[i + 1]
self.sent_history[max_size - 1] = message
# self.sent_history_pos has changed if we browsed sent_history,
# reset to real value
self.sent_history_pos = max_size
else:
self.sent_history.append(message)
self.sent_history_pos = size + 1