diff --git a/src/metabrushes/MetaBrush/Action.hs b/src/metabrushes/MetaBrush/Action.hs index 2a37cd1..7f80e05 100644 --- a/src/metabrushes/MetaBrush/Action.hs +++ b/src/metabrushes/MetaBrush/Action.hs @@ -974,9 +974,6 @@ applyBrushWidgetAction pressingCtrl pressingAlt c mbPrevAction doc@( Document { ( StrokeMetadata { strokeVisible, strokeLocked } ) | strokeVisible , not strokeLocked - -- If we have already started a widget action, only continue an action - -- for the stroke with the correct unique. - , case mbPrevAction of { Just ( ABrushWidgetActionState act ) -> brushWidgetStrokeUnique act == u; Nothing -> True } -- Don't touch strokes without brushes. , Just ( brush@( NamedBrush {} ) :: NamedBrush brushFields ) <- strokeBrush , Intersection { inject2 = updateBrushParams, project1 = ptParamsToUsedParams } @@ -1108,13 +1105,16 @@ applyBrushWidgetAction pressingCtrl pressingAlt c mbPrevAction doc@( Document { Just ( ABrushWidgetActionState @brushFields' prevAction@( BrushWidgetActionState { brushWidgetPointBeingMoved = oldPt + , brushWidgetStrokeUnique = actionUniq , brushWidgetPointIndex = j' , brushWidgetAction = act } ) ) -> if | Just Refl <- eqT @brushFields @brushFields' + , uniq == actionUniq , j == j' -- Continue the current brush widget action, - -- at the point with the correct index in the stroke. + -- but only for the right stroke and only at the point with + -- the correct index within the stroke. -> do let newPt = pointCoords pt --> c