[gimp/goat-invasion] app: generalize some Babl format hardcoding in GimpLevelsTool



commit a86cc221ed92a2cb9449438c95e74cc7f3ebe571
Author: Michael Natterer <mitch gimp org>
Date:   Mon Apr 30 21:12:19 2012 +0200

    app: generalize some Babl format hardcoding in GimpLevelsTool

 app/tools/gimplevelstool.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/app/tools/gimplevelstool.c b/app/tools/gimplevelstool.c
index 26aebb7..c5c940d 100644
--- a/app/tools/gimplevelstool.c
+++ b/app/tools/gimplevelstool.c
@@ -30,6 +30,7 @@
 
 #include "tools-types.h"
 
+#include "gegl/gimp-babl.h"
 #include "gegl/gimplevelsconfig.h"
 #include "gegl/gimpoperationlevels.h"
 
@@ -1170,8 +1171,7 @@ gimp_levels_tool_color_picked (GimpColorTool      *color_tool,
                                                "pick-value"));
 
   if (value & PICK_ALL_CHANNELS &&
-      (sample_format == babl_format ("R'G'B' u8") ||
-       sample_format == babl_format ("R'G'B'A u8")))
+      gimp_babl_format_get_base_type (sample_format) == GIMP_RGB)
     {
       GimpHistogramChannel  channel;
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]