summaryrefslogtreecommitdiff
path: root/gi/_gtktemplate.py
diff options
context:
space:
mode:
authorKai Willadsen <kai.willadsen@gmail.com>2018-07-07 07:24:39 +1000
committerKai Willadsen <kai.willadsen@gmail.com>2018-07-07 07:24:39 +1000
commit05c3b8dc91f5d51bd30bbe58963a4454b447b707 (patch)
tree00712ffab91f7fd94becac5151520250f0eea1af /gi/_gtktemplate.py
parent855e4199390bfa8ea2a07f2d6ecdbe75faa3a5ac (diff)
downloadpygobject-05c3b8dc91f5d51bd30bbe58963a4454b447b707.tar.gz
Gtk.Template: Remove init_template() from instance, not class
Without this change, the second instantiation of any templated class will fail to run any of the actual template-handling logic. This is *only* relevant when using the _gtk_template helpers with an older PyGObject; in newer versions, this method isn't called.
Diffstat (limited to 'gi/_gtktemplate.py')
-rw-r--r--gi/_gtktemplate.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/gi/_gtktemplate.py b/gi/_gtktemplate.py
index df9afdbd..a345f5d2 100644
--- a/gi/_gtktemplate.py
+++ b/gi/_gtktemplate.py
@@ -99,7 +99,7 @@ def register_template(cls):
def init_template(self, cls, base_init_template):
- cls.init_template = lambda s: None
+ self.init_template = lambda s: None
if self.__class__ is not cls:
raise TypeError(