Revision: 5333 http://geany.svn.sourceforge.net/geany/?rev=5333&view=rev Author: ntrel Date: 2010-10-26 18:11:23 +0000 (Tue, 26 Oct 2010)
Log Message: ----------- Avoid calling gtk_icon_size_lookup() twice unnecessarily.
Modified Paths: -------------- trunk/src/ui_utils.c
Modified: trunk/src/ui_utils.c =================================================================== --- trunk/src/ui_utils.c 2010-10-26 17:36:35 UTC (rev 5332) +++ trunk/src/ui_utils.c 2010-10-26 18:11:23 UTC (rev 5333) @@ -2472,9 +2472,10 @@ GtkIconTheme *theme; gint real_size;
- g_return_val_if_fail(gtk_icon_size_lookup(size, &real_size, NULL), NULL); - gtk_icon_size_lookup(size, &real_size, NULL); - + if (!gtk_icon_size_lookup(size, &real_size, NULL)) + { + g_return_val_if_reached(NULL); + } theme = gtk_icon_theme_get_default(); ctype = g_content_type_from_mime_type(mime_type); gicon = g_content_type_get_icon(ctype);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.