gimp/app/actions/actions-types.h
Michael Natterer a4863593ec Close the display after "Save as" when invoked via the "Close Without
2007-01-20  Michael Natterer  <mitch@gimp.org>

	Close the display after "Save as" when invoked via the "Close
	Without Saving" dialog. Fixes bug #383700.

	* app/actions/actions-types.h: added enum GimpSaveMode { SAVE,
	SAVE_AS, SAVE_A_COPY, SAVE_AND_CLOSE }.

	* app/actions/file-actions.c: changed the 4 save actions into
	GimpEnumActions with above enum as values.

	* app/actions/file-commands.[ch]: merged the save callbacks into
	one and pass a "close_after_saving" boolean to
	file_save_dialog_show().

	* app/widgets/gimpfiledialog.[ch]: added "gboolean
	close_after_saving" parameter to gimp_file_dialog_set_image() and
	to the GimpFileDialog struct.

	* app/dialogs/file-save-dialog.c: if the file was saved
	successfully and close_after_saving is TRUE, close the display if
	the image has not become dirty again in the meantime.


svn path=/trunk/; revision=21743
2007-01-20 19:38:09 +00:00

52 lines
1.6 KiB
C

/* GIMP - The GNU Image Manipulation Program
* Copyright (C) 1995 Spencer Kimball and Peter Mattis
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program 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 General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef __ACTIONS_TYPES_H__
#define __ACTIONS_TYPES_H__
#include "dialogs/dialogs-types.h"
#include "tools/tools-types.h"
typedef enum
{
GIMP_ACTION_SELECT_SET = 0,
GIMP_ACTION_SELECT_FIRST = -1,
GIMP_ACTION_SELECT_LAST = -2,
GIMP_ACTION_SELECT_SMALL_PREVIOUS = -3,
GIMP_ACTION_SELECT_SMALL_NEXT = -4,
GIMP_ACTION_SELECT_PREVIOUS = -5,
GIMP_ACTION_SELECT_NEXT = -6,
GIMP_ACTION_SELECT_SKIP_PREVIOUS = -7,
GIMP_ACTION_SELECT_SKIP_NEXT = -8,
GIMP_ACTION_SELECT_PERCENT_PREVIOUS = -9,
GIMP_ACTION_SELECT_PERCENT_NEXT = -10
} GimpActionSelectType;
typedef enum
{
GIMP_SAVE_MODE_SAVE,
GIMP_SAVE_MODE_SAVE_AS,
GIMP_SAVE_MODE_SAVE_A_COPY,
GIMP_SAVE_MODE_SAVE_AND_CLOSE
} GimpSaveMode;
#endif /* __ACTIONS_TYPES_H__ */