Philipp Hörist pushed to branch mainwindow at gajim / gajim


Commits:
9c66534e by lovetox at 2021-04-28T10:39:02+02:00
Simplify init

- - - - -


2 changed files:

- gajim/gtk/chat_list_stack.py
- gajim/gtk/chat_page.py


Changes:

=====================================
gajim/gtk/chat_list_stack.py
=====================================
@@ -49,7 +49,7 @@ class ChatListStack(Gtk.Stack):
                          (str, str, str)),
     }
 
-    def __init__(self, main_window, search_entry):
+    def __init__(self, search_entry):
         Gtk.Stack.__init__(self)
         self.set_hexpand(True)
         self.set_vexpand(True)
@@ -63,7 +63,7 @@ def __init__(self, main_window, search_entry):
 
         self.connect('notify::visible-child-name', self._on_visible_child_name)
         search_entry.connect('search-changed', self._on_search_changed)
-        main_window.connect('notify::is-active', self._on_window_active)
+        app.window.connect('notify::is-active', self._on_window_active)
 
         self._add_actions()
         self.show_all()


=====================================
gajim/gtk/chat_page.py
=====================================
@@ -59,7 +59,7 @@ def __init__(self):
         self._search_revealer.add(self._search_view)
         self._ui.right_grid_overlay.add_overlay(self._search_revealer)
 
-        self._chat_list_stack = ChatListStack(app.window, 
self._ui.search_entry)
+        self._chat_list_stack = ChatListStack(self._ui.search_entry)
         self._chat_list_stack.connect('chat-selected', self._on_chat_selected)
         self._chat_list_stack.connect('chat-unselected',
                                       self._on_chat_unselected)



View it on GitLab: 
https://dev.gajim.org/gajim/gajim/-/commit/9c66534ef6dea56b1dca03264f71bc17b42375e9

-- 
View it on GitLab: 
https://dev.gajim.org/gajim/gajim/-/commit/9c66534ef6dea56b1dca03264f71bc17b42375e9
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

Reply via email to