summaryrefslogtreecommitdiff
path: root/components
diff options
context:
space:
mode:
authorouwou <26526779+ouwou@users.noreply.github.com>2021-01-17 23:24:44 -0500
committerouwou <26526779+ouwou@users.noreply.github.com>2021-01-17 23:24:44 -0500
commit4fd7f9d75e4edd42f559fc8653f8f82bf275e865 (patch)
treee0c9c1c2b7d2002d48bc094601424f3729db59b7 /components
parent744e42892d3da3247df4e04f0d97e93e6d50799a (diff)
downloadabaddon-portaudio-4fd7f9d75e4edd42f559fc8653f8f82bf275e865.tar.gz
abaddon-portaudio-4fd7f9d75e4edd42f559fc8653f8f82bf275e865.zip
put tooltips on reactions
Diffstat (limited to 'components')
-rw-r--r--components/chatmessage.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/components/chatmessage.cpp b/components/chatmessage.cpp
index 0981448..99926fb 100644
--- a/components/chatmessage.cpp
+++ b/components/chatmessage.cpp
@@ -475,6 +475,10 @@ Gtk::Widget *ChatMessageItemContainer::CreateReactionsComponent(const Message &d
// image
if (is_stock) { // unicode/stock
+ const auto shortcode = emojis.GetShortCodeForPattern(reaction.Emoji.Name);
+ if (shortcode != "")
+ ev->set_tooltip_text(shortcode);
+
const auto &pb = emojis.GetPixBuf(reaction.Emoji.Name);
Gtk::Image *img;
if (pb)
@@ -484,6 +488,8 @@ Gtk::Widget *ChatMessageItemContainer::CreateReactionsComponent(const Message &d
img->set_can_focus(false);
box->add(*img);
} else { // custom
+ ev->set_tooltip_text(reaction.Emoji.Name);
+
auto img = Gtk::manage(new LazyImage(reaction.Emoji.GetURL(), 16, 16));
img->set_can_focus(false);
box->add(*img);