From 9bfae21706288802f94d642eb252ac78b4d9e85c Mon Sep 17 00:00:00 2001 From: Dave SIMmONs Date: Mon, 2 May 2011 16:35:55 -0700 Subject: ER-858: Add viewer checkbox to toggle parcel privacy settings. Reviewed by Kelly --- indra/llinventory/llparcel.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'indra/llinventory/llparcel.cpp') diff --git a/indra/llinventory/llparcel.cpp b/indra/llinventory/llparcel.cpp index 0a4cd51ea0..7562bb8320 100644 --- a/indra/llinventory/llparcel.cpp +++ b/indra/llinventory/llparcel.cpp @@ -702,7 +702,7 @@ void LLParcel::packMessage(LLSD& msg) msg["user_location"] = ll_sd_from_vector3(mUserLocation); msg["user_look_at"] = ll_sd_from_vector3(mUserLookAt); msg["landing_type"] = (U8)mLandingType; - + msg["privacy"] = (LLSD::Boolean) getPrivacy(); } @@ -721,6 +721,14 @@ void LLParcel::unpackMessage(LLMessageSystem* msg) msg->getStringFast( _PREHASH_ParcelData,_PREHASH_MediaURL, buffer ); setMediaURL(buffer); + BOOL private_parcel = FALSE; + bool have_privacy_data = (msg->getSizeFast(_PREHASH_ParcelData, _PREHASH_Privacy) > 0); + if (have_privacy_data) + { + msg->getBOOLFast(_PREHASH_ParcelData, _PREHASH_Privacy, private_parcel); + } + setPrivacy((bool) private_parcel); + // non-optimized version msg->getU8 ( "ParcelData", "MediaAutoScale", mMediaAutoScale ); -- cgit v1.2.3 From 1a5b3b0a9091a72fd5e5fb395f7f0c97b0fd502c Mon Sep 17 00:00:00 2001 From: Dave SIMmONs Date: Tue, 24 May 2011 10:44:27 -0700 Subject: ER-914: Disable Parcel Privacy UI in viewer if on older sim --- indra/llinventory/llparcel.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'indra/llinventory/llparcel.cpp') diff --git a/indra/llinventory/llparcel.cpp b/indra/llinventory/llparcel.cpp index 7562bb8320..6236c0df6b 100644 --- a/indra/llinventory/llparcel.cpp +++ b/indra/llinventory/llparcel.cpp @@ -226,6 +226,9 @@ void LLParcel::init(const LLUUID &owner_id, setPreviousOwnerID(LLUUID::null); setPreviouslyGroupOwned(FALSE); + + setPrivacy(false); + setHavePrivacyData(false); } void LLParcel::overrideOwner(const LLUUID& owner_id, BOOL is_group_owned) @@ -728,6 +731,7 @@ void LLParcel::unpackMessage(LLMessageSystem* msg) msg->getBOOLFast(_PREHASH_ParcelData, _PREHASH_Privacy, private_parcel); } setPrivacy((bool) private_parcel); + setHavePrivacyData(have_privacy_data); // non-optimized version msg->getU8 ( "ParcelData", "MediaAutoScale", mMediaAutoScale ); -- cgit v1.2.3 From 50393788693578a2fe3a934faa04b382d75f1657 Mon Sep 17 00:00:00 2001 From: Dave SIMmONs Date: Thu, 9 Jun 2011 13:46:19 -0700 Subject: ER-910: Parcel Privacy. Rename things in code to reflect feature name change to "hidden avatars" --- indra/llinventory/llparcel.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'indra/llinventory/llparcel.cpp') diff --git a/indra/llinventory/llparcel.cpp b/indra/llinventory/llparcel.cpp index c79d410ade..b388d34580 100644 --- a/indra/llinventory/llparcel.cpp +++ b/indra/llinventory/llparcel.cpp @@ -227,8 +227,8 @@ void LLParcel::init(const LLUUID &owner_id, setPreviousOwnerID(LLUUID::null); setPreviouslyGroupOwned(FALSE); - setPrivacy(false); - setHavePrivacyData(false); + setHiddenAVs(false); + setHaveHiddenAVsData(false); } void LLParcel::overrideOwner(const LLUUID& owner_id, BOOL is_group_owned) @@ -705,7 +705,7 @@ void LLParcel::packMessage(LLSD& msg) msg["user_location"] = ll_sd_from_vector3(mUserLocation); msg["user_look_at"] = ll_sd_from_vector3(mUserLookAt); msg["landing_type"] = (U8)mLandingType; - msg["privacy"] = (LLSD::Boolean) getPrivacy(); + msg["hidden_avs"] = (LLSD::Boolean) getHiddenAVs(); } @@ -724,14 +724,14 @@ void LLParcel::unpackMessage(LLMessageSystem* msg) msg->getStringFast( _PREHASH_ParcelData,_PREHASH_MediaURL, buffer ); setMediaURL(buffer); - BOOL private_parcel = FALSE; - bool have_privacy_data = (msg->getSizeFast(_PREHASH_ParcelData, _PREHASH_Privacy) > 0); - if (have_privacy_data) + BOOL hidden_avs = FALSE; + bool have_hidden_av_data = (msg->getSizeFast(_PREHASH_ParcelData, _PREHASH_HiddenAVs) > 0); + if (have_hidden_av_data) { - msg->getBOOLFast(_PREHASH_ParcelData, _PREHASH_Privacy, private_parcel); + msg->getBOOLFast(_PREHASH_ParcelData, _PREHASH_HiddenAVs, hidden_avs); } - setPrivacy((bool) private_parcel); - setHavePrivacyData(have_privacy_data); + setHiddenAVs((bool) hidden_avs); + setHaveHiddenAVsData(have_hidden_av_data); // non-optimized version msg->getU8 ( "ParcelData", "MediaAutoScale", mMediaAutoScale ); -- cgit v1.2.3 From c0c0a2b9a5f41fc06619330a81c34955a39ddfe2 Mon Sep 17 00:00:00 2001 From: "simon@lindenlab.com" Date: Mon, 20 Jun 2011 09:28:10 -0700 Subject: ER-944: Add feature to control user sounds on a parcel. Added new checkboxes to the About Land / Sound tab. Reviewed by Kelly. --- indra/llinventory/llparcel.cpp | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) (limited to 'indra/llinventory/llparcel.cpp') diff --git a/indra/llinventory/llparcel.cpp b/indra/llinventory/llparcel.cpp index b388d34580..e026ad32f9 100644 --- a/indra/llinventory/llparcel.cpp +++ b/indra/llinventory/llparcel.cpp @@ -227,8 +227,10 @@ void LLParcel::init(const LLUUID &owner_id, setPreviousOwnerID(LLUUID::null); setPreviouslyGroupOwned(FALSE); - setHiddenAVs(false); - setHaveHiddenAVsData(false); + setHiddenAVs(FALSE); + setAllowGroupAVSounds(TRUE); + setAllowAnyAVSounds(TRUE); + setHaveNewParcelLimitData(FALSE); } void LLParcel::overrideOwner(const LLUUID& owner_id, BOOL is_group_owned) @@ -706,6 +708,8 @@ void LLParcel::packMessage(LLSD& msg) msg["user_look_at"] = ll_sd_from_vector3(mUserLookAt); msg["landing_type"] = (U8)mLandingType; msg["hidden_avs"] = (LLSD::Boolean) getHiddenAVs(); + msg["group_av_sounds"] = (LLSD::Boolean) getAllowGroupAVSounds(); + msg["any_av_sounds"] = (LLSD::Boolean) getAllowAnyAVSounds(); } @@ -725,13 +729,22 @@ void LLParcel::unpackMessage(LLMessageSystem* msg) setMediaURL(buffer); BOOL hidden_avs = FALSE; - bool have_hidden_av_data = (msg->getSizeFast(_PREHASH_ParcelData, _PREHASH_HiddenAVs) > 0); - if (have_hidden_av_data) + BOOL any_av_sounds = TRUE; + BOOL group_av_sounds = TRUE; + bool have_new_parcel_limit_data = (msg->getSizeFast(_PREHASH_ParcelData, _PREHASH_HiddenAVs) > 0); // New version of server should send all 3 of these values + have_new_parcel_limit_data &= (msg->getSizeFast(_PREHASH_ParcelData, _PREHASH_AnyAVSounds) > 0); + have_new_parcel_limit_data &= (msg->getSizeFast(_PREHASH_ParcelData, _PREHASH_GroupAVSounds) > 0); + if (have_new_parcel_limit_data) { msg->getBOOLFast(_PREHASH_ParcelData, _PREHASH_HiddenAVs, hidden_avs); + msg->getBOOLFast(_PREHASH_ParcelData, _PREHASH_AnyAVSounds, any_av_sounds); + msg->getBOOLFast(_PREHASH_ParcelData, _PREHASH_GroupAVSounds, group_av_sounds); } setHiddenAVs((bool) hidden_avs); - setHaveHiddenAVsData(have_hidden_av_data); + setAllowAnyAVSounds((bool) any_av_sounds); + setAllowGroupAVSounds((bool) group_av_sounds); + + setHaveNewParcelLimitData(have_new_parcel_limit_data); // non-optimized version msg->getU8 ( "ParcelData", "MediaAutoScale", mMediaAutoScale ); -- cgit v1.2.3 From 918238dd18f74ee2783d55dfb961e8f44b2f4b1b Mon Sep 17 00:00:00 2001 From: "simon@lindenlab.com" Date: Fri, 1 Jul 2011 14:06:08 -0700 Subject: ER-1016 - "Remove ability for anyone to edit terrain" and ER-910 "Parcel Privacy" changes. Many naming changes for the featureto be "See avatars" instead of "hidden avatars". Also removed the "anyone can edit terrain" checkbox and slammed the value to FALSE. --- indra/llinventory/llparcel.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'indra/llinventory/llparcel.cpp') diff --git a/indra/llinventory/llparcel.cpp b/indra/llinventory/llparcel.cpp index e026ad32f9..c95f922301 100644 --- a/indra/llinventory/llparcel.cpp +++ b/indra/llinventory/llparcel.cpp @@ -227,7 +227,7 @@ void LLParcel::init(const LLUUID &owner_id, setPreviousOwnerID(LLUUID::null); setPreviouslyGroupOwned(FALSE); - setHiddenAVs(FALSE); + setSeeAVs(TRUE); setAllowGroupAVSounds(TRUE); setAllowAnyAVSounds(TRUE); setHaveNewParcelLimitData(FALSE); @@ -707,7 +707,7 @@ void LLParcel::packMessage(LLSD& msg) msg["user_location"] = ll_sd_from_vector3(mUserLocation); msg["user_look_at"] = ll_sd_from_vector3(mUserLookAt); msg["landing_type"] = (U8)mLandingType; - msg["hidden_avs"] = (LLSD::Boolean) getHiddenAVs(); + msg["see_avs"] = (LLSD::Boolean) getSeeAVs(); msg["group_av_sounds"] = (LLSD::Boolean) getAllowGroupAVSounds(); msg["any_av_sounds"] = (LLSD::Boolean) getAllowAnyAVSounds(); } @@ -728,19 +728,19 @@ void LLParcel::unpackMessage(LLMessageSystem* msg) msg->getStringFast( _PREHASH_ParcelData,_PREHASH_MediaURL, buffer ); setMediaURL(buffer); - BOOL hidden_avs = FALSE; + BOOL see_avs = TRUE; // All default to true for legacy server behavior BOOL any_av_sounds = TRUE; BOOL group_av_sounds = TRUE; - bool have_new_parcel_limit_data = (msg->getSizeFast(_PREHASH_ParcelData, _PREHASH_HiddenAVs) > 0); // New version of server should send all 3 of these values + bool have_new_parcel_limit_data = (msg->getSizeFast(_PREHASH_ParcelData, _PREHASH_SeeAVs) > 0); // New version of server should send all 3 of these values have_new_parcel_limit_data &= (msg->getSizeFast(_PREHASH_ParcelData, _PREHASH_AnyAVSounds) > 0); have_new_parcel_limit_data &= (msg->getSizeFast(_PREHASH_ParcelData, _PREHASH_GroupAVSounds) > 0); if (have_new_parcel_limit_data) { - msg->getBOOLFast(_PREHASH_ParcelData, _PREHASH_HiddenAVs, hidden_avs); + msg->getBOOLFast(_PREHASH_ParcelData, _PREHASH_SeeAVs, see_avs); msg->getBOOLFast(_PREHASH_ParcelData, _PREHASH_AnyAVSounds, any_av_sounds); msg->getBOOLFast(_PREHASH_ParcelData, _PREHASH_GroupAVSounds, group_av_sounds); } - setHiddenAVs((bool) hidden_avs); + setSeeAVs((bool) see_avs); setAllowAnyAVSounds((bool) any_av_sounds); setAllowGroupAVSounds((bool) group_av_sounds); -- cgit v1.2.3