unbreak command auto-completion (was broken since
r0b92341adb6a - 52 commits ago)
--- a/QTfrontend/ui/widget/chatwidget.cpp Mon Oct 24 10:30:47 2011 +0200
+++ b/QTfrontend/ui/widget/chatwidget.cpp Mon Oct 24 10:59:52 2011 +0200
@@ -251,9 +251,6 @@
mainLayout.setColumnStretch(1, 24);
chatEditLine = new SmartLineEdit(this);
- QStringList cmds;
- cmds << "/me" << "/discardStyleSheet" << "/saveStyleSheet";
- chatEditLine->addCommands(cmds);
chatEditLine->setMaxLength(300);
connect(chatEditLine, SIGNAL(returnPressed()), this, SLOT(returnPressed()));
@@ -585,6 +582,12 @@
void HWChatWidget::clear()
{
chatEditLine->reset();
+
+ // add default commands
+ QStringList cmds;
+ cmds << "/me" << "/discardStyleSheet" << "/saveStyleSheet";
+ chatEditLine->addCommands(cmds);
+
chatText->clear();
chatStrings.clear();
chatNicks->clear();