diff options
author | Dan Lake | 2012-02-02 17:44:11 -0800 |
---|---|---|
committer | Dan Lake | 2012-02-02 17:44:11 -0800 |
commit | 3257dbe76dff0a1e5842cafc75e4c2d09278deab (patch) | |
tree | 7f7d1a58ca910d8acefbd3bee0c3d096a59d8a43 /OpenSim/Framework | |
parent | ObjectAddedToScene event should be fired when duplicating objects (diff) | |
parent | Merge branch 'master' of melanie@opensimulator.org:/var/git/opensim (diff) | |
download | opensim-SC_OLD-3257dbe76dff0a1e5842cafc75e4c2d09278deab.zip opensim-SC_OLD-3257dbe76dff0a1e5842cafc75e4c2d09278deab.tar.gz opensim-SC_OLD-3257dbe76dff0a1e5842cafc75e4c2d09278deab.tar.bz2 opensim-SC_OLD-3257dbe76dff0a1e5842cafc75e4c2d09278deab.tar.xz |
Merge branch 'master' of ssh://opensimulator.org/var/git/opensim
Diffstat (limited to 'OpenSim/Framework')
-rw-r--r-- | OpenSim/Framework/IClientAPI.cs | 4 | ||||
-rw-r--r-- | OpenSim/Framework/ILandObject.cs | 4 | ||||
-rw-r--r-- | OpenSim/Framework/LandData.cs | 19 | ||||
-rw-r--r-- | OpenSim/Framework/Serialization/External/LandDataSerializer.cs | 13 | ||||
-rw-r--r-- | OpenSim/Framework/Serialization/Tests/LandDataSerializerTests.cs | 12 | ||||
-rw-r--r-- | OpenSim/Framework/TaskInventoryItem.cs | 11 |
6 files changed, 42 insertions, 21 deletions
diff --git a/OpenSim/Framework/IClientAPI.cs b/OpenSim/Framework/IClientAPI.cs index 1326fe9..dd3e656 100644 --- a/OpenSim/Framework/IClientAPI.cs +++ b/OpenSim/Framework/IClientAPI.cs | |||
@@ -177,7 +177,7 @@ namespace OpenSim.Framework | |||
177 | 177 | ||
178 | public delegate void ParcelAccessListUpdateRequest(UUID agentID, uint flags, | 178 | public delegate void ParcelAccessListUpdateRequest(UUID agentID, uint flags, |
179 | int landLocalID, UUID transactionID, int sequenceID, | 179 | int landLocalID, UUID transactionID, int sequenceID, |
180 | int sections, List<ParcelManager.ParcelAccessEntry> entries, | 180 | int sections, List<LandAccessEntry> entries, |
181 | IClientAPI remote_client); | 181 | IClientAPI remote_client); |
182 | 182 | ||
183 | public delegate void ParcelPropertiesRequest( | 183 | public delegate void ParcelPropertiesRequest( |
@@ -1251,7 +1251,7 @@ namespace OpenSim.Framework | |||
1251 | float simObjectBonusFactor, int parcelObjectCapacity, int simObjectCapacity, | 1251 | float simObjectBonusFactor, int parcelObjectCapacity, int simObjectCapacity, |
1252 | uint regionFlags); | 1252 | uint regionFlags); |
1253 | 1253 | ||
1254 | void SendLandAccessListData(List<UUID> avatars, uint accessFlag, int localLandID); | 1254 | void SendLandAccessListData(List<LandAccessEntry> accessList, uint accessFlag, int localLandID); |
1255 | void SendForceClientSelectObjects(List<uint> objectIDs); | 1255 | void SendForceClientSelectObjects(List<uint> objectIDs); |
1256 | void SendCameraConstraint(Vector4 ConstraintPlane); | 1256 | void SendCameraConstraint(Vector4 ConstraintPlane); |
1257 | void SendLandObjectOwners(LandData land, List<UUID> groups, Dictionary<UUID, int> ownersAndCount); | 1257 | void SendLandObjectOwners(LandData land, List<UUID> groups, Dictionary<UUID, int> ownersAndCount); |
diff --git a/OpenSim/Framework/ILandObject.cs b/OpenSim/Framework/ILandObject.cs index f75a990..dd73b3f 100644 --- a/OpenSim/Framework/ILandObject.cs +++ b/OpenSim/Framework/ILandObject.cs | |||
@@ -73,9 +73,9 @@ namespace OpenSim.Framework | |||
73 | bool IsRestrictedFromLand(UUID avatar); | 73 | bool IsRestrictedFromLand(UUID avatar); |
74 | void SendLandUpdateToClient(IClientAPI remote_client); | 74 | void SendLandUpdateToClient(IClientAPI remote_client); |
75 | void SendLandUpdateToClient(bool snap_selection, IClientAPI remote_client); | 75 | void SendLandUpdateToClient(bool snap_selection, IClientAPI remote_client); |
76 | List<UUID> CreateAccessListArrayByFlag(AccessList flag); | 76 | List<LandAccessEntry> CreateAccessListArrayByFlag(AccessList flag); |
77 | void SendAccessList(UUID agentID, UUID sessionID, uint flags, int sequenceID, IClientAPI remote_client); | 77 | void SendAccessList(UUID agentID, UUID sessionID, uint flags, int sequenceID, IClientAPI remote_client); |
78 | void UpdateAccessList(uint flags, UUID transactionID, int sequenceID, int sections, List<ParcelManager.ParcelAccessEntry> entries, IClientAPI remote_client); | 78 | void UpdateAccessList(uint flags, UUID transactionID, int sequenceID, int sections, List<LandAccessEntry> entries, IClientAPI remote_client); |
79 | void UpdateLandBitmapByteArray(); | 79 | void UpdateLandBitmapByteArray(); |
80 | void SetLandBitmapFromByteArray(); | 80 | void SetLandBitmapFromByteArray(); |
81 | bool[,] GetLandBitmap(); | 81 | bool[,] GetLandBitmap(); |
diff --git a/OpenSim/Framework/LandData.cs b/OpenSim/Framework/LandData.cs index c107143..58a80ef 100644 --- a/OpenSim/Framework/LandData.cs +++ b/OpenSim/Framework/LandData.cs | |||
@@ -34,6 +34,13 @@ using OpenMetaverse; | |||
34 | 34 | ||
35 | namespace OpenSim.Framework | 35 | namespace OpenSim.Framework |
36 | { | 36 | { |
37 | public struct LandAccessEntry | ||
38 | { | ||
39 | public UUID AgentID; | ||
40 | public int Expires; | ||
41 | public AccessList Flags; | ||
42 | } | ||
43 | |||
37 | /// <summary> | 44 | /// <summary> |
38 | /// Details of a Parcel of land | 45 | /// Details of a Parcel of land |
39 | /// </summary> | 46 | /// </summary> |
@@ -73,7 +80,7 @@ namespace OpenSim.Framework | |||
73 | private string _mediaURL = String.Empty; | 80 | private string _mediaURL = String.Empty; |
74 | private string _musicURL = String.Empty; | 81 | private string _musicURL = String.Empty; |
75 | private UUID _ownerID = UUID.Zero; | 82 | private UUID _ownerID = UUID.Zero; |
76 | private List<ParcelManager.ParcelAccessEntry> _parcelAccessList = new List<ParcelManager.ParcelAccessEntry>(); | 83 | private List<LandAccessEntry> _parcelAccessList = new List<LandAccessEntry>(); |
77 | private float _passHours = 0; | 84 | private float _passHours = 0; |
78 | private int _passPrice = 0; | 85 | private int _passPrice = 0; |
79 | private int _salePrice = 0; //Unemeplemented. Parcels price. | 86 | private int _salePrice = 0; //Unemeplemented. Parcels price. |
@@ -450,7 +457,7 @@ namespace OpenSim.Framework | |||
450 | /// <summary> | 457 | /// <summary> |
451 | /// List of access data for the parcel. User data, some bitflags, and a time | 458 | /// List of access data for the parcel. User data, some bitflags, and a time |
452 | /// </summary> | 459 | /// </summary> |
453 | public List<ParcelManager.ParcelAccessEntry> ParcelAccessList { | 460 | public List<LandAccessEntry> ParcelAccessList { |
454 | get { | 461 | get { |
455 | return _parcelAccessList; | 462 | return _parcelAccessList; |
456 | } | 463 | } |
@@ -638,12 +645,12 @@ namespace OpenSim.Framework | |||
638 | landData._simwidePrims = _simwidePrims; | 645 | landData._simwidePrims = _simwidePrims; |
639 | 646 | ||
640 | landData._parcelAccessList.Clear(); | 647 | landData._parcelAccessList.Clear(); |
641 | foreach (ParcelManager.ParcelAccessEntry entry in _parcelAccessList) | 648 | foreach (LandAccessEntry entry in _parcelAccessList) |
642 | { | 649 | { |
643 | ParcelManager.ParcelAccessEntry newEntry = new ParcelManager.ParcelAccessEntry(); | 650 | LandAccessEntry newEntry = new LandAccessEntry(); |
644 | newEntry.AgentID = entry.AgentID; | 651 | newEntry.AgentID = entry.AgentID; |
645 | newEntry.Flags = entry.Flags; | 652 | newEntry.Flags = entry.Flags; |
646 | newEntry.Time = entry.Time; | 653 | newEntry.Expires = entry.Expires; |
647 | 654 | ||
648 | landData._parcelAccessList.Add(newEntry); | 655 | landData._parcelAccessList.Add(newEntry); |
649 | } | 656 | } |
@@ -668,4 +675,4 @@ namespace OpenSim.Framework | |||
668 | return land; | 675 | return land; |
669 | } | 676 | } |
670 | } | 677 | } |
671 | } \ No newline at end of file | 678 | } |
diff --git a/OpenSim/Framework/Serialization/External/LandDataSerializer.cs b/OpenSim/Framework/Serialization/External/LandDataSerializer.cs index fc0387b..3ae9a8e 100644 --- a/OpenSim/Framework/Serialization/External/LandDataSerializer.cs +++ b/OpenSim/Framework/Serialization/External/LandDataSerializer.cs | |||
@@ -90,7 +90,7 @@ namespace OpenSim.Framework.Serialization.External | |||
90 | landData.MusicURL = xtr.ReadElementString("MusicURL"); | 90 | landData.MusicURL = xtr.ReadElementString("MusicURL"); |
91 | landData.OwnerID = UUID.Parse( xtr.ReadElementString("OwnerID")); | 91 | landData.OwnerID = UUID.Parse( xtr.ReadElementString("OwnerID")); |
92 | 92 | ||
93 | landData.ParcelAccessList = new List<ParcelManager.ParcelAccessEntry>(); | 93 | landData.ParcelAccessList = new List<LandAccessEntry>(); |
94 | xtr.Read(); | 94 | xtr.Read(); |
95 | if (xtr.Name != "ParcelAccessList") | 95 | if (xtr.Name != "ParcelAccessList") |
96 | throw new XmlException(String.Format("Expected \"ParcelAccessList\" element but got \"{0}\"", xtr.Name)); | 96 | throw new XmlException(String.Format("Expected \"ParcelAccessList\" element but got \"{0}\"", xtr.Name)); |
@@ -99,11 +99,14 @@ namespace OpenSim.Framework.Serialization.External | |||
99 | { | 99 | { |
100 | while (xtr.Read() && xtr.NodeType != XmlNodeType.EndElement) | 100 | while (xtr.Read() && xtr.NodeType != XmlNodeType.EndElement) |
101 | { | 101 | { |
102 | ParcelManager.ParcelAccessEntry pae = new ParcelManager.ParcelAccessEntry(); | 102 | LandAccessEntry pae = new LandAccessEntry(); |
103 | 103 | ||
104 | xtr.ReadStartElement("ParcelAccessEntry"); | 104 | xtr.ReadStartElement("ParcelAccessEntry"); |
105 | pae.AgentID = UUID.Parse( xtr.ReadElementString("AgentID")); | 105 | pae.AgentID = UUID.Parse( xtr.ReadElementString("AgentID")); |
106 | pae.Time = Convert.ToDateTime( xtr.ReadElementString("Time")); | 106 | // We really don't care about temp vs perm here and this |
107 | // would break on old oars. Assume all bans are perm | ||
108 | xtr.ReadElementString("Time"); | ||
109 | pae.Expires = 0; // Convert.ToUint( xtr.ReadElementString("Time")); | ||
107 | pae.Flags = (AccessList)Convert.ToUInt32( xtr.ReadElementString("AccessList")); | 110 | pae.Flags = (AccessList)Convert.ToUInt32( xtr.ReadElementString("AccessList")); |
108 | xtr.ReadEndElement(); | 111 | xtr.ReadEndElement(); |
109 | 112 | ||
@@ -162,11 +165,11 @@ namespace OpenSim.Framework.Serialization.External | |||
162 | xtw.WriteElementString("OwnerID", landData.OwnerID.ToString()); | 165 | xtw.WriteElementString("OwnerID", landData.OwnerID.ToString()); |
163 | 166 | ||
164 | xtw.WriteStartElement("ParcelAccessList"); | 167 | xtw.WriteStartElement("ParcelAccessList"); |
165 | foreach (ParcelManager.ParcelAccessEntry pal in landData.ParcelAccessList) | 168 | foreach (LandAccessEntry pal in landData.ParcelAccessList) |
166 | { | 169 | { |
167 | xtw.WriteStartElement("ParcelAccessEntry"); | 170 | xtw.WriteStartElement("ParcelAccessEntry"); |
168 | xtw.WriteElementString("AgentID", pal.AgentID.ToString()); | 171 | xtw.WriteElementString("AgentID", pal.AgentID.ToString()); |
169 | xtw.WriteElementString("Time", pal.Time.ToString("s")); | 172 | xtw.WriteElementString("Time", pal.Expires.ToString()); |
170 | xtw.WriteElementString("AccessList", Convert.ToString((uint)pal.Flags)); | 173 | xtw.WriteElementString("AccessList", Convert.ToString((uint)pal.Flags)); |
171 | xtw.WriteEndElement(); | 174 | xtw.WriteEndElement(); |
172 | } | 175 | } |
diff --git a/OpenSim/Framework/Serialization/Tests/LandDataSerializerTests.cs b/OpenSim/Framework/Serialization/Tests/LandDataSerializerTests.cs index c69c89d..3607ce8 100644 --- a/OpenSim/Framework/Serialization/Tests/LandDataSerializerTests.cs +++ b/OpenSim/Framework/Serialization/Tests/LandDataSerializerTests.cs | |||
@@ -42,7 +42,7 @@ namespace OpenSim.Framework.Serialization.Tests | |||
42 | private LandData landWithParcelAccessList; | 42 | private LandData landWithParcelAccessList; |
43 | 43 | ||
44 | private static string preSerialized = "<?xml version=\"1.0\" encoding=\"utf-16\"?>\n<LandData>\n <Area>128</Area>\n <AuctionID>0</AuctionID>\n <AuthBuyerID>00000000-0000-0000-0000-000000000000</AuthBuyerID>\n <Category>10</Category>\n <ClaimDate>0</ClaimDate>\n <ClaimPrice>0</ClaimPrice>\n <GlobalID>54ff9641-dd40-4a2c-b1f1-47dd3af24e50</GlobalID>\n <GroupID>d740204e-bbbf-44aa-949d-02c7d739f6a5</GroupID>\n <IsGroupOwned>False</IsGroupOwned>\n <Bitmap>AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=</Bitmap>\n <Description>land data to test LandDataSerializer</Description>\n <Flags>536870944</Flags>\n <LandingType>2</LandingType>\n <Name>LandDataSerializerTest Land</Name>\n <Status>0</Status>\n <LocalID>0</LocalID>\n <MediaAutoScale>1</MediaAutoScale>\n <MediaID>d4452578-2f25-4b97-a81b-819af559cfd7</MediaID>\n <MediaURL>http://videos.opensimulator.org/bumblebee.mp4</MediaURL>\n <MusicURL />\n <OwnerID>1b8eedf9-6d15-448b-8015-24286f1756bf</OwnerID>\n <ParcelAccessList />\n <PassHours>0</PassHours>\n <PassPrice>0</PassPrice>\n <SalePrice>0</SalePrice>\n <SnapshotID>00000000-0000-0000-0000-000000000000</SnapshotID>\n <UserLocation><0, 0, 0></UserLocation>\n <UserLookAt><0, 0, 0></UserLookAt>\n <Dwell>0</Dwell>\n <OtherCleanTime>0</OtherCleanTime>\n</LandData>"; | 44 | private static string preSerialized = "<?xml version=\"1.0\" encoding=\"utf-16\"?>\n<LandData>\n <Area>128</Area>\n <AuctionID>0</AuctionID>\n <AuthBuyerID>00000000-0000-0000-0000-000000000000</AuthBuyerID>\n <Category>10</Category>\n <ClaimDate>0</ClaimDate>\n <ClaimPrice>0</ClaimPrice>\n <GlobalID>54ff9641-dd40-4a2c-b1f1-47dd3af24e50</GlobalID>\n <GroupID>d740204e-bbbf-44aa-949d-02c7d739f6a5</GroupID>\n <IsGroupOwned>False</IsGroupOwned>\n <Bitmap>AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=</Bitmap>\n <Description>land data to test LandDataSerializer</Description>\n <Flags>536870944</Flags>\n <LandingType>2</LandingType>\n <Name>LandDataSerializerTest Land</Name>\n <Status>0</Status>\n <LocalID>0</LocalID>\n <MediaAutoScale>1</MediaAutoScale>\n <MediaID>d4452578-2f25-4b97-a81b-819af559cfd7</MediaID>\n <MediaURL>http://videos.opensimulator.org/bumblebee.mp4</MediaURL>\n <MusicURL />\n <OwnerID>1b8eedf9-6d15-448b-8015-24286f1756bf</OwnerID>\n <ParcelAccessList />\n <PassHours>0</PassHours>\n <PassPrice>0</PassPrice>\n <SalePrice>0</SalePrice>\n <SnapshotID>00000000-0000-0000-0000-000000000000</SnapshotID>\n <UserLocation><0, 0, 0></UserLocation>\n <UserLookAt><0, 0, 0></UserLookAt>\n <Dwell>0</Dwell>\n <OtherCleanTime>0</OtherCleanTime>\n</LandData>"; |
45 | private static string preSerializedWithParcelAccessList = "<?xml version=\"1.0\" encoding=\"utf-16\"?>\n<LandData>\n <Area>128</Area>\n <AuctionID>0</AuctionID>\n <AuthBuyerID>00000000-0000-0000-0000-000000000000</AuthBuyerID>\n <Category>10</Category>\n <ClaimDate>0</ClaimDate>\n <ClaimPrice>0</ClaimPrice>\n <GlobalID>54ff9641-dd40-4a2c-b1f1-47dd3af24e50</GlobalID>\n <GroupID>d740204e-bbbf-44aa-949d-02c7d739f6a5</GroupID>\n <IsGroupOwned>False</IsGroupOwned>\n <Bitmap>AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=</Bitmap>\n <Description>land data to test LandDataSerializer</Description>\n <Flags>536870944</Flags>\n <LandingType>2</LandingType>\n <Name>LandDataSerializerTest Land</Name>\n <Status>0</Status>\n <LocalID>0</LocalID>\n <MediaAutoScale>1</MediaAutoScale>\n <MediaID>d4452578-2f25-4b97-a81b-819af559cfd7</MediaID>\n <MediaURL>http://videos.opensimulator.org/bumblebee.mp4</MediaURL>\n <MusicURL />\n <OwnerID>1b8eedf9-6d15-448b-8015-24286f1756bf</OwnerID>\n <ParcelAccessList>\n <ParcelAccessEntry>\n <AgentID>62d65d45-c91a-4f77-862c-46557d978b6c</AgentID>\n <Time>2009-10-01T00:00:00</Time>\n <AccessList>2</AccessList>\n </ParcelAccessEntry>\n <ParcelAccessEntry>\n <AgentID>ec2a8d18-2378-4fe0-8b68-2a31b57c481e</AgentID>\n <Time>2010-10-20T00:00:00</Time>\n <AccessList>1</AccessList>\n </ParcelAccessEntry>\n </ParcelAccessList>\n <PassHours>0</PassHours>\n <PassPrice>0</PassPrice>\n <SalePrice>0</SalePrice>\n <SnapshotID>00000000-0000-0000-0000-000000000000</SnapshotID>\n <UserLocation><0, 0, 0></UserLocation>\n <UserLookAt><0, 0, 0></UserLookAt>\n <Dwell>0</Dwell>\n <OtherCleanTime>0</OtherCleanTime>\n</LandData>"; | 45 | private static string preSerializedWithParcelAccessList = "<?xml version=\"1.0\" encoding=\"utf-16\"?>\n<LandData>\n <Area>128</Area>\n <AuctionID>0</AuctionID>\n <AuthBuyerID>00000000-0000-0000-0000-000000000000</AuthBuyerID>\n <Category>10</Category>\n <ClaimDate>0</ClaimDate>\n <ClaimPrice>0</ClaimPrice>\n <GlobalID>54ff9641-dd40-4a2c-b1f1-47dd3af24e50</GlobalID>\n <GroupID>d740204e-bbbf-44aa-949d-02c7d739f6a5</GroupID>\n <IsGroupOwned>False</IsGroupOwned>\n <Bitmap>AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=</Bitmap>\n <Description>land data to test LandDataSerializer</Description>\n <Flags>536870944</Flags>\n <LandingType>2</LandingType>\n <Name>LandDataSerializerTest Land</Name>\n <Status>0</Status>\n <LocalID>0</LocalID>\n <MediaAutoScale>1</MediaAutoScale>\n <MediaID>d4452578-2f25-4b97-a81b-819af559cfd7</MediaID>\n <MediaURL>http://videos.opensimulator.org/bumblebee.mp4</MediaURL>\n <MusicURL />\n <OwnerID>1b8eedf9-6d15-448b-8015-24286f1756bf</OwnerID>\n <ParcelAccessList>\n <ParcelAccessEntry>\n <AgentID>62d65d45-c91a-4f77-862c-46557d978b6c</AgentID>\n <Time>0</Time>\n <AccessList>2</AccessList>\n </ParcelAccessEntry>\n <ParcelAccessEntry>\n <AgentID>ec2a8d18-2378-4fe0-8b68-2a31b57c481e</AgentID>\n <Time>0</Time>\n <AccessList>1</AccessList>\n </ParcelAccessEntry>\n </ParcelAccessList>\n <PassHours>0</PassHours>\n <PassPrice>0</PassPrice>\n <SalePrice>0</SalePrice>\n <SnapshotID>00000000-0000-0000-0000-000000000000</SnapshotID>\n <UserLocation><0, 0, 0></UserLocation>\n <UserLookAt><0, 0, 0></UserLookAt>\n <Dwell>0</Dwell>\n <OtherCleanTime>0</OtherCleanTime>\n</LandData>"; |
46 | 46 | ||
47 | [SetUp] | 47 | [SetUp] |
48 | public void setup() | 48 | public void setup() |
@@ -73,16 +73,16 @@ namespace OpenSim.Framework.Serialization.Tests | |||
73 | this.landWithParcelAccessList = this.land.Copy(); | 73 | this.landWithParcelAccessList = this.land.Copy(); |
74 | this.landWithParcelAccessList.ParcelAccessList.Clear(); | 74 | this.landWithParcelAccessList.ParcelAccessList.Clear(); |
75 | 75 | ||
76 | ParcelManager.ParcelAccessEntry pae0 = new ParcelManager.ParcelAccessEntry(); | 76 | LandAccessEntry pae0 = new LandAccessEntry(); |
77 | pae0.AgentID = new UUID("62d65d45-c91a-4f77-862c-46557d978b6c"); | 77 | pae0.AgentID = new UUID("62d65d45-c91a-4f77-862c-46557d978b6c"); |
78 | pae0.Flags = AccessList.Ban; | 78 | pae0.Flags = AccessList.Ban; |
79 | pae0.Time = new DateTime(2009, 10, 01); | 79 | pae0.Expires = 0; |
80 | this.landWithParcelAccessList.ParcelAccessList.Add(pae0); | 80 | this.landWithParcelAccessList.ParcelAccessList.Add(pae0); |
81 | 81 | ||
82 | ParcelManager.ParcelAccessEntry pae1 = new ParcelManager.ParcelAccessEntry(); | 82 | LandAccessEntry pae1 = new LandAccessEntry(); |
83 | pae1.AgentID = new UUID("ec2a8d18-2378-4fe0-8b68-2a31b57c481e"); | 83 | pae1.AgentID = new UUID("ec2a8d18-2378-4fe0-8b68-2a31b57c481e"); |
84 | pae1.Flags = AccessList.Access; | 84 | pae1.Flags = AccessList.Access; |
85 | pae1.Time = new DateTime(2010, 10, 20); | 85 | pae1.Expires = 0; |
86 | this.landWithParcelAccessList.ParcelAccessList.Add(pae1); | 86 | this.landWithParcelAccessList.ParcelAccessList.Add(pae1); |
87 | } | 87 | } |
88 | 88 | ||
@@ -128,4 +128,4 @@ namespace OpenSim.Framework.Serialization.Tests | |||
128 | "Reified LandData.Name != original LandData.Name (pre-serialized with parcel access list)"); | 128 | "Reified LandData.Name != original LandData.Name (pre-serialized with parcel access list)"); |
129 | } | 129 | } |
130 | } | 130 | } |
131 | } \ No newline at end of file | 131 | } |
diff --git a/OpenSim/Framework/TaskInventoryItem.cs b/OpenSim/Framework/TaskInventoryItem.cs index ba2a306..d4bbbfb 100644 --- a/OpenSim/Framework/TaskInventoryItem.cs +++ b/OpenSim/Framework/TaskInventoryItem.cs | |||
@@ -65,6 +65,7 @@ namespace OpenSim.Framework | |||
65 | private int _permsMask; | 65 | private int _permsMask; |
66 | private int _type = 0; | 66 | private int _type = 0; |
67 | private UUID _oldID; | 67 | private UUID _oldID; |
68 | private UUID _loadedID = UUID.Zero; | ||
68 | 69 | ||
69 | private bool _ownerChanged = false; | 70 | private bool _ownerChanged = false; |
70 | 71 | ||
@@ -231,6 +232,15 @@ namespace OpenSim.Framework | |||
231 | } | 232 | } |
232 | } | 233 | } |
233 | 234 | ||
235 | public UUID LoadedItemID { | ||
236 | get { | ||
237 | return _loadedID; | ||
238 | } | ||
239 | set { | ||
240 | _loadedID = value; | ||
241 | } | ||
242 | } | ||
243 | |||
234 | public UUID LastOwnerID { | 244 | public UUID LastOwnerID { |
235 | get { | 245 | get { |
236 | return _lastOwnerID; | 246 | return _lastOwnerID; |
@@ -347,6 +357,7 @@ namespace OpenSim.Framework | |||
347 | /// <param name="partID">The new part ID to which this item belongs</param> | 357 | /// <param name="partID">The new part ID to which this item belongs</param> |
348 | public void ResetIDs(UUID partID) | 358 | public void ResetIDs(UUID partID) |
349 | { | 359 | { |
360 | LoadedItemID = OldItemID; | ||
350 | OldItemID = ItemID; | 361 | OldItemID = ItemID; |
351 | ItemID = UUID.Random(); | 362 | ItemID = UUID.Random(); |
352 | ParentPartID = partID; | 363 | ParentPartID = partID; |