Don't display too many broken images. (#169870, Roman Kagan, patch by Ivan

2005-04-09  Matthias Clasen  <mclasen@redhat.com>

	* gtk/gtkimage.c (gtk_image_calc_size, gtk_image_expose):
	Don't display too many broken images.  (#169870, Roman
	Kagan, patch by Ivan Wong)

	* gtk/gtkwidget.c (gtk_widget_unparent): Remove debugging
	output.  (#300013, Tommi Komulainen)

	* io-bmp.c (gdk_pixbuf__bmp_image_save_to_callback):
	Don't overflow the stack.  (Jakub Jelinek, Arjan van de Ven)
This commit is contained in:
Matthias Clasen 2005-04-09 21:57:04 +00:00 committed by Matthias Clasen
parent 62fee90c16
commit a75e27c0a4
7 changed files with 36 additions and 11 deletions

View File

@ -1,3 +1,12 @@
2005-04-09 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkimage.c (gtk_image_calc_size, gtk_image_expose):
Don't display too many broken images. (#169870, Roman
Kagan, patch by Ivan Wong)
* gtk/gtkwidget.c (gtk_widget_unparent): Remove debugging
output. (#300013, Tommi Komulainen)
2005-04-08 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkimage.c (gtk_image_expose, gtk_image_calc_size):

View File

@ -1,3 +1,12 @@
2005-04-09 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkimage.c (gtk_image_calc_size, gtk_image_expose):
Don't display too many broken images. (#169870, Roman
Kagan, patch by Ivan Wong)
* gtk/gtkwidget.c (gtk_widget_unparent): Remove debugging
output. (#300013, Tommi Komulainen)
2005-04-08 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkimage.c (gtk_image_expose, gtk_image_calc_size):

View File

@ -1,3 +1,12 @@
2005-04-09 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkimage.c (gtk_image_calc_size, gtk_image_expose):
Don't display too many broken images. (#169870, Roman
Kagan, patch by Ivan Wong)
* gtk/gtkwidget.c (gtk_widget_unparent): Remove debugging
output. (#300013, Tommi Komulainen)
2005-04-08 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkimage.c (gtk_image_expose, gtk_image_calc_size):

View File

@ -1,3 +1,8 @@
2005-04-09 Matthias Clasen <mclasen@redhat.com>
* io-bmp.c (gdk_pixbuf__bmp_image_save_to_callback):
Don't overflow the stack. (Jakub Jelinek, Arjan van de Ven)
2005-04-08 Matthias Clasen <mclasen@redhat.com>
* io-pcx.c: No debugging output, please. (#173107,

View File

@ -1155,7 +1155,7 @@ gdk_pixbuf__bmp_image_save_to_callback (GdkPixbufSaveFunc save_func,
GError **error)
{
guint width, height, channel, size, stride, src_stride, x, y;
guchar BFH_BIH[40], *pixels, *buf, *src, *dst, *dst_line;
guchar BFH_BIH[54], *pixels, *buf, *src, *dst, *dst_line;
gboolean ret;
width = gdk_pixbuf_get_width (pixbuf);

View File

@ -1547,7 +1547,6 @@ gtk_image_expose (GtkWidget *widget,
GdkBitmap *mask;
GdkPixbuf *pixbuf;
gboolean needs_state_transform;
GtkStockItem item;
gchar *stock_id;
@ -1657,7 +1656,7 @@ gtk_image_expose (GtkWidget *widget,
break;
case GTK_IMAGE_STOCK:
if (gtk_stock_lookup (image->data.stock.stock_id, &item))
if (gtk_style_lookup_icon_set (widget->style, image->data.stock.stock_id))
stock_id = image->data.stock.stock_id;
else
stock_id = GTK_STOCK_MISSING_IMAGE;
@ -1957,7 +1956,6 @@ gtk_image_calc_size (GtkImage *image)
{
GtkWidget *widget = GTK_WIDGET (image);
GdkPixbuf *pixbuf = NULL;
GtkStockItem item;
gchar *stock_id;
/* We update stock/icon set on every size request, because
@ -1968,7 +1966,7 @@ gtk_image_calc_size (GtkImage *image)
switch (image->storage_type)
{
case GTK_IMAGE_STOCK:
if (gtk_stock_lookup (image->data.stock.stock_id, &item))
if (gtk_style_lookup_icon_set (widget->style, image->data.stock.stock_id))
stock_id = image->data.stock.stock_id;
else
stock_id = GTK_STOCK_MISSING_IMAGE;

View File

@ -1901,12 +1901,7 @@ gtk_widget_unparent (GtkWidget *widget)
if (GTK_WIDGET_REALIZED (widget))
{
if (GTK_WIDGET_IN_REPARENT (widget))
#if 1
{
g_print ("unmapping!\n");
gtk_widget_unmap (widget);
}
#endif
gtk_widget_unmap (widget);
else
gtk_widget_unrealize (widget);
}