[meld/deprecation-cleanup: 26/48] meldwindow: Move realize signal handling to vfunc override
- From: Kai Willadsen <kaiw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [meld/deprecation-cleanup: 26/48] meldwindow: Move realize signal handling to vfunc override
- Date: Sun, 2 Dec 2018 02:44:19 +0000 (UTC)
commit 3693f94c9c62eebd3616b2f489ca193a510ef111
Author: Kai Willadsen <kai willadsen gmail com>
Date: Sat Dec 1 07:57:40 2018 +1000
meldwindow: Move realize signal handling to vfunc override
meld/meldwindow.py | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/meld/meldwindow.py b/meld/meldwindow.py
index 6706042f..40da2b96 100644
--- a/meld/meldwindow.py
+++ b/meld/meldwindow.py
@@ -226,7 +226,6 @@ class MeldWindow(Gtk.ApplicationWindow):
self.ui.ensure_update()
self.diff_handler = None
self.undo_handlers = tuple()
- self.connect('realize', self.on_realize)
self.connect('focus_in_event', self.on_focus_change)
self.connect('focus_out_event', self.on_focus_change)
@@ -238,10 +237,11 @@ class MeldWindow(Gtk.ApplicationWindow):
shortcut_window = builder.get_object("shortcuts-meld")
self.set_help_overlay(shortcut_window)
- def on_realize(self, user_data):
- # FIXME: Ideally this would be in do_realize, and we'd get the menu
- # from resources, but MeldWindow would need to be a real GtkWindow
- # subclass, and we'd need to... have resources.
+ def do_realize(self):
+ Gtk.ApplicationWindow.do_realize(self)
+
+ # FIXME: Ideally we'd get the menu from resources, but we'd need to...
+ # have resources.
builder = meld.ui.util.get_builder("application.ui")
menu = builder.get_object("gear-menu")
self.gear_menu_button.set_popover(
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]