Add a tooltip when messages are in WONTSEND state (#550)

The warning sign and red color, while obviously synonymous with a
problem, are still a bit perplexing for the user.

This change add a bit of clarity.

It would obviously be better to get exact cause of the problem from the
different plugins. Maybe it would be possible to add a field to the
Message class from libdino/src/entity/message.vala in order to record an
error message for every case.
This commit is contained in:
Aearil 2020-02-21 18:22:27 +01:00 committed by fiaxh
parent 78ef31dcf5
commit ed71f61422
2 changed files with 8 additions and 0 deletions

View file

@ -202,6 +202,10 @@ msgstr "%d %b"
msgid "Yesterday"
msgstr "Hier"
#: main/src/ui/conversation_summary/conversation_item_skeleton.vala:144
msgid "Unable to send message"
msgstr "Impossible d'envoyer le message"
#: main/src/ui/conversation_selector/conversation_selector_row.vala:265
#: main/src/ui/conversation_summary/conversation_item_skeleton.vala:205
#, no-c-format

View file

@ -150,6 +150,10 @@ public class ItemMetaDataHeader : Box {
Util.force_error_color(received_image);
Util.force_error_color(encryption_image);
Util.force_error_color(time_label);
string error_text = _("Unable to send message");
received_image.tooltip_text = error_text;
encryption_image.tooltip_text = error_text;
time_label.tooltip_text = error_text;
return;
} else if (item.mark != Message.Marked.READ) {
all_read = false;