Make sure either the window or the depth is given when creating a pixmap.

Sun Mar  1 17:40:58 1998  Owen Taylor  <owt1@cornell.edu>

	* gdk/gdkpixmap.c: Make sure either the window or
	the depth is given when creating a pixmap.
This commit is contained in:
Owen Taylor 1998-03-01 23:38:01 +00:00 committed by Owen Taylor
parent af18ab4305
commit ade3020098
9 changed files with 45 additions and 8 deletions

View File

@ -1,3 +1,8 @@
Sun Mar 1 17:40:58 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkpixmap.c: Make sure either the window or
the depth is given when creating a pixmap.
Sun Mar 1 22:59:09 1998 Tim Janik <timj@gimp.org>
* gtk/gtkstatusbar.h:

View File

@ -1,3 +1,8 @@
Sun Mar 1 17:40:58 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkpixmap.c: Make sure either the window or
the depth is given when creating a pixmap.
Sun Mar 1 22:59:09 1998 Tim Janik <timj@gimp.org>
* gtk/gtkstatusbar.h:

View File

@ -1,3 +1,8 @@
Sun Mar 1 17:40:58 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkpixmap.c: Make sure either the window or
the depth is given when creating a pixmap.
Sun Mar 1 22:59:09 1998 Tim Janik <timj@gimp.org>
* gtk/gtkstatusbar.h:

View File

@ -1,3 +1,8 @@
Sun Mar 1 17:40:58 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkpixmap.c: Make sure either the window or
the depth is given when creating a pixmap.
Sun Mar 1 22:59:09 1998 Tim Janik <timj@gimp.org>
* gtk/gtkstatusbar.h:

View File

@ -1,3 +1,8 @@
Sun Mar 1 17:40:58 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkpixmap.c: Make sure either the window or
the depth is given when creating a pixmap.
Sun Mar 1 22:59:09 1998 Tim Janik <timj@gimp.org>
* gtk/gtkstatusbar.h:

View File

@ -1,3 +1,8 @@
Sun Mar 1 17:40:58 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkpixmap.c: Make sure either the window or
the depth is given when creating a pixmap.
Sun Mar 1 22:59:09 1998 Tim Janik <timj@gimp.org>
* gtk/gtkstatusbar.h:

View File

@ -1,3 +1,8 @@
Sun Mar 1 17:40:58 1998 Owen Taylor <owt1@cornell.edu>
* gdk/gdkpixmap.c: Make sure either the window or
the depth is given when creating a pixmap.
Sun Mar 1 22:59:09 1998 Tim Janik <timj@gimp.org>
* gtk/gtkstatusbar.h:

View File

@ -43,6 +43,8 @@ gdk_pixmap_new (GdkWindow *window,
GdkWindowPrivate *private;
GdkWindowPrivate *window_private;
g_return_val_if_fail ((window != NULL) || (depth != -1), NULL);
if (!window)
window = (GdkWindow*) &gdk_root_parent;
@ -132,6 +134,7 @@ gdk_pixmap_create_from_data (GdkWindow *window,
g_return_val_if_fail (data != NULL, NULL);
g_return_val_if_fail (fg != NULL, NULL);
g_return_val_if_fail (bg != NULL, NULL);
g_return_val_if_fail ((window != NULL) || (depth != -1), NULL);
if (!window)
window = (GdkWindow*) &gdk_root_parent;
@ -368,8 +371,7 @@ gdk_pixmap_create_from_xpm (GdkWindow *window,
_GdkPixmapColor *colors = NULL, *color = NULL;
gulong index;
if (!window)
window = (GdkWindow*) &gdk_root_parent;
g_return_val_if_fail (window != NULL, NULL);
infile = fopen (filename, "rb");
if (infile != NULL)
@ -529,8 +531,7 @@ gdk_pixmap_create_from_xpm_d (GdkWindow *window,
_GdkPixmapColor *colors = NULL, *color = NULL;
gulong index;
if (!window)
window = (GdkWindow*) &gdk_root_parent;
g_return_val_if_fail (window != NULL, NULL);
i = 0;
buffer = data[i++];

View File

@ -43,6 +43,8 @@ gdk_pixmap_new (GdkWindow *window,
GdkWindowPrivate *private;
GdkWindowPrivate *window_private;
g_return_val_if_fail ((window != NULL) || (depth != -1), NULL);
if (!window)
window = (GdkWindow*) &gdk_root_parent;
@ -132,6 +134,7 @@ gdk_pixmap_create_from_data (GdkWindow *window,
g_return_val_if_fail (data != NULL, NULL);
g_return_val_if_fail (fg != NULL, NULL);
g_return_val_if_fail (bg != NULL, NULL);
g_return_val_if_fail ((window != NULL) || (depth != -1), NULL);
if (!window)
window = (GdkWindow*) &gdk_root_parent;
@ -368,8 +371,7 @@ gdk_pixmap_create_from_xpm (GdkWindow *window,
_GdkPixmapColor *colors = NULL, *color = NULL;
gulong index;
if (!window)
window = (GdkWindow*) &gdk_root_parent;
g_return_val_if_fail (window != NULL, NULL);
infile = fopen (filename, "rb");
if (infile != NULL)
@ -529,8 +531,7 @@ gdk_pixmap_create_from_xpm_d (GdkWindow *window,
_GdkPixmapColor *colors = NULL, *color = NULL;
gulong index;
if (!window)
window = (GdkWindow*) &gdk_root_parent;
g_return_val_if_fail (window != NULL, NULL);
i = 0;
buffer = data[i++];