I'm back banging on this bit of code that puts together a doubly-linked list of Pixbufs for use as Window icons, etc. I assemble the list, check the integrity of the list and everything seems fine. Then I pass it to Window.setIconList() and get the errors shown below.
Does this function work as intended? Am I assembling the ListG wrong?
string[] images = ["images/airport_25.png",
"images/airport_35.png",
"images/airport_60.png",
"images/airport_100.png"];
ListG listG = new ListG(null);
for(int i; i < images.length; i++)
{
string imageName = images[i];
Pixbuf pixbuf = new Pixbuf(imageName);
listG = listG.append(cast(void*)pixbuf);
}
// check list integrity
uint listLength = listG.length();
for(int i; i < listLength; i++)
{
Pixbuf pixbuf = cast(Pixbuf)listG.nthData(i);
writeln("data: ", listG.nthData(i), ", width: ", pixbuf.getWidth());
}
setIconList(listG);
Which results in these errors:
(pixbuf_listg_pixbufs.exe:780): GLib-GObject-CRITICAL **: 15:15:46.141: g_object_ref: assertion 'G_IS_OBJECT (object)' failed
(pixbuf_listg_pixbufs.exe:780): GLib-GObject-CRITICAL **: 15:15:46.152: g_object_ref: assertion 'G_IS_OBJECT (object)' failed
(pixbuf_listg_pixbufs.exe:780): GLib-GObject-CRITICAL **: 15:15:46.158: g_object_ref: assertion 'G_IS_OBJECT (object)' failed
(pixbuf_listg_pixbufs.exe:780): GLib-GObject-CRITICAL **: 15:15:46.165: g_object_ref: assertion 'G_IS_OBJECT (object)' failed
icon list set
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.395: gdk_pixbuf_get_width: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.400: gdk_pixbuf_get_height: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.407: gdk_pixbuf_get_width: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.413: gdk_pixbuf_get_height: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.419: gdk_pixbuf_get_width: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.427: gdk_pixbuf_get_height: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.432: gdk_pixbuf_get_width: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.439: gdk_pixbuf_get_height: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.445: gdk_pixbuf_get_has_alpha: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.450: gdk_pixbuf_get_width: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.457: gdk_pixbuf_get_height: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): Gdk-WARNING **: 15:15:46.465: gdkcursor-win32.c:1072: CreateDIBSection failed with code 87: The parameter is incorrect.
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.471: gdk_pixbuf_get_has_alpha: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.477: gdk_pixbuf_get_width: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): GdkPixbuf-CRITICAL **: 15:15:46.482: gdk_pixbuf_get_height: assertion 'GDK_IS_PIXBUF (pixbuf)' failed
(pixbuf_listg_pixbufs.exe:780): Gdk-WARNING **: 15:15:46.490: gdkcursor-win32.c:1072: CreateDIBSection failed with code 87: The parameter is incorrect.