Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Evangelos Ribeiro Tzaras
chatty
Commits
44713162
Commit
44713162
authored
Jul 20, 2021
by
Mohammed Sadiq
Browse files
pp-chat-info: Disconnect signal callback before changing chat
parent
6f89a494
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/dialogs/chatty-pp-chat-info.c
View file @
44713162
...
...
@@ -415,6 +415,11 @@ chatty_pp_chat_info_set_item (ChattyPpChatInfo *self,
g_return_if_fail
(
CHATTY_IS_PP_CHAT_INFO
(
self
));
g_return_if_fail
(
!
chat
||
CHATTY_IS_CHAT
(
chat
));
if
(
self
->
chat
)
g_signal_handlers_disconnect_by_func
(
self
->
chat
,
pp_chat_info_encrypt_changed_cb
,
self
);
if
(
!
g_set_object
(
&
self
->
chat
,
chat
))
return
;
...
...
@@ -425,10 +430,5 @@ chatty_pp_chat_info_set_item (ChattyPpChatInfo *self,
gtk_container_foreach
(
GTK_CONTAINER
(
self
->
key_list
),
(
GtkCallback
)
gtk_widget_destroy
,
NULL
);
if
(
self
->
chat
)
g_signal_handlers_disconnect_by_func
(
self
->
chat
,
pp_chat_info_encrypt_changed_cb
,
self
);
chatty_pp_chat_info_update
(
self
);
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment