mirror of
https://gitlab.gnome.org/GNOME/gimp.git
synced 2025-07-04 09:53:25 +00:00
libgimpwidgets: add back some GEGL prop special-casing in…
… gimp_prop_spin_scale_new().
This was forgotten when moving the code to libgimpwidgets in commit
7056f1b960
. Thanks to Thomas Manni for noticing.
This commit is contained in:
parent
78fceca353
commit
75f9bdccbb
1 changed files with 18 additions and 0 deletions
|
@ -20,6 +20,7 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
#include <gegl.h>
|
#include <gegl.h>
|
||||||
|
#include <gegl-paramspecs.h>
|
||||||
#include <gtk/gtk.h>
|
#include <gtk/gtk.h>
|
||||||
|
|
||||||
#include "libgimpcolor/gimpcolor.h"
|
#include "libgimpcolor/gimpcolor.h"
|
||||||
|
@ -1546,6 +1547,23 @@ gimp_prop_spin_scale_new (GObject *config,
|
||||||
|
|
||||||
set_param_spec (G_OBJECT (adjustment), spinscale, param_spec);
|
set_param_spec (G_OBJECT (adjustment), spinscale, param_spec);
|
||||||
|
|
||||||
|
if (GEGL_IS_PARAM_SPEC_DOUBLE (param_spec))
|
||||||
|
{
|
||||||
|
GeglParamSpecDouble *gspec = GEGL_PARAM_SPEC_DOUBLE (param_spec);
|
||||||
|
|
||||||
|
gimp_spin_scale_set_scale_limits (GIMP_SPIN_SCALE (spinscale),
|
||||||
|
gspec->ui_minimum, gspec->ui_maximum);
|
||||||
|
gimp_spin_scale_set_gamma (GIMP_SPIN_SCALE (spinscale), gspec->ui_gamma);
|
||||||
|
}
|
||||||
|
else if (GEGL_IS_PARAM_SPEC_INT (param_spec))
|
||||||
|
{
|
||||||
|
GeglParamSpecInt *gspec = GEGL_PARAM_SPEC_INT (param_spec);
|
||||||
|
|
||||||
|
gimp_spin_scale_set_scale_limits (GIMP_SPIN_SCALE (spinscale),
|
||||||
|
gspec->ui_minimum, gspec->ui_maximum);
|
||||||
|
gimp_spin_scale_set_gamma (GIMP_SPIN_SCALE (spinscale), gspec->ui_gamma);
|
||||||
|
}
|
||||||
|
|
||||||
tooltip = g_param_spec_get_blurb (param_spec);
|
tooltip = g_param_spec_get_blurb (param_spec);
|
||||||
gimp_help_set_help_data (spinscale, tooltip, NULL);
|
gimp_help_set_help_data (spinscale, tooltip, NULL);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue