add MESSAGE_DELETE handling

This commit is contained in:
ouwou
2020-08-29 01:14:07 -04:00
parent 4e7ae1af1d
commit 299ecc71d9
12 changed files with 73 additions and 0 deletions

View File

@@ -62,3 +62,10 @@ void ChatMessageTextItem::PrependNewContent(std::string content) {
auto buf = m_text->get_buffer();
buf->set_text(content + "\n" + buf->get_text());
}
void ChatMessageTextItem::MarkAsDeleted() {
auto buf = m_text->get_buffer();
Gtk::TextBuffer::iterator start, end;
buf->get_bounds(start, end);
buf->insert_markup(end, "<span color='#ff0000'> [deleted]</span>");
}