diff options
author | Tom Grimshaw | 2010-07-04 19:28:39 -0700 |
---|---|---|
committer | Tom Grimshaw | 2010-07-04 19:28:39 -0700 |
commit | 5b68343361cbd000a2f024b37797ec235abb7207 (patch) | |
tree | a8977cb2d9392c83081675f24f8043a3cc56ad73 /OpenSim/Framework/UndoStack.cs | |
parent | Correct positioning of timeout modifier in the SynchronousRestObjectRequester (diff) | |
download | opensim-SC_OLD-5b68343361cbd000a2f024b37797ec235abb7207.zip opensim-SC_OLD-5b68343361cbd000a2f024b37797ec235abb7207.tar.gz opensim-SC_OLD-5b68343361cbd000a2f024b37797ec235abb7207.tar.bz2 opensim-SC_OLD-5b68343361cbd000a2f024b37797ec235abb7207.tar.xz |
The majority of the Undo fix. There is still an issue with Rotation which i'll address next; however position undo and scale undo should be working just fine now. Also removed some residual debug logging.
Diffstat (limited to 'OpenSim/Framework/UndoStack.cs')
-rw-r--r-- | OpenSim/Framework/UndoStack.cs | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/OpenSim/Framework/UndoStack.cs b/OpenSim/Framework/UndoStack.cs index 3799180..4cd779a 100644 --- a/OpenSim/Framework/UndoStack.cs +++ b/OpenSim/Framework/UndoStack.cs | |||
@@ -88,7 +88,14 @@ namespace OpenSim.Framework | |||
88 | 88 | ||
89 | public T Peek() | 89 | public T Peek() |
90 | { | 90 | { |
91 | return m_undolist[m_undolist.Count - 1]; | 91 | if (m_undolist.Count > 0) |
92 | { | ||
93 | return m_undolist[m_undolist.Count - 1]; | ||
94 | } | ||
95 | else | ||
96 | { | ||
97 | return default(T); | ||
98 | } | ||
92 | } | 99 | } |
93 | 100 | ||
94 | public void Clear() | 101 | public void Clear() |