Fix: Text rendering causing crash because of notification being in a different thread

This commit is contained in:
jeffser 2024-09-29 16:07:12 -06:00
parent 56eac5ccd6
commit 0be0942da3
2 changed files with 2 additions and 0 deletions

View File

@ -451,6 +451,7 @@ class message(Gtk.Overlay):
chat.container.remove(chat.welcome_screen)
chat.welcome_screen = None
chat.stop_message()
self.text = self.content_children[-1].get_label()
GLib.idle_add(self.set_text, self.content_children[-1].get_label())
self.dt = datetime.datetime.now()
GLib.idle_add(self.add_footer, self.dt)

View File

@ -575,6 +575,7 @@ Generate a title following these rules:
if response.status_code != 200:
raise Exception('Network Error')
except Exception as e:
logger.error(e)
self.chat_list_box.get_tab_by_name(chat.get_name()).spinner.set_visible(False)
chat.busy = False
GLib.idle_add(message_element.add_action_buttons)