changeset 10522:e8b160971254

[gaim-migrate @ 11838] Don't show smileys in Help -> About, apparently some people put smileys in their compiler flags. committer: Tailor Script <tailor@pidgin.im>
author Stu Tomlinson <stu@nosnilmot.com>
date Tue, 18 Jan 2005 02:11:51 +0000
parents db44efdf6565
children f5c9438982f8
files src/gtkdialogs.c src/gtkimhtml.c
diffstat 2 files changed, 12 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/src/gtkdialogs.c	Mon Jan 17 02:52:16 2005 +0000
+++ b/src/gtkdialogs.c	Tue Jan 18 02:11:51 2005 +0000
@@ -213,6 +213,7 @@
 	gtk_box_pack_start(GTK_BOX(vbox), logo, FALSE, FALSE, 0);
 
 	frame = gaim_gtk_create_imhtml(FALSE, &text, NULL);
+	gtk_imhtml_set_format_functions(GTK_IMHTML(text), GTK_IMHTML_ALL ^ GTK_IMHTML_SMILEY);
 	gtk_box_pack_start(GTK_BOX(vbox), frame, TRUE, TRUE, 0);
 
 	str = g_string_sized_new(4096);
--- a/src/gtkimhtml.c	Mon Jan 17 02:52:16 2005 +0000
+++ b/src/gtkimhtml.c	Tue Jan 18 02:11:51 2005 +0000
@@ -3884,14 +3884,17 @@
 	GtkTextChildAnchor *anchor;
 	char *unescaped = gaim_unescape_html(smiley);
 
-	annipixbuf = gtk_smiley_tree_image(imhtml, sml, unescaped);
-	if(annipixbuf) {
-		if(gdk_pixbuf_animation_is_static_image(annipixbuf)) {
-			pixbuf = gdk_pixbuf_animation_get_static_image(annipixbuf);
-			if(pixbuf)
-				icon = gtk_image_new_from_pixbuf(pixbuf);
-		} else {
-			icon = gtk_image_new_from_animation(annipixbuf);
+	if (imhtml->format_functions & GTK_IMHTML_SMILEY)
+	{
+		annipixbuf = gtk_smiley_tree_image(imhtml, sml, unescaped);
+		if(annipixbuf) {
+			if(gdk_pixbuf_animation_is_static_image(annipixbuf)) {
+				pixbuf = gdk_pixbuf_animation_get_static_image(annipixbuf);
+				if(pixbuf)
+					icon = gtk_image_new_from_pixbuf(pixbuf);
+			} else {
+				icon = gtk_image_new_from_animation(annipixbuf);
+			}
 		}
 	}