summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTobias Markmann <tm@ayena.de>2012-04-26 22:09:25 (GMT)
committerKevin Smith <git@kismith.co.uk>2012-04-27 13:18:12 (GMT)
commit68d9f9aa02e227355e0fc032f922853b36143f4a (patch)
treeb44805e8f2980ca288c938875f3d468d4e349687 /Swift/QtUI
parent3cb4abb7840b473899b6f872da1b0be87036554b (diff)
downloadswift-68d9f9aa02e227355e0fc032f922853b36143f4a.zip
swift-68d9f9aa02e227355e0fc032f922853b36143f4a.tar.bz2
Mark corrected MUC messages as read on active chat.
Resolves: #943 License: This patch is BSD-licensed, see http://www.opensource.org/licenses/bsd-license.php
Diffstat (limited to 'Swift/QtUI')
-rw-r--r--Swift/QtUI/QtChatWindow.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/Swift/QtUI/QtChatWindow.cpp b/Swift/QtUI/QtChatWindow.cpp
index 57f7c15..ed134aa 100644
--- a/Swift/QtUI/QtChatWindow.cpp
+++ b/Swift/QtUI/QtChatWindow.cpp
@@ -670,6 +670,10 @@ void QtChatWindow::replaceMessage(const std::string& message, const std::string&
void QtChatWindow::replaceMessage(const std::string& message, const std::string& id, const boost::posix_time::ptime& time, const QString& style) {
if (!id.empty()) {
+ if (isWidgetSelected()) {
+ onAllMessagesRead();
+ }
+
QString messageHTML(Qt::escape(P2QSTRING(message)));
messageHTML = P2QSTRING(Linkify::linkify(Q2PSTRING(messageHTML)));
messageHTML.replace("\n","<br/>");