changeset 3006:ba9aaf7d6cd0

quick frontends (app): setSpecial is now called before getOrCreateWidget in mucRoomJoinedHandler: this avoid a issue in Primitivus where the contact list selection is done before the room is actually added to the contact list.
author Goffi <goffi@goffi.org>
date Sun, 14 Jul 2019 21:19:47 +0200
parents 595b8857538b
children 420897488080
files sat_frontends/quick_frontend/quick_app.py
diffstat 1 files changed, 1 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/sat_frontends/quick_frontend/quick_app.py	Sun Jul 14 20:42:14 2019 +0200
+++ b/sat_frontends/quick_frontend/quick_app.py	Sun Jul 14 21:19:47 2019 +0200
@@ -862,6 +862,7 @@
             )
         )
         room_jid = jid.JID(room_jid_s)
+        self.contact_lists[profile].setSpecial(room_jid, C.CONTACT_SPECIAL_GROUP)
         self.widgets.getOrCreateWidget(
             quick_chat.QuickChat,
             room_jid,
@@ -871,8 +872,6 @@
             subject=subject,
             profile=profile,
         )
-        self.contact_lists[profile].setSpecial(room_jid, C.CONTACT_SPECIAL_GROUP)
-        # chat_widget.update()
 
     def mucRoomLeftHandler(self, room_jid_s, profile):
         """Called when a MUC room is left"""