summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterland.cpp
diff options
context:
space:
mode:
authorBrad Payne (Vir Linden) <vir@lindenlab.com>2013-12-05 10:39:35 -0500
committerBrad Payne (Vir Linden) <vir@lindenlab.com>2013-12-05 10:39:35 -0500
commit744cf6be8d5a808020a4d6cc98ff4c6b208239c0 (patch)
treefab4ec7a30752ef1087d15540899830bf766cb89 /indra/newview/llfloaterland.cpp
parent1320e5ddcd9fc3be526dcacbf4710f8bcf878665 (diff)
parent787ccaf297e81291469aaf269f563d862fb150a3 (diff)
merge
Diffstat (limited to 'indra/newview/llfloaterland.cpp')
-rwxr-xr-xindra/newview/llfloaterland.cpp30
1 files changed, 11 insertions, 19 deletions
diff --git a/indra/newview/llfloaterland.cpp b/indra/newview/llfloaterland.cpp
index 8f20d4e082..6c8e81e563 100755
--- a/indra/newview/llfloaterland.cpp
+++ b/indra/newview/llfloaterland.cpp
@@ -2374,7 +2374,7 @@ void LLPanelLandAccess::refresh()
{
BOOL use_access_list = parcel->getParcelFlag(PF_USE_ACCESS_LIST);
BOOL use_group = parcel->getParcelFlag(PF_USE_ACCESS_GROUP);
- BOOL public_access = !use_access_list && !use_group;
+ BOOL public_access = !use_access_list;
getChild<LLUICtrl>("public_access")->setValue(public_access );
getChild<LLUICtrl>("GroupCheck")->setValue(use_group );
@@ -2541,6 +2541,10 @@ void LLPanelLandAccess::refresh_ui()
getChildView("HoursSpin")->setEnabled(FALSE);
getChildView("AccessList")->setEnabled(FALSE);
getChildView("BannedList")->setEnabled(FALSE);
+ getChildView("add_allowed")->setEnabled(FALSE);
+ getChildView("remove_allowed")->setEnabled(FALSE);
+ getChildView("add_banned")->setEnabled(FALSE);
+ getChildView("remove_banned")->setEnabled(FALSE);
LLParcel *parcel = mParcel->getParcel();
if (parcel)
@@ -2579,7 +2583,6 @@ void LLPanelLandAccess::refresh_ui()
{
getChildView("Only Allow")->setToolTip(std::string());
}
- getChildView("GroupCheck")->setEnabled(FALSE);
getChildView("PassCheck")->setEnabled(FALSE);
getChildView("pass_combo")->setEnabled(FALSE);
getChildView("AccessList")->setEnabled(FALSE);
@@ -2589,11 +2592,7 @@ void LLPanelLandAccess::refresh_ui()
getChildView("limit_payment")->setEnabled(FALSE);
getChildView("limit_age_verified")->setEnabled(FALSE);
- std::string group_name;
- if (gCacheName->getGroupName(parcel->getGroupID(), group_name))
- {
- getChildView("GroupCheck")->setEnabled(can_manage_allowed);
- }
+
BOOL group_access = getChild<LLUICtrl>("GroupCheck")->getValue().asBoolean();
BOOL sell_passes = getChild<LLUICtrl>("PassCheck")->getValue().asBoolean();
getChildView("PassCheck")->setEnabled(can_manage_allowed);
@@ -2604,6 +2603,11 @@ void LLPanelLandAccess::refresh_ui()
getChildView("HoursSpin")->setEnabled(can_manage_allowed);
}
}
+ std::string group_name;
+ if (gCacheName->getGroupName(parcel->getGroupID(), group_name))
+ {
+ getChildView("GroupCheck")->setEnabled(can_manage_allowed);
+ }
getChildView("AccessList")->setEnabled(can_manage_allowed);
S32 allowed_list_count = parcel->mAccessList.size();
getChildView("add_allowed")->setEnabled(can_manage_allowed && allowed_list_count < PARCEL_MAX_ACCESS_LIST);
@@ -2650,17 +2654,6 @@ void LLPanelLandAccess::onCommitPublicAccess(LLUICtrl *ctrl, void *userdata)
return;
}
- // If we disabled public access, enable group access by default (if applicable)
- BOOL public_access = self->getChild<LLUICtrl>("public_access")->getValue().asBoolean();
- if (public_access == FALSE)
- {
- std::string group_name;
- if (gCacheName->getGroupName(parcel->getGroupID(), group_name))
- {
- self->getChild<LLUICtrl>("GroupCheck")->setValue(public_access ? FALSE : TRUE);
- }
- }
-
onCommitAny(ctrl, userdata);
}
@@ -2694,7 +2687,6 @@ void LLPanelLandAccess::onCommitAny(LLUICtrl *ctrl, void *userdata)
if (public_access)
{
use_access_list = FALSE;
- use_access_group = FALSE;
limit_payment = self->getChild<LLUICtrl>("limit_payment")->getValue().asBoolean();
limit_age_verified = self->getChild<LLUICtrl>("limit_age_verified")->getValue().asBoolean();
}