summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonas Danielsson <jonas.danielsson@threetimestwo.org>2014-11-06 09:17:53 -0500
committerJonas Danielsson <jonas.danielsson@threetimestwo.org>2014-11-17 01:17:33 -0500
commit5c84dc06e38a5ef4c3b58978e1e1f973b99f0049 (patch)
tree88a4fa4e67edd8995d04c630edf4a0db083e9358
parent40ff788fc16fd1f61ddf958289ecfa8c1ffcc011 (diff)
downloadgjs-5c84dc06e38a5ef4c3b58978e1e1f973b99f0049.tar.gz
Gtk: Scrub resource:// prefix for template path
Gtk.Widget.bind_template_child_full expects an absolute path to the resource. We need to scrub the resource:// part of the template string. https://bugzilla.gnome.org/show_bug.cgi?id=739739
-rw-r--r--modules/overrides/Gtk.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/overrides/Gtk.js b/modules/overrides/Gtk.js
index 9b7d8910..8a239770 100644
--- a/modules/overrides/Gtk.js
+++ b/modules/overrides/Gtk.js
@@ -51,7 +51,7 @@ const GtkWidgetClass = new Lang.Class({
if (template) {
if (typeof template == 'string' &&
template.startsWith('resource:///'))
- Gtk.Widget.set_template_from_resource.call(this, template);
+ Gtk.Widget.set_template_from_resource.call(this, template.slice(11));
else
Gtk.Widget.set_template.call(this, template);
}