diff options
author | Monty Brandenberg <monty@lindenlab.com> | 2013-11-12 14:06:38 -0500 |
---|---|---|
committer | Monty Brandenberg <monty@lindenlab.com> | 2013-11-12 14:06:38 -0500 |
commit | d191585a3eec778e36e5f0c4b620c3d525c86c42 (patch) | |
tree | 2612c0d1947e00d9ceba82b054a7a90113ffa752 /indra/newview/llfloaterland.cpp | |
parent | ac1d3a22f2034a5e3aba757bde72825643fa799c (diff) | |
parent | ebc9bcbf69f7a519677a6522979a6bf6cbb04bb8 (diff) |
Merge. Refresh from viewer-release after 3.6.10 release
Diffstat (limited to 'indra/newview/llfloaterland.cpp')
-rwxr-xr-x | indra/newview/llfloaterland.cpp | 43 |
1 files changed, 16 insertions, 27 deletions
diff --git a/indra/newview/llfloaterland.cpp b/indra/newview/llfloaterland.cpp index 6ef4d8717d..2b9c216e54 100755 --- a/indra/newview/llfloaterland.cpp +++ b/indra/newview/llfloaterland.cpp @@ -2097,7 +2097,6 @@ void LLPanelLandOptions::refresh() // virtual void LLPanelLandOptions::draw() { - refreshSearch(); // Is this necessary? JC LLPanel::draw(); } @@ -2111,9 +2110,8 @@ void LLPanelLandOptions::refreshSearch() mCheckShowDirectory->set(FALSE); mCheckShowDirectory->setEnabled(FALSE); - // *TODO:Translate - const std::string& none_string = LLParcel::getCategoryUIString(LLParcel::C_NONE); - mCategoryCombo->setSimple(none_string); + const std::string& none_string = LLParcel::getCategoryString(LLParcel::C_NONE); + mCategoryCombo->setValue(none_string); mCategoryCombo->setEnabled(FALSE); return; } @@ -2140,10 +2138,9 @@ void LLPanelLandOptions::refreshSearch() mCheckShowDirectory ->set(show_directory); // Set by string in case the order in UI doesn't match the order by index. - // *TODO:Translate LLParcel::ECategory cat = parcel->getCategory(); - const std::string& category_string = LLParcel::getCategoryUIString(cat); - mCategoryCombo->setSimple(category_string); + const std::string& category_string = LLParcel::getCategoryString(cat); + mCategoryCombo->setValue(category_string); std::string tooltip; bool enable_show_directory = false; @@ -2377,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 ); @@ -2544,7 +2541,11 @@ 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) { @@ -2582,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); @@ -2592,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); @@ -2607,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); @@ -2652,17 +2653,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); } @@ -2697,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(); } |