From 7e75c13e0ea967de1fd1f5531b30d2eab7917ae8 Mon Sep 17 00:00:00 2001 From: McCabe Maxsted Date: Wed, 14 Oct 2009 02:38:26 -0700 Subject: Applied patch for VWR-6787 by Alissa Sabre - 'none' text in group window not translatable --- linden/indra/newview/llfloatergroups.cpp | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'linden/indra/newview/llfloatergroups.cpp') diff --git a/linden/indra/newview/llfloatergroups.cpp b/linden/indra/newview/llfloatergroups.cpp index 23e2f4d..9599089 100644 --- a/linden/indra/newview/llfloatergroups.cpp +++ b/linden/indra/newview/llfloatergroups.cpp @@ -61,7 +61,7 @@ std::map LLFloaterGroupPicker::sInstances; // helper functions -void init_group_list(LLScrollListCtrl* ctrl, const LLUUID& highlight_id, U64 powers_mask = GP_ALL_POWERS); +void init_group_list(LLScrollListCtrl* ctrl, const LLUUID& highlight_id, const std::string& none_text, U64 powers_mask = GP_ALL_POWERS); ///---------------------------------------------------------------------------- /// Class LLFloaterGroupPicker @@ -116,7 +116,8 @@ void LLFloaterGroupPicker::setPowersMask(U64 powers_mask) BOOL LLFloaterGroupPicker::postBuild() { - init_group_list(getChild("group list"), gAgent.getGroupID(), mPowersMask); + const std::string none_text = getString("none"); + init_group_list(getChild("group list"), gAgent.getGroupID(), none_text, mPowersMask); childSetAction("OK", onBtnOK, this); @@ -200,7 +201,8 @@ void LLPanelGroups::reset() childSetTextArg("groupcount", "[COUNT]", llformat("%d",gAgent.mGroups.count())); childSetTextArg("groupcount", "[MAX]", llformat("%d",MAX_AGENT_GROUPS)); - init_group_list(getChild("group list"), gAgent.getGroupID()); + const std::string none_text = getString("none"); + init_group_list(getChild("group list"), gAgent.getGroupID(), none_text); enableButtons(); } @@ -211,7 +213,8 @@ BOOL LLPanelGroups::postBuild() childSetTextArg("groupcount", "[COUNT]", llformat("%d",gAgent.mGroups.count())); childSetTextArg("groupcount", "[MAX]", llformat("%d",MAX_AGENT_GROUPS)); - init_group_list(getChild("group list"), gAgent.getGroupID()); + const std::string none_text = getString("none"); + init_group_list(getChild("group list"), gAgent.getGroupID(), none_text); childSetAction("Activate", onBtnActivate, this); @@ -457,7 +460,7 @@ void LLPanelGroups::onGroupList(LLUICtrl* ctrl, void* userdata) if(self) self->enableButtons(); } -void init_group_list(LLScrollListCtrl* ctrl, const LLUUID& highlight_id, U64 powers_mask) +void init_group_list(LLScrollListCtrl* ctrl, const LLUUID& highlight_id, const std::string& none_text, U64 powers_mask) { S32 count = gAgent.mGroups.count(); LLUUID id; @@ -499,7 +502,7 @@ void init_group_list(LLScrollListCtrl* ctrl, const LLUUID& highlight_id, U64 pow LLSD element; element["id"] = LLUUID::null; element["columns"][0]["column"] = "name"; - element["columns"][0]["value"] = "none"; // *TODO: Translate + element["columns"][0]["value"] = none_text; element["columns"][0]["font"] = "SANSSERIF"; element["columns"][0]["font-style"] = style; -- cgit v1.1