aboutsummaryrefslogtreecommitdiff
path: root/main/src/ui/conversation_selector
diff options
context:
space:
mode:
authorcodedust <codedust@users.noreply.github.com>2018-08-20 02:59:58 +0200
committerfiaxh <git@mx.ax.lt>2018-11-02 15:14:35 +0100
commit1e54a442ba78cd117c0262b9b5e83ef4438e5858 (patch)
tree025be91fe62a1284ac911a7919792afe2bce1ea2 /main/src/ui/conversation_selector
parent4ad07fea47e9e3463e864673b9c601b304b05270 (diff)
downloaddino-1e54a442ba78cd117c0262b9b5e83ef4438e5858.tar.gz
dino-1e54a442ba78cd117c0262b9b5e83ef4438e5858.zip
Display room name in conversation selector and conversation titlebar
Diffstat (limited to 'main/src/ui/conversation_selector')
-rw-r--r--main/src/ui/conversation_selector/conversation_row.vala2
-rw-r--r--main/src/ui/conversation_selector/groupchat_row.vala6
2 files changed, 7 insertions, 1 deletions
diff --git a/main/src/ui/conversation_selector/conversation_row.vala b/main/src/ui/conversation_selector/conversation_row.vala
index d79b840b..ea0aeeb4 100644
--- a/main/src/ui/conversation_selector/conversation_row.vala
+++ b/main/src/ui/conversation_selector/conversation_row.vala
@@ -61,7 +61,7 @@ public abstract class ConversationRow : ListBoxRow {
update_read();
}
- protected void update_name_label(string? new_name = null) {
+ protected void update_name_label() {
name_label.label = Util.get_conversation_display_name(stream_interactor, conversation);
}
diff --git a/main/src/ui/conversation_selector/groupchat_row.vala b/main/src/ui/conversation_selector/groupchat_row.vala
index fdbfa40b..70b24dfd 100644
--- a/main/src/ui/conversation_selector/groupchat_row.vala
+++ b/main/src/ui/conversation_selector/groupchat_row.vala
@@ -12,6 +12,12 @@ public class GroupchatRow : ConversationRow {
closed.connect(() => {
stream_interactor.get_module(MucManager.IDENTITY).part(conversation.account, conversation.counterpart);
});
+
+ stream_interactor.get_module(MucManager.IDENTITY).room_name_set.connect((account, jid, room_name) => {
+ if (conversation != null && conversation.counterpart.equals_bare(jid) && conversation.account.equals(account)) {
+ update_name_label();
+ }
+ });
}
protected override void update_message_label() {