summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorouwou <26526779+ouwou@users.noreply.github.com>2021-04-24 04:23:28 -0400
committerouwou <26526779+ouwou@users.noreply.github.com>2021-04-24 04:23:28 -0400
commit3deb2b10020529ac36cf7ab298e0be425887c88f (patch)
tree830aef6c51d3bc523ca196a470b43673d2e2efd8
parenta120cbda2cf0a247d5189e12d93c0c4c40503910 (diff)
downloadabaddon-portaudio-3deb2b10020529ac36cf7ab298e0be425887c88f.tar.gz
abaddon-portaudio-3deb2b10020529ac36cf7ab298e0be425887c88f.zip
basic handling of CALL messages
-rw-r--r--components/chatmessage.cpp3
-rw-r--r--discord/message.hpp2
2 files changed, 4 insertions, 1 deletions
diff --git a/components/chatmessage.cpp b/components/chatmessage.cpp
index 4d38806..03398dd 100644
--- a/components/chatmessage.cpp
+++ b/components/chatmessage.cpp
@@ -274,6 +274,9 @@ void ChatMessageItemContainer::UpdateTextComponent(Gtk::TextView *tv) {
const auto author = Abaddon::Get().GetDiscordClient().GetUser(data->Author.ID);
b->insert_markup(s, "<i><span color='#999999'>" + author->GetEscapedBoldName() + " has added <b>" + Glib::Markup::escape_text(data->Content) + "</b> to this channel. Its most important updates will show up here.</span></i>");
} break;
+ case MessageType::CALL: {
+ b->insert_markup(s, "<span color='#999999'><i>[started a call]</i></span>");
+ } break;
default: break;
}
}
diff --git a/discord/message.hpp b/discord/message.hpp
index 66d0afd..baf147e 100644
--- a/discord/message.hpp
+++ b/discord/message.hpp
@@ -13,7 +13,7 @@ enum class MessageType {
DEFAULT = 0, // yep
RECIPIENT_ADD = 1, // yep
RECIPIENT_REMOVE = 2, // yep
- CALL = 3, // nope
+ CALL = 3, // yep (sorta)
CHANNEL_NAME_CHANGE = 4, // yep
CHANNEL_ICON_CHANGE = 5, // yep
CHANNEL_PINNED_MESSAGE = 6, // yep