forked from AuroraMiddleware/gtk
Check column types on the new model, and check them all. (#159389, Olivier
2004-11-26 Matthias Clasen <mclasen@redhat.com> * gtk/gtkiconview.c (gtk_icon_view_set_model): Check column types on the new model, and check them all. (#159389, Olivier Andrieu)
This commit is contained in:
parent
54c6743787
commit
5b29d3d55e
@ -1,5 +1,8 @@
|
||||
2004-11-26 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gtk/gtkiconview.c (gtk_icon_view_set_model): Check column types on the
|
||||
new model, and check them all. (#159389, Olivier Andrieu)
|
||||
|
||||
* gdk/x11/gdkselection-x11.c (gdk_text_property_to_utf8_list_for_display):
|
||||
Don't crash if Xlib fails to return UTF-8. (#159373, Kristian Høgsberg)
|
||||
|
||||
|
@ -1,5 +1,8 @@
|
||||
2004-11-26 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gtk/gtkiconview.c (gtk_icon_view_set_model): Check column types on the
|
||||
new model, and check them all. (#159389, Olivier Andrieu)
|
||||
|
||||
* gdk/x11/gdkselection-x11.c (gdk_text_property_to_utf8_list_for_display):
|
||||
Don't crash if Xlib fails to return UTF-8. (#159373, Kristian Høgsberg)
|
||||
|
||||
|
@ -1,5 +1,8 @@
|
||||
2004-11-26 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gtk/gtkiconview.c (gtk_icon_view_set_model): Check column types on the
|
||||
new model, and check them all. (#159389, Olivier Andrieu)
|
||||
|
||||
* gdk/x11/gdkselection-x11.c (gdk_text_property_to_utf8_list_for_display):
|
||||
Don't crash if Xlib fails to return UTF-8. (#159373, Kristian Høgsberg)
|
||||
|
||||
|
@ -1,5 +1,8 @@
|
||||
2004-11-26 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gtk/gtkiconview.c (gtk_icon_view_set_model): Check column types on the
|
||||
new model, and check them all. (#159389, Olivier Andrieu)
|
||||
|
||||
* gdk/x11/gdkselection-x11.c (gdk_text_property_to_utf8_list_for_display):
|
||||
Don't crash if Xlib fails to return UTF-8. (#159373, Kristian Høgsberg)
|
||||
|
||||
|
@ -2955,24 +2955,32 @@ gtk_icon_view_set_model (GtkIconView *icon_view,
|
||||
|
||||
if (model)
|
||||
{
|
||||
GType pixbuf_column_type, text_column_type;
|
||||
GType column_type;
|
||||
|
||||
g_return_if_fail (gtk_tree_model_get_flags (model) & GTK_TREE_MODEL_LIST_ONLY);
|
||||
|
||||
if (icon_view->priv->pixbuf_column != -1)
|
||||
{
|
||||
pixbuf_column_type = gtk_tree_model_get_column_type (icon_view->priv->model,
|
||||
icon_view->priv->pixbuf_column);
|
||||
column_type = gtk_tree_model_get_column_type (model,
|
||||
icon_view->priv->pixbuf_column);
|
||||
|
||||
g_return_if_fail (pixbuf_column_type == GDK_TYPE_PIXBUF);
|
||||
g_return_if_fail (column_type == GDK_TYPE_PIXBUF);
|
||||
}
|
||||
|
||||
if (icon_view->priv->text_column != -1)
|
||||
{
|
||||
text_column_type = gtk_tree_model_get_column_type (icon_view->priv->model,
|
||||
icon_view->priv->pixbuf_column);
|
||||
column_type = gtk_tree_model_get_column_type (model,
|
||||
icon_view->priv->text_column);
|
||||
|
||||
g_return_if_fail (text_column_type == G_TYPE_STRING);
|
||||
g_return_if_fail (column_type == G_TYPE_STRING);
|
||||
}
|
||||
|
||||
if (icon_view->priv->markup_column != -1)
|
||||
{
|
||||
column_type = gtk_tree_model_get_column_type (model,
|
||||
icon_view->priv->markup_column);
|
||||
|
||||
g_return_if_fail (column_type == G_TYPE_STRING);
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user