Mercurial > pidgin
comparison src/gtkimhtml.c @ 12335:3726ff9022f3
[gaim-migrate @ 14639]
[ 1342462 ] [HEAD] Crash on some custom smilies
committer: Tailor Script <tailor@pidgin.im>
author | Tim Ringenbach <marv@pidgin.im> |
---|---|
date | Mon, 05 Dec 2005 02:56:55 +0000 |
parents | 868220a1a1b2 |
children | a88ca6da0b38 |
comparison
equal
deleted
inserted
replaced
12334:2823118073fa | 12335:3726ff9022f3 |
---|---|
1822 else if ((tree = g_hash_table_lookup(imhtml->smiley_data, sml))) { | 1822 else if ((tree = g_hash_table_lookup(imhtml->smiley_data, sml))) { |
1823 } else { | 1823 } else { |
1824 tree = gtk_smiley_tree_new(); | 1824 tree = gtk_smiley_tree_new(); |
1825 g_hash_table_insert(imhtml->smiley_data, g_strdup(sml), tree); | 1825 g_hash_table_insert(imhtml->smiley_data, g_strdup(sml), tree); |
1826 } | 1826 } |
1827 | |
1828 smiley->imhtml = imhtml; | |
1827 | 1829 |
1828 gtk_smiley_tree_insert (tree, smiley); | 1830 gtk_smiley_tree_insert (tree, smiley); |
1829 } | 1831 } |
1830 | 1832 |
1831 static gboolean | 1833 static gboolean |
4377 } else { | 4379 } else { |
4378 icon = gtk_image_new_from_animation(annipixbuf); | 4380 icon = gtk_image_new_from_animation(annipixbuf); |
4379 } | 4381 } |
4380 } | 4382 } |
4381 } | 4383 } |
4382 #if 0 | |
4383 else { | |
4384 GtkIMHtmlSmiley *imhtml_smiley; | |
4385 | |
4386 if (imhtml_smiley->loader) { ; } | |
4387 icon = gtk_image_new_from_stock(GTK_STOCK_MISSING_IMAGE, GTK_ICON_SIZE_MENU); | |
4388 imhtml_smiley = gtk_get_imhtml_smiley(imhtml, sml, unescaped); | |
4389 if (!imhtml_smiley) { | |
4390 gaim_debug_info("gtkimhtml", "geezz couldnt find smiley struct\n"); | |
4391 } | |
4392 imhtml_smiley->orphan = g_slist_append(imhtml_smiley->orphan, icon); | |
4393 } | |
4394 #endif | |
4395 | 4384 |
4396 if (icon) { | 4385 if (icon) { |
4397 anchor = gtk_text_buffer_create_child_anchor(imhtml->text_buffer, iter); | 4386 anchor = gtk_text_buffer_create_child_anchor(imhtml->text_buffer, iter); |
4398 g_object_set_data_full(G_OBJECT(anchor), "gtkimhtml_plaintext", g_strdup(unescaped), g_free); | 4387 g_object_set_data_full(G_OBJECT(anchor), "gtkimhtml_plaintext", g_strdup(unescaped), g_free); |
4399 g_object_set_data_full(G_OBJECT(anchor), "gtkimhtml_htmltext", g_strdup(smiley), g_free); | 4388 g_object_set_data_full(G_OBJECT(anchor), "gtkimhtml_htmltext", g_strdup(smiley), g_free); |