[gimp] app: remove code in draw() that special cases drawing vs. undrawing



commit 7a6a57c42f123f3c6db4827f54352bd2ce4ab802
Author: Michael Natterer <mitch gimp org>
Date:   Fri Sep 24 21:18:45 2010 +0200

    app: remove code in draw() that special cases drawing vs. undrawing
    
    GimpDrawTool::draw() is not used for undrawing any longer.

 app/tools/gimpbrushtool.c |   18 ++++++------------
 1 files changed, 6 insertions(+), 12 deletions(-)
---
diff --git a/app/tools/gimpbrushtool.c b/app/tools/gimpbrushtool.c
index dcb85e6..19d4a87 100644
--- a/app/tools/gimpbrushtool.c
+++ b/app/tools/gimpbrushtool.c
@@ -306,17 +306,11 @@ gimp_brush_tool_draw_brush (GimpBrushTool *brush_tool,
   brush_core = GIMP_BRUSH_CORE (GIMP_PAINT_TOOL (brush_tool)->core);
   options    = GIMP_PAINT_TOOL_GET_OPTIONS (brush_tool);
 
-  /*  don't create the segments for the purpose of undrawing (if we
-   *  don't have the segments, we can hardly have drawn them before)
-   */
-  if (! brush_core->brush_bound_segs && brush_core->main_brush &&
-      ! gimp_draw_tool_is_drawn (draw_tool))
-    {
-      gimp_brush_core_create_bound_segs (brush_core, options);
-    }
+  if (! brush_core->brush_bound_segs && brush_core->main_brush)
+    gimp_brush_core_create_bound_segs (brush_core, options);
 
   if (brush_core->brush_bound_segs)
-      gimp_brush_core_transform_bound_segs (brush_core, options);
+    gimp_brush_core_transform_bound_segs (brush_core, options);
 
   if (brush_core->transformed_brush_bound_segs)
     {
@@ -370,9 +364,9 @@ gimp_brush_tool_brush_changed (GimpContext   *context,
 }
 
 static void
-gimp_brush_tool_brush_transformed  (GimpPaintOptions *options,
-                                    GParamSpec       *pspec,
-                                    GimpBrushTool    *brush_tool)
+gimp_brush_tool_brush_transformed (GimpPaintOptions *options,
+                                   GParamSpec       *pspec,
+                                   GimpBrushTool    *brush_tool)
 {
   GimpPaintTool *paint_tool = GIMP_PAINT_TOOL (brush_tool);
   GimpBrushCore *brush_core = GIMP_BRUSH_CORE (paint_tool->core);



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