Set a default creation date on inventory and task inventory items

0.6.0-stable
Melanie Thielker 2008-10-21 00:44:57 +00:00
parent 81e220af8d
commit 5865a2b8f8
2 changed files with 11 additions and 0 deletions

View File

@ -25,6 +25,7 @@
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
using System;
using OpenMetaverse;
namespace OpenSim.Framework
@ -236,5 +237,10 @@ namespace OpenSim.Framework
get { return _creationDate; }
set { _creationDate = value; }
}
public InventoryItemBase()
{
_creationDate = (int)(DateTime.UtcNow - new DateTime(1970, 1, 1)).TotalSeconds;
}
}
}

View File

@ -336,5 +336,10 @@ namespace OpenSim.Framework
_itemID = UUID.Random();
_parentPartID = partID;
}
public TaskInventoryItem()
{
_creationDate = (uint)(DateTime.UtcNow - new DateTime(1970, 1, 1)).TotalSeconds;
}
}
}