aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2011-07-16 05:23:21 +0100
committerJustin Clark-Casey (justincc)2011-07-16 05:23:21 +0100
commitf5ddf37112d4881243e3350d5df898c6b2bb02ae (patch)
tree72fe5fb9c4a3558fc0ffcc801e3040595ef77d39 /OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
parentremove now unncessary parts of SceneObjectGroup.Resize() (diff)
downloadopensim-SC_OLD-f5ddf37112d4881243e3350d5df898c6b2bb02ae.zip
opensim-SC_OLD-f5ddf37112d4881243e3350d5df898c6b2bb02ae.tar.gz
opensim-SC_OLD-f5ddf37112d4881243e3350d5df898c6b2bb02ae.tar.bz2
opensim-SC_OLD-f5ddf37112d4881243e3350d5df898c6b2bb02ae.tar.xz
Replace ifs in SOG.GroupResize() with Math.Min()
Also fiddle a bit with undo. This is not currently working properly, though to be fair it also didn't appear to work in 0.7.1.1 either (at least for resize). Will get some more attention soon.
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/SceneObjectPart.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectPart.cs18
1 files changed, 17 insertions, 1 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
index f5b8daf..6b9607c 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
@@ -3687,6 +3687,8 @@ namespace OpenSim.Region.Framework.Scenes
3687 { 3687 {
3688 if (m_parentGroup != null) 3688 if (m_parentGroup != null)
3689 { 3689 {
3690// m_log.DebugFormat("[SCENE OBJECT PART]: Storing undo state for {0} {1}", Name, LocalId);
3691
3690 lock (m_undo) 3692 lock (m_undo)
3691 { 3693 {
3692 if (m_undo.Count > 0) 3694 if (m_undo.Count > 0)
@@ -3705,11 +3707,18 @@ namespace OpenSim.Region.Framework.Scenes
3705 3707
3706 m_undo.Push(nUndo); 3708 m_undo.Push(nUndo);
3707 } 3709 }
3708
3709 } 3710 }
3710 } 3711 }
3711 } 3712 }
3713// else
3714// {
3715// m_log.DebugFormat("[SCENE OBJECT PART]: Ignoring undo store for {0} {1}", Name, LocalId);
3716// }
3712 } 3717 }
3718// else
3719// {
3720// m_log.DebugFormat("[SCENE OBJECT PART]: Ignoring undo store for {0} {1} since already undoing", Name, LocalId);
3721// }
3713 } 3722 }
3714 3723
3715 public EntityIntersection TestIntersection(Ray iray, Quaternion parentrot) 3724 public EntityIntersection TestIntersection(Ray iray, Quaternion parentrot)
@@ -4179,11 +4188,14 @@ namespace OpenSim.Region.Framework.Scenes
4179 if (m_undo.Count > 0) 4188 if (m_undo.Count > 0)
4180 { 4189 {
4181 UndoState nUndo = null; 4190 UndoState nUndo = null;
4191
4182 if (m_parentGroup.GetSceneMaxUndo() > 0) 4192 if (m_parentGroup.GetSceneMaxUndo() > 0)
4183 { 4193 {
4184 nUndo = new UndoState(this); 4194 nUndo = new UndoState(this);
4185 } 4195 }
4196
4186 UndoState goback = m_undo.Pop(); 4197 UndoState goback = m_undo.Pop();
4198
4187 if (goback != null) 4199 if (goback != null)
4188 { 4200 {
4189 goback.PlaybackState(this); 4201 goback.PlaybackState(this);
@@ -4196,6 +4208,8 @@ namespace OpenSim.Region.Framework.Scenes
4196 4208
4197 public void Redo() 4209 public void Redo()
4198 { 4210 {
4211// m_log.DebugFormat("[SCENE OBJECT PART]: Handling redo request for {0} {1}", Name, LocalId);
4212
4199 lock (m_redo) 4213 lock (m_redo)
4200 { 4214 {
4201 if (m_parentGroup.GetSceneMaxUndo() > 0) 4215 if (m_parentGroup.GetSceneMaxUndo() > 0)
@@ -4204,7 +4218,9 @@ namespace OpenSim.Region.Framework.Scenes
4204 4218
4205 m_undo.Push(nUndo); 4219 m_undo.Push(nUndo);
4206 } 4220 }
4221
4207 UndoState gofwd = m_redo.Pop(); 4222 UndoState gofwd = m_redo.Pop();
4223
4208 if (gofwd != null) 4224 if (gofwd != null)
4209 gofwd.PlayfwdState(this); 4225 gofwd.PlayfwdState(this);
4210 } 4226 }