diff options
author | CasperW | 2009-12-23 14:15:27 +0100 |
---|---|---|
committer | CasperW | 2009-12-23 14:15:27 +0100 |
commit | c54e0953d09f74be65f7f1939af16afcb8ade054 (patch) | |
tree | 30fdda415425190bb50a752d7b84f64e0a29db9b /OpenSim/Framework/Capabilities/Caps.cs | |
parent | Added some null reference and deleted group checks to certain functions to fi... (diff) | |
parent | Merge branch 'master' into careminster (diff) | |
download | opensim-SC-c54e0953d09f74be65f7f1939af16afcb8ade054.zip opensim-SC-c54e0953d09f74be65f7f1939af16afcb8ade054.tar.gz opensim-SC-c54e0953d09f74be65f7f1939af16afcb8ade054.tar.bz2 opensim-SC-c54e0953d09f74be65f7f1939af16afcb8ade054.tar.xz |
Merge branch 'master' of ssh://TOR/var/git/careminster
Diffstat (limited to 'OpenSim/Framework/Capabilities/Caps.cs')
-rw-r--r-- | OpenSim/Framework/Capabilities/Caps.cs | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/OpenSim/Framework/Capabilities/Caps.cs b/OpenSim/Framework/Capabilities/Caps.cs index 1f1ac78..74c6ab0 100644 --- a/OpenSim/Framework/Capabilities/Caps.cs +++ b/OpenSim/Framework/Capabilities/Caps.cs | |||
@@ -46,7 +46,7 @@ namespace OpenSim.Framework.Capabilities | |||
46 | 46 | ||
47 | public delegate UUID UpdateItem(UUID itemID, byte[] data); | 47 | public delegate UUID UpdateItem(UUID itemID, byte[] data); |
48 | 48 | ||
49 | public delegate void UpdateTaskScript(UUID itemID, UUID primID, bool isScriptRunning, byte[] data); | 49 | public delegate void UpdateTaskScript(UUID itemID, UUID primID, bool isScriptRunning, byte[] data, ref ArrayList errors); |
50 | 50 | ||
51 | public delegate void NewInventoryItem(UUID userID, InventoryItemBase item); | 51 | public delegate void NewInventoryItem(UUID userID, InventoryItemBase item); |
52 | 52 | ||
@@ -54,7 +54,7 @@ namespace OpenSim.Framework.Capabilities | |||
54 | 54 | ||
55 | public delegate UUID ItemUpdatedCallback(UUID userID, UUID itemID, byte[] data); | 55 | public delegate UUID ItemUpdatedCallback(UUID userID, UUID itemID, byte[] data); |
56 | 56 | ||
57 | public delegate void TaskScriptUpdatedCallback(UUID userID, UUID itemID, UUID primID, | 57 | public delegate ArrayList TaskScriptUpdatedCallback(UUID userID, UUID itemID, UUID primID, |
58 | bool isScriptRunning, byte[] data); | 58 | bool isScriptRunning, byte[] data); |
59 | 59 | ||
60 | public delegate InventoryCollection FetchInventoryDescendentsCAPS(UUID agentID, UUID folderID, UUID ownerID, | 60 | public delegate InventoryCollection FetchInventoryDescendentsCAPS(UUID agentID, UUID folderID, UUID ownerID, |
@@ -940,11 +940,13 @@ namespace OpenSim.Framework.Capabilities | |||
940 | /// <param name="primID">Prim containing item to update</param> | 940 | /// <param name="primID">Prim containing item to update</param> |
941 | /// <param name="isScriptRunning">Signals whether the script to update is currently running</param> | 941 | /// <param name="isScriptRunning">Signals whether the script to update is currently running</param> |
942 | /// <param name="data">New asset data</param> | 942 | /// <param name="data">New asset data</param> |
943 | public void TaskScriptUpdated(UUID itemID, UUID primID, bool isScriptRunning, byte[] data) | 943 | public void TaskScriptUpdated(UUID itemID, UUID primID, bool isScriptRunning, byte[] data, ref ArrayList errors) |
944 | { | 944 | { |
945 | if (TaskScriptUpdatedCall != null) | 945 | if (TaskScriptUpdatedCall != null) |
946 | { | 946 | { |
947 | TaskScriptUpdatedCall(m_agentID, itemID, primID, isScriptRunning, data); | 947 | ArrayList e = TaskScriptUpdatedCall(m_agentID, itemID, primID, isScriptRunning, data); |
948 | foreach (Object item in e) | ||
949 | errors.Add(item); | ||
948 | } | 950 | } |
949 | } | 951 | } |
950 | 952 | ||
@@ -1174,17 +1176,20 @@ namespace OpenSim.Framework.Capabilities | |||
1174 | // data, path, param)); | 1176 | // data, path, param)); |
1175 | 1177 | ||
1176 | string res = String.Empty; | 1178 | string res = String.Empty; |
1177 | LLSDTaskInventoryUploadComplete uploadComplete = new LLSDTaskInventoryUploadComplete(); | 1179 | LLSDTaskScriptUploadComplete uploadComplete = new LLSDTaskScriptUploadComplete(); |
1178 | 1180 | ||
1181 | ArrayList errors = new ArrayList(); | ||
1179 | handlerUpdateTaskScript = OnUpLoad; | 1182 | handlerUpdateTaskScript = OnUpLoad; |
1180 | if (handlerUpdateTaskScript != null) | 1183 | if (handlerUpdateTaskScript != null) |
1181 | { | 1184 | { |
1182 | handlerUpdateTaskScript(inventoryItemID, primID, isScriptRunning, data); | 1185 | handlerUpdateTaskScript(inventoryItemID, primID, isScriptRunning, data, ref errors); |
1183 | } | 1186 | } |
1184 | 1187 | ||
1185 | uploadComplete.item_id = inventoryItemID; | 1188 | uploadComplete.new_asset = inventoryItemID; |
1186 | uploadComplete.task_id = primID; | 1189 | uploadComplete.compiled = errors.Count > 0 ? false : true; |
1187 | uploadComplete.state = "complete"; | 1190 | uploadComplete.state = "complete"; |
1191 | uploadComplete.errors = new OSDArray(); | ||
1192 | uploadComplete.errors.Array = errors; | ||
1188 | 1193 | ||
1189 | res = LLSDHelpers.SerialiseLLSDReply(uploadComplete); | 1194 | res = LLSDHelpers.SerialiseLLSDReply(uploadComplete); |
1190 | 1195 | ||