[LLNameUI] Handle LFIDBearer::Type instead of jusst group or not
Removes "is_group" and switches it out for "type" setValue no longer takes "group", instead it takes "type" Constructors and setNameID now take Type instead of a boolean setIsGroup is now setType
This commit is contained in:
@@ -39,17 +39,17 @@ static LLRegisterWidget<LLNameBox> r("name_box");
|
||||
|
||||
LLNameBox::LLNameBox(const std::string& name,
|
||||
const LLUUID& name_id,
|
||||
bool is_group,
|
||||
const Type& type,
|
||||
const std::string& loading,
|
||||
bool rlv_sensitive,
|
||||
const std::string& name_system)
|
||||
: LLNameUI(loading, rlv_sensitive, name_id, is_group, name_system)
|
||||
: LLNameUI(loading, rlv_sensitive, name_id, type, name_system)
|
||||
, LLTextBox(name, LLRect(), LLStringUtil::null, nullptr, TRUE)
|
||||
{
|
||||
setClickedCallback(boost::bind(&LLNameUI::showProfile, this));
|
||||
if (!name_id.isNull())
|
||||
{
|
||||
setNameID(name_id, is_group);
|
||||
setNameID(name_id, type);
|
||||
}
|
||||
else setText(mInitialValue);
|
||||
}
|
||||
@@ -104,8 +104,8 @@ LLXMLNodePtr LLNameBox::getXML(bool save_children) const
|
||||
// static
|
||||
LLView* LLNameBox::fromXML(LLXMLNodePtr node, LLView *parent, LLUICtrlFactory *factory)
|
||||
{
|
||||
bool is_group = false;
|
||||
node->getAttribute_bool("is_group", is_group);
|
||||
S8 type = AVATAR;
|
||||
node->getAttributeS8("type", type);
|
||||
LLUUID id;
|
||||
node->getAttributeUUID("id", id);
|
||||
std::string loading;
|
||||
@@ -114,7 +114,7 @@ LLView* LLNameBox::fromXML(LLXMLNodePtr node, LLView *parent, LLUICtrlFactory *f
|
||||
node->getAttribute_bool("rlv_sensitive", rlv_sensitive);
|
||||
std::string name_system;
|
||||
node->getAttributeString("name_system", name_system);
|
||||
LLNameBox* name_box = new LLNameBox("name_box", id, is_group, loading, rlv_sensitive, name_system);
|
||||
LLNameBox* name_box = new LLNameBox("name_box", id, (Type)type, loading, rlv_sensitive, name_system);
|
||||
name_box->initFromXML(node,parent);
|
||||
|
||||
return name_box;
|
||||
|
||||
Reference in New Issue
Block a user