Mercurial > pidgin
changeset 3050:200b8133616a
[gaim-migrate @ 3063]
This fixes smileys when changing protocols.
committer: Tailor Script <tailor@pidgin.im>
author | Rob Flynn <gaim@robflynn.com> |
---|---|
date | Fri, 15 Mar 2002 02:34:10 +0000 |
parents | dd4d4c59a2a4 |
children | 7cd6eadd575f |
files | src/conversation.c src/gtkimhtml.c src/gtkimhtml.h |
diffstat | 3 files changed, 16 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/conversation.c Fri Mar 15 02:13:45 2002 +0000 +++ b/src/conversation.c Fri Mar 15 02:34:10 2002 +0000 @@ -2207,6 +2207,7 @@ update_icon(cnv); update_checkbox(cnv); + update_smilies(cnv); } int set_dispstyle(int chat) @@ -3380,6 +3381,7 @@ GSList *smilies; if (c->gc->prpl->smiley_list) { + gtk_imhtml_remove_smileys(GTK_IMHTML(c->text)); smilies = c->gc->prpl->smiley_list(); while (smilies) { @@ -3389,6 +3391,8 @@ gtk_imhtml_associate_smiley(GTK_IMHTML(c->text), smile->key, smile->xpm); smilies = g_slist_next(smilies); } + } else { + gtk_imhtml_reset_smileys(GTK_IMHTML(c->text)); } }
--- a/src/gtkimhtml.c Fri Mar 15 02:13:45 2002 +0000 +++ b/src/gtkimhtml.c Fri Mar 15 02:34:10 2002 +0000 @@ -256,6 +256,14 @@ imhtml->smiley_data = gtk_smiley_tree_new (); } +void +gtk_imhtml_reset_smileys (GtkIMHtml *imhtml) +{ + gtk_imhtml_remove_smileys(imhtml); + gtk_imhtml_init_smileys (imhtml); +} + + struct im_image { gchar *filename;
--- a/src/gtkimhtml.h Fri Mar 15 02:13:45 2002 +0000 +++ b/src/gtkimhtml.h Fri Mar 15 02:34:10 2002 +0000 @@ -121,8 +121,12 @@ gchar *text, gchar **xpm); +static void gtk_imhtml_init_smileys (GtkIMHtml *imhtml); + void gtk_imhtml_remove_smileys (GtkIMHtml *imhtml); +void gtk_imhtml_reset_smileys (GtkIMHtml *imhtml); + void gtk_imhtml_show_smileys (GtkIMHtml *imhtml, gboolean show);