iconview: Don't draw unallocated items

This is more a workaround for Clutter-GTK than anything else. Most of
all, it makes gnome-boxes start again.
This commit is contained in:
Benjamin Otte 2012-05-09 14:23:10 +02:00 committed by Christophe Fergeau
parent 767a01448d
commit cc057d5c4e

View File

@ -2996,7 +2996,7 @@ gtk_icon_view_paint_item (GtkIconView *icon_view,
GtkIconViewPrivate *priv = icon_view->priv;
GtkCellAreaContext *context;
if (priv->model == NULL)
if (priv->model == NULL || item->cell_area.width <= 0 || item->cell_area.height <= 0)
return;
_gtk_icon_view_set_cell_data (icon_view, item);