diff options
-rw-r--r-- | libappstream-glib/as-app.c | 2 | ||||
-rw-r--r-- | libappstream-glib/as-icon-private.h | 3 | ||||
-rw-r--r-- | libappstream-glib/as-icon.c | 7 |
3 files changed, 11 insertions, 1 deletions
diff --git a/libappstream-glib/as-app.c b/libappstream-glib/as-app.c index 49f3e30..43a0008 100644 --- a/libappstream-glib/as-app.c +++ b/libappstream-glib/as-app.c @@ -5020,7 +5020,7 @@ as_app_node_parse_child (AsApp *app, GNode *n, guint32 flags, { g_autoptr(AsIcon) ic = NULL; ic = as_icon_new (); - as_icon_set_prefix (ic, priv->icon_path); + as_icon_set_prefix_rstr (ic, priv->icon_path); if (!as_icon_node_parse (ic, n, ctx, error)) return FALSE; as_app_add_icon (app, ic); diff --git a/libappstream-glib/as-icon-private.h b/libappstream-glib/as-icon-private.h index 0c7af74..df6f891 100644 --- a/libappstream-glib/as-icon-private.h +++ b/libappstream-glib/as-icon-private.h @@ -47,6 +47,9 @@ gboolean as_icon_node_parse_dep11 (AsIcon *icon, AsNodeContext *ctx, GError **error); +void as_icon_set_prefix_rstr (AsIcon *icon, + AsRefString *rstr); + G_END_DECLS #endif /* __AS_ICON_PRIVATE_H */ diff --git a/libappstream-glib/as-icon.c b/libappstream-glib/as-icon.c index 8a13ae0..ae15dc4 100644 --- a/libappstream-glib/as-icon.c +++ b/libappstream-glib/as-icon.c @@ -363,6 +363,13 @@ as_icon_set_prefix (AsIcon *icon, const gchar *prefix) as_ref_string_assign_safe (&priv->prefix, prefix); } +void +as_icon_set_prefix_rstr (AsIcon *icon, AsRefString *rstr) +{ + AsIconPrivate *priv = GET_PRIVATE (icon); + as_ref_string_assign (&priv->prefix, rstr); +} + /** * as_icon_set_url: * @icon: a #AsIcon instance. |