diff options
author | jstebbins <[email protected]> | 2012-09-27 23:54:46 +0000 |
---|---|---|
committer | jstebbins <[email protected]> | 2012-09-27 23:54:46 +0000 |
commit | e60ee5a27cd80c40712c0965d1175bf55ce86412 (patch) | |
tree | c63b0cdb24555b66666f7f5eb10479e2f0880b10 /gtk/src/icons.c | |
parent | fd28fdf271be189b5ff44ddbbf1974f990e18da6 (diff) |
Lingui: update hb icon. Fix icon in notification bubble on fedora.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4991 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'gtk/src/icons.c')
-rw-r--r-- | gtk/src/icons.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/gtk/src/icons.c b/gtk/src/icons.c index a99deba03..042525592 100644 --- a/gtk/src/icons.c +++ b/gtk/src/icons.c @@ -7,7 +7,7 @@ void ghb_load_icons() { GHashTableIter iter; - gchar *name; + gchar *key; GValue *gval; GValue *icons = ghb_resource_get("icons"); @@ -15,13 +15,19 @@ ghb_load_icons() // middle (void*) cast prevents gcc warning "defreferencing type-punned // pointer will break strict-aliasing rules" while (g_hash_table_iter_next( - &iter, (gpointer*)(void*)&name, (gpointer*)(void*)&gval)) + &iter, (gpointer*)(void*)&key, (gpointer*)(void*)&gval)) { gint colorspace, bps, width, height, rowstride; gboolean alpha; ghb_rawdata_t *rd; gint size; GdkPixbuf *pb; + char *name = g_strdup(key); + char *pos; + + pos = g_strstr_len(name, -1, "."); + if (pos != NULL) + *pos = '\0'; colorspace = ghb_value_int(ghb_dict_lookup(gval, "colorspace")); alpha = ghb_value_boolean(ghb_dict_lookup(gval, "alpha")); @@ -37,5 +43,6 @@ ghb_load_icons() size = gdk_pixbuf_get_height(pb); gtk_icon_theme_add_builtin_icon(name, size, pb); g_object_unref(pb); + g_free(name); } } |