core: Use MAX_CHANNELS for Histogram limit
gimphistogram.c used its own custom MAX_N_COMPONENTS define for the max value of its "n-components" property. Since this value is the same as MAX_CHANNELS, it would be good to use the global constant so the histogram limit automatically updates when we added a new format with a larger number of components such as CMYKA.
This commit is contained in:
parent
657dceb3ed
commit
127510cd81
1 changed files with 1 additions and 2 deletions
|
|
@ -44,7 +44,6 @@
|
|||
#include "gimpwaitable.h"
|
||||
|
||||
|
||||
#define MAX_N_COMPONENTS 4
|
||||
#define N_DERIVED_CHANNELS 2
|
||||
|
||||
#define PIXELS_PER_THREAD \
|
||||
|
|
@ -146,7 +145,7 @@ gimp_histogram_class_init (GimpHistogramClass *klass)
|
|||
|
||||
g_object_class_install_property (object_class, PROP_N_COMPONENTS,
|
||||
g_param_spec_int ("n-components", NULL, NULL,
|
||||
0, MAX_N_COMPONENTS, 0,
|
||||
0, MAX_CHANNELS, 0,
|
||||
GIMP_PARAM_READABLE));
|
||||
|
||||
g_object_class_install_property (object_class, PROP_N_BINS,
|
||||
|
|
|
|||
Loading…
Reference in a new issue