summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVlad Voicu <vladvoic@gmail.com>2011-06-13 11:03:08 (GMT)
committerRemko Tronçon <git@el-tramo.be>2011-06-13 12:34:08 (GMT)
commit643999af94c4fede5e1348da91ad539235b9d60f (patch)
treea0b0022eeca66542344ee4c153f0f860df76be61 /Swift/Controllers
parent7928fe52faf92a7c2cbe5046c48cea3e0d7f95e6 (diff)
downloadswift-643999af94c4fede5e1348da91ad539235b9d60f.zip
swift-643999af94c4fede5e1348da91ad539235b9d60f.tar.bz2
Small fix for replace message feature
License: This patch is BSD-licensed, see http://www.opensource.org/licenses/bsd-license.php
Diffstat (limited to 'Swift/Controllers')
-rw-r--r--Swift/Controllers/Chat/ChatController.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/Swift/Controllers/Chat/ChatController.cpp b/Swift/Controllers/Chat/ChatController.cpp
index ab273a2..a735ed9 100644
--- a/Swift/Controllers/Chat/ChatController.cpp
+++ b/Swift/Controllers/Chat/ChatController.cpp
@@ -120,6 +120,7 @@ void ChatController::postSendMessage(const std::string& body, boost::shared_ptr<
boost::shared_ptr<Replace> replace = sentStanza->getPayload<Replace>();
if (replace) {
eraseIf(unackedStanzas_, PairSecondEquals<boost::shared_ptr<Stanza>, std::string>(myLastMessageUIID_));
+ chatWindow_->replaceMessage(body, myLastMessageUIID_, boost::posix_time::microsec_clock::universal_time());
} else {
myLastMessageUIID_ = addMessage(body, QT_TRANSLATE_NOOP("", "me"), true, labelsEnabled_ ? chatWindow_->getSelectedSecurityLabel().getLabel() : boost::shared_ptr<SecurityLabel>(), std::string(avatarManager_->getAvatarPath(selfJID_).string()), boost::posix_time::microsec_clock::universal_time());
}