pike.git / src / post_modules / GTK2 / source / support.c

version» Context lines:

pike.git/src/post_modules/GTK2/source/support.c:1:   /*   || This file is part of Pike. For copyright information see COPYRIGHT.   || Pike is distributed under GPL, LGPL and MPL. See the file COPYING   || for more information. - || $Id: support.c,v 1.25 2010/07/31 23:54:07 marcus Exp $ + || $Id: support.c,v 1.26 2010/08/01 00:10:20 marcus Exp $   */      #include <version.h>   #include <bignum.h>   #include <stdarg.h>      #ifndef INIT_VARIABLES   extern struct program *image_color_program;   extern struct program *image_program;   #endif
pike.git/src/post_modules/GTK2/source/support.c:98:    img_data=(struct image*)get_storage(img, image_program);       /* 1a: create the actual image... */    x = img_data->xsize;    y = img_data->ysize;          if (x==0 || y==0)    Pike_error("Size of image must be > 0x0\n");    if (pi) { -  i = *pi; +  i = GDK_IMAGE(*pi);    if (i != NULL && ((i->width!=x) || (i->height!=y))) {    g_object_unref(i);    i=NULL;    }    } else    i=NULL;    if (!i) {    PFTIME("Create");    i=(void *)gdk_image_new(fast,vis,x,y);    }    if (pi) -  *pi = i; +  *pi = G_OBJECT(i);       if (!i)    Pike_error("Failed to create gdkimage\n");       /* 1b: do the work.. */       if (vis->type==GDK_VISUAL_TRUE_COLOR || vis->type==GDK_VISUAL_STATIC_GRAY)    /* no colormap.. */    {    int pad=0;