diff options
author | Tobias Markmann <tm@ayena.de> | 2016-06-10 10:59:04 (GMT) |
---|---|---|
committer | Kevin Smith <kevin.smith@isode.com> | 2016-07-01 12:18:48 (GMT) |
commit | b16a2d1483f59ad93a2171c6c286e12f4ebbf3be (patch) | |
tree | f49c9ba36649797070a84955423e4611dae7dd8a /Swift/Controllers/Chat/ChatsManager.h | |
parent | a1be6105b97dddc1e03db0075f6ca3fc47fa8e1d (diff) | |
download | swift-b16a2d1483f59ad93a2171c6c286e12f4ebbf3be.zip swift-b16a2d1483f59ad93a2171c6c286e12f4ebbf3be.tar.bz2 |
Implement Message Carbons in Swift and Swift/Controllers
If the server supports message carbons, Swift will try to
enable it.
Carbon copied messages will open a chat window in the
background if no chat window exists for the conversation.
Test-Information:
Tested with a XMPP server Swift and a mobile Android client
all supporting message carbons. Tested direct messages
and MUC PM messages. All working as expected.
Added unit tests for message carbons of sent messages and
message carbons of received messages.
All unit tests pass on OS X 10.11.5
Change-Id: I8d5b5d9975651a2353909dea976f58e4bf12e014
Diffstat (limited to 'Swift/Controllers/Chat/ChatsManager.h')
-rw-r--r-- | Swift/Controllers/Chat/ChatsManager.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Swift/Controllers/Chat/ChatsManager.h b/Swift/Controllers/Chat/ChatsManager.h index da85949..593624d 100644 --- a/Swift/Controllers/Chat/ChatsManager.h +++ b/Swift/Controllers/Chat/ChatsManager.h @@ -67,7 +67,7 @@ namespace Swift { void setAvatarManager(AvatarManager* avatarManager); void setOnline(bool enabled); void setServerDiscoInfo(std::shared_ptr<DiscoInfo> info); - void handleIncomingMessage(std::shared_ptr<Message> message); + void handleIncomingMessage(std::shared_ptr<Message> incomingMessage); std::vector<ChatListWindow::Chat> getRecentChats() const; virtual std::vector<Contact::ref> getContacts(bool withMUCNicks); @@ -105,6 +105,7 @@ namespace Swift { void handleWhiteboardSessionRequest(const JID& contact, bool senderIsSelf); void handleWhiteboardStateChange(const JID& contact, const ChatWindow::WhiteboardSessionState state); boost::optional<ChatListWindow::Chat> removeExistingChat(const ChatListWindow::Chat& chat); + bool messageCausesSessionBinding(std::shared_ptr<Message> message); void cleanupPrivateMessageRecents(); void appendRecent(const ChatListWindow::Chat& chat); void prependRecent(const ChatListWindow::Chat& chat); |