added copyright header, added #defines for access(), F_OK, R_OK and X_OK.

2004-07-19  Michael Natterer  <mitch@gimp.org>

	* libgimpbase/gimpwin32-io.h: added copyright header, added
	#defines for access(), F_OK, R_OK and X_OK.

	* app/core/gimpdata.c: include the above instead of defining
	the workarounds here.

	* app/base/tile-swap.c
	* app/config/gimpconfig-dump.c
	* libgimpthumb/gimpthumb-utils.c
	* libgimpthumb/gimpthumbnail.c: for consistency, #include
	gimpwin32-io.h with "" instead of <>.
This commit is contained in:
Michael Natterer 2004-07-19 13:22:44 +00:00 committed by Michael Natterer
parent fe23211092
commit c5e78fe18a
7 changed files with 60 additions and 26 deletions

View file

@ -1,3 +1,17 @@
2004-07-19 Michael Natterer <mitch@gimp.org>
* libgimpbase/gimpwin32-io.h: added copyright header, added
#defines for access(), F_OK, R_OK and X_OK.
* app/core/gimpdata.c: include the above instead of defining
the workarounds here.
* app/base/tile-swap.c
* app/config/gimpconfig-dump.c
* libgimpthumb/gimpthumb-utils.c
* libgimpthumb/gimpthumbnail.c: for consistency, #include
gimpwin32-io.h with "" instead of <>.
2004-07-19 Michael Natterer <mitch@gimp.org>
* app/core/gimpchannel-combine.c (gimp_channel_combine_ellipse):

View file

@ -329,7 +329,7 @@ tile_swap_compress (gint swap_num)
/* check if we can open a swap file */
gboolean
tile_swap_test ()
tile_swap_test (void)
{
SwapFile *swap_file;
int swap_num = 1;

View file

@ -29,12 +29,12 @@
#include <glib-object.h>
#ifdef G_OS_WIN32
#include <libgimpbase/gimpwin32-io.h>
#endif
#include "libgimpbase/gimpbase.h"
#ifdef G_OS_WIN32
#include "libgimpbase/gimpwin32-io.h"
#endif
#include "config-types.h"
#include "gimpconfig.h"

View file

@ -31,17 +31,12 @@
#include <glib-object.h>
#ifdef G_OS_WIN32
#include <io.h>
#define F_OK 0
#define W_OK 2
#define R_OK 4
#define X_OK 0 /* not really */
#define access(f,p) _access(f,p)
#endif
#include "libgimpbase/gimpbase.h"
#ifdef G_OS_WIN32
#include "libgimpbase/gimpwin32-io.h"
#endif
#include "core-types.h"
#include "gimpdata.h"
@ -106,11 +101,8 @@ gimp_data_get_type (void)
static void
gimp_data_class_init (GimpDataClass *klass)
{
GObjectClass *object_class;
GimpObjectClass *gimp_object_class;
object_class = G_OBJECT_CLASS (klass);
gimp_object_class = GIMP_OBJECT_CLASS (klass);
GObjectClass *object_class = G_OBJECT_CLASS (klass);
GimpObjectClass *gimp_object_class = GIMP_OBJECT_CLASS (klass);
parent_class = g_type_class_peek_parent (klass);

View file

@ -1,15 +1,34 @@
/*
/* LIBGIMP - The GIMP Library
* Copyright (C) 1995-1997 Peter Mattis and Spencer Kimball
*
* gimpwin32-io.h
* Compatibilty defines, you mostly need this as unistd.h replacement
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Library General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#ifndef __GIMP_WIN32_IO_H__
#define __GIMP_WIN32_IO_H__
#include <io.h>
#include <direct.h>
#define mkdir(n,a) _mkdir(n)
#define chmod(n,f) _chmod(n,f)
#define mkdir(n,a) _mkdir(n)
#define chmod(n,f) _chmod(n,f)
#define access(f,p) _access(f,p)
#ifndef S_ISREG
#define S_ISREG(m) (((m) & _S_IFMT) == _S_IFREG)
@ -35,8 +54,17 @@
#define _O_TEMPORARY 0
#endif
#ifndef F_OK
#define F_OK 0
#endif
#ifndef W_OK
#define W_OK 2
#endif
#ifndef R_OK
#define R_OK 4
#endif
#ifndef X_OK
#define X_OK 0 /* not really */
#endif
#endif /* __GIMP_WIN32_IO_H__ */

View file

@ -36,7 +36,7 @@
#include <glib-object.h>
#ifdef G_OS_WIN32
#include <libgimpbase/gimpwin32-io.h>
#include "libgimpbase/gimpwin32-io.h"
#endif
#include "libgimpmath/gimpmath.h"

View file

@ -34,7 +34,7 @@
#include <gdk-pixbuf/gdk-pixbuf.h>
#ifdef G_OS_WIN32
#include <libgimpbase/gimpwin32-io.h>
#include "libgimpbase/gimpwin32-io.h"
#endif
#include "gimpthumb-types.h"