Daniel Brötzmann pushed to branch master at gajim / gajim
Commits:
9b44d769 by wurstsalat at 2023-05-28T22:39:27+02:00
cfix: Search: Restore group chat participants list to previous state when
closing search via Escape
Fixes #11536
- - - - -
1 changed file:
- gajim/gtk/chat_page.py
Changes:
=====================================
gajim/gtk/chat_page.py
=====================================
@@ -171,7 +171,8 @@ def _on_search_history(self,
self._chat_control.contact.jid)
if not app.settings.get('hide_groupchat_occupants_list'):
- # Hide group chat roster in order to make some space horizontally
+ # Hide group chat roster in order to make some space horizontally.
+ # Store state to be able to restore it when hiding search.
self._restore_occupants_list = True
app.settings.set('hide_groupchat_occupants_list', True)
@@ -179,11 +180,7 @@ def _on_search_history(self,
self._search_view.set_focus()
def _on_search_hide(self, *args: Any) -> None:
- if self._restore_occupants_list:
- app.settings.set('hide_groupchat_occupants_list', False)
- self._restore_occupants_list = False
-
- self._search_revealer.set_reveal_child(False)
+ self.hide_search()
def _on_chat_list_changed(self,
chat_list_stack: ChatListStack,
@@ -344,6 +341,11 @@ def get_control(self) -> ChatControl:
def hide_search(self) -> bool:
if self._search_revealer.get_reveal_child():
self._search_revealer.set_reveal_child(False)
+
+ if self._restore_occupants_list:
+ app.settings.set('hide_groupchat_occupants_list', False)
+ self._restore_occupants_list = False
+
return True
return False
View it on GitLab:
https://dev.gajim.org/gajim/gajim/-/commit/9b44d7693f3b478b6ed5bffd680f588f71aea59f
--
View it on GitLab:
https://dev.gajim.org/gajim/gajim/-/commit/9b44d7693f3b478b6ed5bffd680f588f71aea59f
You're receiving this email because of your account on dev.gajim.org.
_______________________________________________
Commits mailing list
[email protected]
https://lists.gajim.org/cgi-bin/listinfo/commits