From 20a9bf08f51351e1e0a9de94f184ff56cd572665 Mon Sep 17 00:00:00 2001 From: Adam Frisby Date: Thu, 1 May 2008 18:04:42 +0000 Subject: * Rolled back a few changes. --- OpenSim/Region/Environment/Scenes/UndoState.cs | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) (limited to 'OpenSim/Region/Environment/Scenes/UndoState.cs') diff --git a/OpenSim/Region/Environment/Scenes/UndoState.cs b/OpenSim/Region/Environment/Scenes/UndoState.cs index f16bb34..daabd8d 100644 --- a/OpenSim/Region/Environment/Scenes/UndoState.cs +++ b/OpenSim/Region/Environment/Scenes/UndoState.cs @@ -32,8 +32,8 @@ namespace OpenSim.Region.Environment.Scenes public class UndoState { public LLVector3 Position = LLVector3.Zero; - public LLQuaternion Rotation = LLQuaternion.Identity; public LLVector3 Scale = LLVector3.Zero; + public LLQuaternion Rotation = LLQuaternion.Identity; public UndoState(LLVector3 pos, LLQuaternion rot, LLVector3 scale) { @@ -41,7 +41,7 @@ namespace OpenSim.Region.Environment.Scenes Rotation = rot; Scale = scale; } - + public UndoState(SceneObjectPart part) { if (part != null) @@ -50,20 +50,18 @@ namespace OpenSim.Region.Environment.Scenes { Position = part.AbsolutePosition; Rotation = part.RotationOffset; + } else { Position = part.GroupPosition; Rotation = part.RotationOffset; Scale = part.Shape.Scale; + } } } - public UndoState() - { - } - public bool Compare(SceneObjectPart part) { if (part != null) @@ -81,6 +79,7 @@ namespace OpenSim.Region.Environment.Scenes return true; else return false; + } } return false; @@ -91,7 +90,7 @@ namespace OpenSim.Region.Environment.Scenes if (part != null) { part.m_undoing = true; - + if (part.ParentID == 0) { part.ParentGroup.AbsolutePosition = Position; @@ -106,7 +105,12 @@ namespace OpenSim.Region.Environment.Scenes part.ScheduleTerseUpdate(); } part.m_undoing = false; + } } + + public UndoState() + { + } } -} \ No newline at end of file +} -- cgit v1.1