mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
clear previous id on action (issue #7)
This commit is contained in:
parent
2dc79a80bc
commit
624b73edc7
|
@ -212,12 +212,15 @@ ChatMessage::Ptr GenericChatForm::addMessage(const ToxID& author, const QString
|
|||
if(isAction)
|
||||
{
|
||||
msg = ChatMessage::createChatMessage(authorStr, message, true, false, false);
|
||||
previousId.clear();
|
||||
}
|
||||
else
|
||||
{
|
||||
msg = ChatMessage::createChatMessage(authorStr, message, false, false, author.isMine());
|
||||
if(author == previousId)
|
||||
msg->hideSender();
|
||||
|
||||
previousId = author;
|
||||
}
|
||||
|
||||
insertChatMessage(msg);
|
||||
|
@ -225,8 +228,6 @@ ChatMessage::Ptr GenericChatForm::addMessage(const ToxID& author, const QString
|
|||
if(isSent)
|
||||
msg->markAsSent(datetime);
|
||||
|
||||
previousId = author;
|
||||
|
||||
return msg;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user