summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoanna Hulboj <joanna.hulboj@isode.com>2017-05-08 15:30:15 (GMT)
committerKevin Smith <kevin.smith@isode.com>2017-05-10 10:09:22 (GMT)
commitb98dcbdecf60ebdd5df97c9af0323621ba70e9dd (patch)
tree4230510827803dca402a538802fbc5aacccc4196 /Swift/Controllers
parent1cb2bb760d6487764a9480c84cf2d2edc65ff564 (diff)
downloadswift-b98dcbdecf60ebdd5df97c9af0323621ba70e9dd.zip
swift-b98dcbdecf60ebdd5df97c9af0323621ba70e9dd.tar.bz2
Fix for chat not being set correctly as impromptu chat
Test-Information: Open Swift app, from Recent Chat List click on entry that was created from offline invitees. New chat window will be opened and the chat message will be e.g. "You have joined the chat as test.". Change-Id: I54bdd019aac4274bed2a213b2679e5aeca7bd5fb
Diffstat (limited to 'Swift/Controllers')
-rw-r--r--Swift/Controllers/Chat/ChatsManager.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/Swift/Controllers/Chat/ChatsManager.cpp b/Swift/Controllers/Chat/ChatsManager.cpp
index d9f80ba..190ca8b 100644
--- a/Swift/Controllers/Chat/ChatsManager.cpp
+++ b/Swift/Controllers/Chat/ChatsManager.cpp
@@ -1063,8 +1063,9 @@ void ChatsManager::handleRecentActivated(const ChatListWindow::Chat& chat) {
uiEventStream_->send(std::make_shared<CreateImpromptuMUCUIEvent>(inviteJIDs, chat.jid, ""));
}
else if (chat.isMUC) {
+ bool isImpromptu = (!chat.inviteesNames.empty() || !chat.impromptuJIDs.empty());
/* FIXME: This means that recents requiring passwords will just flat-out not work */
- uiEventStream_->send(std::make_shared<JoinMUCUIEvent>(chat.jid, boost::optional<std::string>(), chat.nick));
+ uiEventStream_->send(std::make_shared<JoinMUCUIEvent>(chat.jid, boost::optional<std::string>(), chat.nick, false, false, isImpromptu));
}
else {
uiEventStream_->send(std::make_shared<RequestChatUIEvent>(chat.jid));