diff options
author | Justin Clark-Casey (justincc) | 2011-07-19 04:15:27 +0100 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2011-07-19 04:15:27 +0100 |
commit | 97f1edfd95176415d0e0b3169467655522334804 (patch) | |
tree | c4551d9d2ef141b12d61d038a4c88cda5610c6e1 /OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs | |
parent | Rename UpdatePrimRotation() to UpdatePrimGroupRotation() since this is what i... (diff) | |
download | opensim-SC-97f1edfd95176415d0e0b3169467655522334804.zip opensim-SC-97f1edfd95176415d0e0b3169467655522334804.tar.gz opensim-SC-97f1edfd95176415d0e0b3169467655522334804.tar.bz2 opensim-SC-97f1edfd95176415d0e0b3169467655522334804.tar.xz |
Fix undo of prim group rotation.
This isn't that great since I think I broke it a few commits earlier.
Undo of rotation of individual prims in a linkset is still broken
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs index 3adeef1..aa1f7bc 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs | |||
@@ -2895,9 +2895,11 @@ namespace OpenSim.Region.Framework.Scenes | |||
2895 | // m_log.DebugFormat( | 2895 | // m_log.DebugFormat( |
2896 | // "[SCENE OBJECT GROUP]: Updating group rotation R of {0} {1} to {2}", Name, LocalId, rot); | 2896 | // "[SCENE OBJECT GROUP]: Updating group rotation R of {0} {1} to {2}", Name, LocalId, rot); |
2897 | 2897 | ||
2898 | SceneObjectPart[] parts = m_parts.GetArray(); | 2898 | // SceneObjectPart[] parts = m_parts.GetArray(); |
2899 | for (int i = 0; i < parts.Length; i++) | 2899 | // for (int i = 0; i < parts.Length; i++) |
2900 | parts[i].StoreUndoState(); | 2900 | // parts[i].StoreUndoState(); |
2901 | |||
2902 | m_rootPart.StoreUndoState(true); | ||
2901 | 2903 | ||
2902 | m_rootPart.UpdateRotation(rot); | 2904 | m_rootPart.UpdateRotation(rot); |
2903 | 2905 | ||
@@ -2922,9 +2924,12 @@ namespace OpenSim.Region.Framework.Scenes | |||
2922 | // m_log.DebugFormat( | 2924 | // m_log.DebugFormat( |
2923 | // "[SCENE OBJECT GROUP]: Updating group rotation PR of {0} {1} to {2}", Name, LocalId, rot); | 2925 | // "[SCENE OBJECT GROUP]: Updating group rotation PR of {0} {1} to {2}", Name, LocalId, rot); |
2924 | 2926 | ||
2925 | SceneObjectPart[] parts = m_parts.GetArray(); | 2927 | // SceneObjectPart[] parts = m_parts.GetArray(); |
2926 | for (int i = 0; i < parts.Length; i++) | 2928 | // for (int i = 0; i < parts.Length; i++) |
2927 | parts[i].StoreUndoState(); | 2929 | // parts[i].StoreUndoState(); |
2930 | |||
2931 | RootPart.StoreUndoState(true); | ||
2932 | RootPart.IgnoreUndoUpdate = true; | ||
2928 | 2933 | ||
2929 | m_rootPart.UpdateRotation(rot); | 2934 | m_rootPart.UpdateRotation(rot); |
2930 | 2935 | ||
@@ -2939,6 +2944,8 @@ namespace OpenSim.Region.Framework.Scenes | |||
2939 | 2944 | ||
2940 | HasGroupChanged = true; | 2945 | HasGroupChanged = true; |
2941 | ScheduleGroupForTerseUpdate(); | 2946 | ScheduleGroupForTerseUpdate(); |
2947 | |||
2948 | RootPart.IgnoreUndoUpdate = false; | ||
2942 | } | 2949 | } |
2943 | 2950 | ||
2944 | /// <summary> | 2951 | /// <summary> |