Commit 24f8d7e7 authored by Michael Natterer's avatar Michael Natterer 😴 Committed by Michael Natterer

cleanup.

2004-09-27  Michael Natterer  <mitch@gimp.org>

	* app/actions/data-commands.c: cleanup.

	* app/actions/vectors-commands.c
	* app/display/gimpdisplayshell.c
	* tools/pdbgen/pdb/paint_tools.pdb: removed unused #includes.

	* app/text/gimptext-bitmap.c
	* app/text/gimptext-parasite.c
	* app/text/gimptext-vectors.c
	* app/text/gimptext-xlfd.c
	* app/text/gimptext.c
	* app/text/gimptextlayer-xcf.c: include "text-types.h" instead
	of "text/text-types.h".

	* app/widgets/gimppatternselect.c: create a GimpPatternFactoryView
	instead of GimpDataFactoryView.

	* app/pdb/paint_tools_cmds.c: regenerated.
parent 96a27b59
2004-09-27 Michael Natterer <mitch@gimp.org>
* app/actions/data-commands.c: cleanup.
* app/actions/vectors-commands.c
* app/display/gimpdisplayshell.c
* tools/pdbgen/pdb/paint_tools.pdb: removed unused #includes.
* app/text/gimptext-bitmap.c
* app/text/gimptext-parasite.c
* app/text/gimptext-vectors.c
* app/text/gimptext-xlfd.c
* app/text/gimptext.c
* app/text/gimptextlayer-xcf.c: include "text-types.h" instead
of "text/text-types.h".
* app/widgets/gimppatternselect.c: create a GimpPatternFactoryView
instead of GimpDataFactoryView.
* app/pdb/paint_tools_cmds.c: regenerated.
2004-09-27 Michael Natterer <mitch@gimp.org>
* app/actions/brushes-actions.c
......
......@@ -42,6 +42,24 @@
#include "gimp-intl.h"
typedef struct _GimpDataDeleteData GimpDataDeleteData;
struct _GimpDataDeleteData
{
GimpDataFactory *factory;
GimpData *data;
};
/* local function prototypes */
static void data_delete_callback (GtkWidget *widget,
gboolean delete,
gpointer data);
/* public functions */
void
data_new_data_cmd_callback (GtkAction *action,
gpointer user_data)
......@@ -101,35 +119,6 @@ data_duplicate_data_cmd_callback (GtkAction *action,
}
}
typedef struct _GimpDataDeleteData GimpDataDeleteData;
struct _GimpDataDeleteData
{
GimpDataFactory *factory;
GimpData *data;
};
static void
data_delete_callback (GtkWidget *widget,
gboolean delete,
gpointer data)
{
GimpDataDeleteData *delete_data = data;
if (delete)
{
GError *error = NULL;
if (! gimp_data_factory_data_delete (delete_data->factory,
delete_data->data,
TRUE, &error))
{
g_message (error->message);
g_clear_error (&error);
}
}
}
void
data_delete_data_cmd_callback (GtkAction *action,
gpointer user_data)
......@@ -217,3 +206,27 @@ data_edit_data_cmd_callback (GtkAction *action,
data);
}
}
/* private functions */
static void
data_delete_callback (GtkWidget *widget,
gboolean delete,
gpointer data)
{
GimpDataDeleteData *delete_data = data;
if (delete)
{
GError *error = NULL;
if (! gimp_data_factory_data_delete (delete_data->factory,
delete_data->data,
TRUE, &error))
{
g_message (error->message);
g_clear_error (&error);
}
}
}
......@@ -46,13 +46,11 @@
#include "vectors/gimpvectors-export.h"
#include "vectors/gimpvectors-import.h"
#include "widgets/gimpdock.h"
#include "widgets/gimphelp-ids.h"
#include "widgets/gimpviewabledialog.h"
#include "display/gimpdisplay.h"
#include "tools/gimppainttool.h"
#include "tools/gimpvectortool.h"
#include "tools/tool_manager.h"
......
......@@ -44,7 +44,6 @@
#include "core/gimppattern.h"
#include "vectors/gimpvectors.h"
#include "vectors/gimpstroke.h"
#include "widgets/gimpdnd.h"
#include "widgets/gimphelp-ids.h"
......
......@@ -34,7 +34,6 @@
#include "core/gimppaintinfo.h"
#include "paint/gimppaintcore-stroke.h"
#include "paint/gimppaintoptions.h"
#include "paint/paint-types.h"
static ProcRecord airbrush_proc;
static ProcRecord airbrush_default_proc;
......
......@@ -26,7 +26,7 @@
#define PANGO_ENABLE_ENGINE
#include <pango/pangoft2.h>
#include "text/text-types.h"
#include "text-types.h"
#include "gimptext-bitmap.h"
......
......@@ -29,7 +29,7 @@
#include "libgimpbase/gimpbase.h"
#include "libgimpcolor/gimpcolor.h"
#include "text/text-types.h"
#include "text-types.h"
#include "config/gimpconfig.h"
......
......@@ -30,7 +30,7 @@
#include FT_GLYPH_H
#include FT_OUTLINE_H
#include "text/text-types.h"
#include "text-types.h"
#include "core/gimpimage.h"
......
......@@ -31,7 +31,7 @@
#include "libgimpbase/gimpbase.h"
#include "text/text-types.h"
#include "text-types.h"
#include "gimptext.h"
#include "gimptext-xlfd.h"
......
......@@ -29,7 +29,7 @@
#include "libgimpbase/gimpbase.h"
#include "libgimpcolor/gimpcolor.h"
#include "text/text-types.h"
#include "text-types.h"
#include "config/gimpconfig.h"
#include "config/gimpconfig-params.h"
......
......@@ -23,7 +23,7 @@
#include <glib-object.h>
#include "text/text-types.h"
#include "text-types.h"
#include "core/gimp.h"
#include "core/gimpimage.h"
......
......@@ -36,7 +36,7 @@
#include "pdb/procedural_db.h"
#include "gimpcontainerbox.h"
#include "gimpdatafactoryview.h"
#include "gimppatternfactoryview.h"
#include "gimppatternselect.h"
......@@ -109,13 +109,11 @@ gimp_pattern_select_constructor (GType type,
dialog = GIMP_PDB_DIALOG (object);
dialog->view =
gimp_data_factory_view_new (GIMP_VIEW_TYPE_GRID,
dialog->context->gimp->pattern_factory,
dialog->context,
GIMP_VIEW_SIZE_MEDIUM, 1,
dialog->menu_factory, "<Patterns>",
"/patterns-popup",
"patterns");
gimp_pattern_factory_view_new (GIMP_VIEW_TYPE_GRID,
dialog->context->gimp->pattern_factory,
dialog->context,
GIMP_VIEW_SIZE_MEDIUM, 1,
dialog->menu_factory);
gimp_container_box_set_size_request (GIMP_CONTAINER_BOX (GIMP_CONTAINER_EDITOR (dialog->view)->view),
6 * (GIMP_VIEW_SIZE_MEDIUM + 2),
......
......@@ -728,7 +728,7 @@ sub ink {
);
}
@headers = qw("libgimpmath/gimpmath.h" "paint/paint-types.h"
@headers = qw("libgimpmath/gimpmath.h"
"paint/gimppaintcore-stroke.h" "paint/gimppaintoptions.h"
"core/gimp.h" "core/gimpcontainer.h" "core/gimppaintinfo.h");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment