diff options
Diffstat (limited to 'indra/newview/llsidepaneliteminfo.cpp')
-rw-r--r-- | indra/newview/llsidepaneliteminfo.cpp | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/indra/newview/llsidepaneliteminfo.cpp b/indra/newview/llsidepaneliteminfo.cpp index 0a76a1f48f..54194e5fe6 100644 --- a/indra/newview/llsidepaneliteminfo.cpp +++ b/indra/newview/llsidepaneliteminfo.cpp @@ -633,16 +633,14 @@ void LLSidepanelItemInfo::refreshFromItem(LLViewerInventoryItem* item) } // Set values. - bool is_group_copy = (group_mask & PERM_COPY) ? true : false; - bool is_group_modify = (group_mask & PERM_MODIFY) ? true : false; - bool is_group_move = (group_mask & PERM_MOVE) ? true : false; + bool is_group_copy = group_mask & PERM_COPY; + bool is_group_modify = group_mask & PERM_MODIFY; + bool is_group_move = group_mask & PERM_MOVE; if (is_group_copy && is_group_modify && is_group_move) { getChild<LLUICtrl>("CheckShareWithGroup")->setValue(LLSD((bool)true)); - - LLCheckBoxCtrl* ctl = getChild<LLCheckBoxCtrl>("CheckShareWithGroup"); - if(ctl) + if (LLCheckBoxCtrl* ctl = getChild<LLCheckBoxCtrl>("CheckShareWithGroup")) { ctl->setTentative(false); } @@ -650,22 +648,20 @@ void LLSidepanelItemInfo::refreshFromItem(LLViewerInventoryItem* item) else if (!is_group_copy && !is_group_modify && !is_group_move) { getChild<LLUICtrl>("CheckShareWithGroup")->setValue(LLSD((bool)false)); - LLCheckBoxCtrl* ctl = getChild<LLCheckBoxCtrl>("CheckShareWithGroup"); - if(ctl) + if (LLCheckBoxCtrl* ctl = getChild<LLCheckBoxCtrl>("CheckShareWithGroup")) { ctl->setTentative(false); } } else { - LLCheckBoxCtrl* ctl = getChild<LLCheckBoxCtrl>("CheckShareWithGroup"); - if(ctl) + if (LLCheckBoxCtrl* ctl = getChild<LLCheckBoxCtrl>("CheckShareWithGroup")) { ctl->setTentative(!ctl->getEnabled()); ctl->set(true); } } - + getChild<LLUICtrl>("CheckEveryoneCopy")->setValue(LLSD((bool)(everyone_mask & PERM_COPY))); /////////////// |