# HG changeset patch # User Stu Tomlinson # Date 1130073201 0 # Node ID 21aff66af1e777cacbb06fa58a001a47415c8aa7 # Parent 7da512f06185c891f26f288421164658a2f9d2a7 [gaim-migrate @ 14041] Inserting a smiley with text selected will now replace that text with the smiley. I have a feeling there's a bug report about this somewhere. committer: Tailor Script diff -r 7da512f06185 -r 21aff66af1e7 src/gtkimhtml.c --- a/src/gtkimhtml.c Sun Oct 23 13:12:08 2005 +0000 +++ b/src/gtkimhtml.c Sun Oct 23 13:13:21 2005 +0000 @@ -4344,6 +4344,9 @@ GtkTextMark *mark; GtkTextIter iter; + if (gtk_text_buffer_get_selection_bounds(imhtml->text_buffer, NULL, NULL)) + gtk_text_buffer_delete_selection(imhtml->text_buffer, TRUE, TRUE); + mark = gtk_text_buffer_get_insert(imhtml->text_buffer); gtk_text_buffer_get_iter_at_mark(imhtml->text_buffer, &iter, mark);