summaryrefslogtreecommitdiff
path: root/src/terminal-util.c
diff options
context:
space:
mode:
authorrbuj <[email protected]>2019-02-22 12:02:30 +0100
committerraveit65 <[email protected]>2019-04-23 11:59:07 +0200
commitde1be0a956d49a82b67ec92741899fea7da60e3a (patch)
treeb73669266033a90ce39789f922ca90343138eaba /src/terminal-util.c
parent0aa5954350341dca1d262915b956b3bc2ee7577d (diff)
downloadmate-terminal-de1be0a956d49a82b67ec92741899fea7da60e3a.tar.bz2
mate-terminal-de1be0a956d49a82b67ec92741899fea7da60e3a.tar.xz
Use gresources for about_DATA, uimanager_DATA & builder_DATA
Diffstat (limited to 'src/terminal-util.c')
-rw-r--r--src/terminal-util.c15
1 files changed, 3 insertions, 12 deletions
diff --git a/src/terminal-util.c b/src/terminal-util.c
index 3c7cb3b..1ffb629 100644
--- a/src/terminal-util.c
+++ b/src/terminal-util.c
@@ -339,26 +339,17 @@ terminal_util_get_licence_text (void)
}
gboolean
-terminal_util_load_builder_file (const char *filename,
+terminal_util_load_builder_resource (const char *path,
const char *object_name,
...)
{
- char *path;
GtkBuilder *builder;
GError *error = NULL;
va_list args;
- path = g_build_filename (TERM_PKGDATADIR, filename, NULL);
builder = gtk_builder_new ();
- if (!gtk_builder_add_from_file (builder, path, &error))
- {
- g_warning ("Failed to load %s: %s\n", filename, error->message);
- g_error_free (error);
- g_free (path);
- g_object_unref (builder);
- return FALSE;
- }
- g_free (path);
+ gtk_builder_add_from_resource (builder, path, &error);
+ g_assert_no_error (error);
va_start (args, object_name);