Include current nick for highlight checking if "All nicks" is chosen
[quassel.git] / src / qtui / qtuimessageprocessor.cpp
index 2466e15..353928a 100644 (file)
@@ -115,6 +115,8 @@ void QtUiMessageProcessor::checkForHighlight(Message &msg) {
       const Identity *myIdentity = Client::identity(net->identity());
       if(myIdentity)
         nickList = myIdentity->nicks();
       const Identity *myIdentity = Client::identity(net->identity());
       if(myIdentity)
         nickList = myIdentity->nicks();
+      if(!nickList.contains(net->myNick()))
+        nickList.prepend(net->myNick());
     }
     foreach(QString nickname, nickList) {
       QRegExp nickRegExp("\\b" + QRegExp::escape(nickname) + "(\\W|\\b|$)", // + "\\b", this does not seem to work for trailing ` -> upstream bug?
     }
     foreach(QString nickname, nickList) {
       QRegExp nickRegExp("\\b" + QRegExp::escape(nickname) + "(\\W|\\b|$)", // + "\\b", this does not seem to work for trailing ` -> upstream bug?