Various cleanups in the GimpDynamics object

This commit is contained in:
Michael Natterer 2009-10-11 01:19:40 +02:00
parent 1fcfa9fe58
commit ba355321cf
1 changed files with 14 additions and 48 deletions

View File

@ -19,22 +19,15 @@
#include <gegl.h>
#include "libgimpbase/gimpbase.h"
#include "libgimpmath/gimpmath.h"
#include "libgimpconfig/gimpconfig.h"
#include "paint/paint-types.h"
#include "gimp.h"
#include "gimpimage.h"
#include "gimpcurve.h"
#include "core-types.h"
#include "gimpdynamics.h"
#include "gimpdynamics-load.h"
#include "gimpdynamics-save.h"
#include "gimpdata.h"
#include "gimp-intl.h"
@ -49,7 +42,6 @@
#define DEFAULT_PRESSURE_ANGLE FALSE
#define DEFAULT_PRESSURE_JITTER FALSE
#define DEFAULT_VELOCITY_OPACITY FALSE
#define DEFAULT_VELOCITY_HARDNESS FALSE
#define DEFAULT_VELOCITY_RATE FALSE
@ -153,17 +145,12 @@ enum
PROP_FADING_ASPECT_RATIO,
PROP_FADING_COLOR,
PROP_FADING_ANGLE,
PROP_FADING_JITTER,
PROP_FADING_JITTER
};
static void gimp_dynamics_class_init (GimpDynamicsClass *klass);
static void gimp_dynamics_finalize (GObject *object);
static void gimp_dynamics_notify (GObject *object,
GParamSpec *pspec);
static void gimp_dynamics_set_property (GObject *object,
guint property_id,
const GValue *value,
@ -198,7 +185,6 @@ gimp_dynamics_class_init (GimpDynamicsClass *klass)
object_class->finalize = gimp_dynamics_finalize;
object_class->set_property = gimp_dynamics_set_property;
object_class->get_property = gimp_dynamics_get_property;
object_class->notify = gimp_dynamics_notify;
data_class->save = gimp_dynamics_save;
data_class->get_extension = gimp_dynamics_get_extension;
@ -405,7 +391,6 @@ gimp_dynamics_class_init (GimpDynamicsClass *klass)
"fading-jitter", NULL,
DEFAULT_FADING_JITTER,
GIMP_PARAM_STATIC_STRINGS);
}
static void
@ -507,7 +492,6 @@ gimp_dynamics_set_property (GObject *object,
GParamSpec *pspec)
{
GimpDynamics *dynamics = GIMP_DYNAMICS (object);
GimpDynamicsOutput *opacity_dynamics = dynamics->opacity_dynamics;
GimpDynamicsOutput *hardness_dynamics = dynamics->hardness_dynamics;
GimpDynamicsOutput *rate_dynamics = dynamics->rate_dynamics;
@ -519,9 +503,8 @@ gimp_dynamics_set_property (GObject *object,
switch (property_id)
{
case PROP_NAME:
gimp_object_set_name (dynamics, g_value_get_string (value));
gimp_object_set_name (GIMP_OBJECT (dynamics), g_value_get_string (value));
break;
case PROP_PRESSURE_OPACITY:
@ -723,8 +706,6 @@ gimp_dynamics_set_property (GObject *object,
}
}
static void
gimp_dynamics_get_property (GObject *object,
guint property_id,
@ -948,29 +929,14 @@ gimp_dynamics_get_property (GObject *object,
}
}
static void
gimp_dynamics_notify (GObject *object,
GParamSpec *pspec)
{
GimpDynamics *dynamics = GIMP_DYNAMICS (object);
}
GimpData *
gimp_dynamics_new (const gchar *name)
{
GimpDynamics *dynamics;
dynamics = g_object_new (GIMP_TYPE_DYNAMICS,
return g_object_new (GIMP_TYPE_DYNAMICS,
"name", name,
NULL);
return dynamics;
}
GimpData *
gimp_dynamics_get_standard (void)
{