adds ingame-chat nick-highlighting
This commit is contained in:
@@ -28,7 +28,7 @@ using namespace std;
|
||||
|
||||
Chat::Chat(mainWindowImpl* w, ConfigFile *c) : myW(w), myConfig(c)
|
||||
{
|
||||
myChatTools = new ChatTools(myW->lineEdit_ChatInput, myConfig);
|
||||
myChatTools = new ChatTools(myW->lineEdit_ChatInput, myConfig, 2, myW->textBrowser_Chat);
|
||||
|
||||
}
|
||||
|
||||
@@ -47,7 +47,7 @@ void Chat::sendMessage() {
|
||||
|
||||
void Chat::receiveMessage(QString playerName, QString message) {
|
||||
|
||||
myW->textBrowser_Chat->append(playerName + ": " + message);
|
||||
myChatTools->receiveMessage(playerName, message);
|
||||
checkInvisible();
|
||||
}
|
||||
|
||||
|
||||
@@ -3678,7 +3678,7 @@ bool mainWindowImpl::eventFilter(QObject *obj, QEvent *event)
|
||||
{
|
||||
QKeyEvent *keyEvent = static_cast<QKeyEvent*>(event);
|
||||
|
||||
if (obj == lineEdit_ChatInput && lineEdit_ChatInput->text() != "" && event->type() == QEvent::KeyPress && keyEvent->key() == Qt::Key_Tab)
|
||||
if (/*obj == lineEdit_ChatInput && lineEdit_ChatInput->text() != "" && */event->type() == QEvent::KeyPress && keyEvent->key() == Qt::Key_Tab)
|
||||
{
|
||||
myChat->nickAutoCompletition();
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user