[gimp] app: register the newly changed ops' properties normally
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app: register the newly changed ops' properties normally
- Date: Sat, 16 Jan 2016 21:52:03 +0000 (UTC)
commit 38691ee03dd879ebed8a04dfe1a7da09f73e18a3
Author: Michael Natterer <mitch gimp org>
Date: Sat Jan 16 22:50:15 2016 +0100
app: register the newly changed ops' properties normally
not using GIMP_CONFIG_INSTALL_PROP_FOO() because they don't allow to
set the param spec's nick and blurb separately.
app/operations/gimpoperationdesaturate.c | 12 +++++++-----
app/operations/gimpoperationposterize.c | 10 ++++++----
2 files changed, 13 insertions(+), 9 deletions(-)
---
diff --git a/app/operations/gimpoperationdesaturate.c b/app/operations/gimpoperationdesaturate.c
index 85a39b3..08c04fc 100644
--- a/app/operations/gimpoperationdesaturate.c
+++ b/app/operations/gimpoperationdesaturate.c
@@ -85,11 +85,13 @@ gimp_operation_desaturate_class_init (GimpOperationDesaturateClass *klass)
"description", _("Turn colors into shades of gray"),
NULL);
- GIMP_CONFIG_INSTALL_PROP_ENUM (object_class, PROP_MODE,
- "mode",
- _("Choose shade of gray based on"),
- GIMP_TYPE_DESATURATE_MODE,
- GIMP_DESATURATE_LIGHTNESS, 0);
+ g_object_class_install_property (object_class, PROP_MODE,
+ g_param_spec_enum ("mode",
+ _("Mode"),
+ _("Choose shade of gray based on"),
+ GIMP_TYPE_DESATURATE_MODE,
+ GIMP_DESATURATE_LIGHTNESS,
+ GIMP_CONFIG_PARAM_FLAGS));
}
static void
diff --git a/app/operations/gimpoperationposterize.c b/app/operations/gimpoperationposterize.c
index 891f1b8..4f2a6a7 100644
--- a/app/operations/gimpoperationposterize.c
+++ b/app/operations/gimpoperationposterize.c
@@ -82,10 +82,12 @@ gimp_operation_posterize_class_init (GimpOperationPosterizeClass *klass)
"description", _("Reduce to a limited set of colors"),
NULL);
- GIMP_CONFIG_INSTALL_PROP_INT (object_class, PROP_LEVELS,
- "levels",
- _("Posterize levels"),
- 2, 256, 3, 0);
+ g_object_class_install_property (object_class, PROP_LEVELS,
+ g_param_spec_int ("levels",
+ _("Posterize levels"),
+ NULL,
+ 2, 256, 3,
+ GIMP_CONFIG_PARAM_FLAGS));
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]