diff options
Diffstat (limited to 'Swift/Controllers/UnitTest/MockChatWindow.h')
-rw-r--r-- | Swift/Controllers/UnitTest/MockChatWindow.h | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/Swift/Controllers/UnitTest/MockChatWindow.h b/Swift/Controllers/UnitTest/MockChatWindow.h index 7682781..389d787 100644 --- a/Swift/Controllers/UnitTest/MockChatWindow.h +++ b/Swift/Controllers/UnitTest/MockChatWindow.h @@ -17,10 +17,11 @@ namespace Swift { MockChatWindow() {} virtual ~MockChatWindow(); - virtual std::string addMessage(const ChatMessage& message, const std::string& senderName, bool senderIsSelf, std::shared_ptr<SecurityLabel> /*label*/, const std::string& /*avatarPath*/, const boost::posix_time::ptime& /*time*/) { + virtual std::string addMessage(const ChatMessage& message, const std::string& senderName, bool senderIsSelf, std::shared_ptr<SecurityLabel> label, const std::string& /*avatarPath*/, const boost::posix_time::ptime& /*time*/) { lastAddedMessage_ = message; lastAddedMessageSenderName_ = senderName; lastAddedMessageSenderIsSelf_ = senderIsSelf; + lastAddedMessageSecurityLabel_ = label; return "id"; } @@ -133,10 +134,19 @@ namespace Swift { lastAddedMessageSenderIsSelf_ = lastAddedActionSenderIsSelf_ = false; } + void setChatSecurityMarking(const std::string& markingValue, const std::string& markingForegroundColorValue, const std::string& markingBackgroundColorValue) { + markingValue_ = markingValue; + markingForegroundColorValue_ = markingForegroundColorValue; + markingBackgroundColorValue_ = markingBackgroundColorValue; + } + + void removeChatSecurityMarking() {} + std::string name_; ChatMessage lastAddedMessage_; std::string lastAddedMessageSenderName_; bool lastAddedMessageSenderIsSelf_ = false; + std::shared_ptr<SecurityLabel> lastAddedMessageSecurityLabel_ = nullptr; ChatMessage lastAddedAction_; std::string lastAddedActionSenderName_; bool lastAddedActionSenderIsSelf_ = false; @@ -154,6 +164,9 @@ namespace Swift { Roster* roster_ = nullptr; std::vector<std::pair<std::string, ReceiptState>> receiptChanges_; boost::optional<MUCType> mucType_; + std::string markingValue_; + std::string markingForegroundColorValue_; + std::string markingBackgroundColorValue_; }; } |