From 62d1eba3b2cf1ff9e43e64a22d27b1ee73e6c2c6 Mon Sep 17 00:00:00 2001 From: Justin Clarke Casey Date: Fri, 12 Sep 2008 20:42:04 +0000 Subject: * Patch http://opensimulator.org/mantis/view.php?id=2167 * Force ClickAction persistence even if other object properties are not edited * Thanks nlin! --- OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) (limited to 'OpenSim/Region/ClientStack/LindenUDP') diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs index 6235381..57a995c 100644 --- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs @@ -170,6 +170,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP private ObjectSelect handlerDeGrabObject = null; //OnDeGrabObject; private GenericCall7 handlerObjectDescription = null; private GenericCall7 handlerObjectName = null; + private GenericCall7 handlerObjectClickAction = null; private ObjectPermissions handlerObjectPermissions = null; private RequestObjectPropertiesFamily handlerRequestObjectPropertiesFamily = null; //OnRequestObjectPropertiesFamily; private TextureRequest handlerTextureRequest = null; @@ -864,6 +865,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP public event ObjectDeselect OnObjectDeselect; public event GenericCall7 OnObjectDescription; public event GenericCall7 OnObjectName; + public event GenericCall7 OnObjectClickAction; public event ObjectIncludeInSearch OnObjectIncludeInSearch; public event RequestObjectPropertiesFamily OnRequestObjectPropertiesFamily; public event UpdatePrimFlags OnUpdatePrimFlags; @@ -4774,16 +4776,17 @@ namespace OpenSim.Region.ClientStack.LindenUDP case PacketType.ObjectClickAction: ObjectClickActionPacket ocpacket = (ObjectClickActionPacket)Pack; - Scene tScene = (Scene)m_scene; - foreach (ObjectClickActionPacket.ObjectDataBlock odata in ocpacket.ObjectData) + handlerObjectClickAction = OnObjectClickAction; + if(handlerObjectClickAction != null) { - byte action = odata.ClickAction; - uint localId = odata.ObjectLocalID; - SceneObjectPart part = tScene.GetSceneObjectPart(localId); - part.ClickAction = action; + foreach (ObjectClickActionPacket.ObjectDataBlock odata in ocpacket.ObjectData) + { + byte action = odata.ClickAction; + uint localID = odata.ObjectLocalID; + handlerObjectClickAction(this, localID, action.ToString()); + } } - break; #endregion -- cgit v1.1