From 9880a9ec51c140f81c5ab02eb1662069313cfc35 Mon Sep 17 00:00:00 2001 From: Henry de Jongh Date: Mon, 16 Apr 2018 23:07:35 +0200 Subject: [PATCH] Revert "2DSE extruding brush can be undone properly. Fixes #87." This reverts commit 05019dd374a2268af1b523d2acb21841f9cfa676. --- .../ShapeEditor/ShapeEditorBrush.cs | 27 ------------------- 1 file changed, 27 deletions(-) diff --git a/Scripts/Brushes/CompoundBrushes/ShapeEditor/ShapeEditorBrush.cs b/Scripts/Brushes/CompoundBrushes/ShapeEditor/ShapeEditorBrush.cs index 4b87b8f4..6a8a35ab 100644 --- a/Scripts/Brushes/CompoundBrushes/ShapeEditor/ShapeEditorBrush.cs +++ b/Scripts/Brushes/CompoundBrushes/ShapeEditor/ShapeEditorBrush.cs @@ -284,18 +284,6 @@ public override void Invalidate(bool polygonsChanged) UpdateGeneratedHierarchyName(); } - /// - /// Called when undo or redo is performed in the editor. - /// - public override void OnUndoRedoPerformed() - { - // reset our cached polygon data. - isDirty = true; - m_LastBuiltPolygons = null; - // the base method will invalidate this compound brush. - base.OnUndoRedoPerformed(); - } - /// /// Gets the next segment. /// @@ -695,9 +683,6 @@ public Project GetEmbeddedProject() /// The project to be copied into the brush. public void CreatePolygon(Project project) { -#if UNITY_EDITOR - UnityEditor.Undo.RecordObject(this, "Create Polygon"); -#endif // store a project copy inside of this brush. this.project = project.Clone(); // store the extrude mode inside of this brush. @@ -715,9 +700,6 @@ public void CreatePolygon(Project project) /// The project to be copied into the brush. public void RevolveShape(Project project) { -#if UNITY_EDITOR - UnityEditor.Undo.RecordObject(this, "Revolve Shape"); -#endif // store a project copy inside of this brush. this.project = project.Clone(); // store the extrude mode inside of this brush. @@ -735,9 +717,6 @@ public void RevolveShape(Project project) /// The project to be copied into the brush. public void ExtrudeShape(Project project) { -#if UNITY_EDITOR - UnityEditor.Undo.RecordObject(this, "Extrude Shape"); -#endif // store a project copy inside of this brush. this.project = project.Clone(); // store the extrude mode inside of this brush. @@ -755,9 +734,6 @@ public void ExtrudeShape(Project project) /// The project to be copied into the brush. public void ExtrudePoint(Project project) { -#if UNITY_EDITOR - UnityEditor.Undo.RecordObject(this, "Extrude Point"); -#endif // store a project copy inside of this brush. this.project = project.Clone(); // store the extrude mode inside of this brush. @@ -776,9 +752,6 @@ public void ExtrudePoint(Project project) /// The project to be copied into the brush. public void ExtrudeBevel(Project project) { -#if UNITY_EDITOR - UnityEditor.Undo.RecordObject(this, "Extrude Bevel"); -#endif // if the depth and clip depth are identical, extrude a point instead. if (project.extrudeDepth.EqualsWithEpsilon(project.extrudeClipDepth)) {