From 146e9d5e4d9a9a4f33d9ccd47a901980972b7ab9 Mon Sep 17 00:00:00 2001 From: James Cook Date: Mon, 1 Feb 2010 17:06:18 -0800 Subject: Support returning full_name (and SLID) for LLCacheName::get() calls Changed callback signature to full_name instead of first_name,last_name Eliminated all calls to legacy (non-signal/non-boost-bind) lookup mechanism Change Pay dialog names to SLURL links Tweaked layout of Pay Resident and Pay via Object floaters to make SLURLs fit Consolidate name first + " " + last concatenation in LLCacheName::buildFullName() Reviewed with Kelly --- indra/newview/llfloaterpay.cpp | 36 ++++++++++++++---------------------- 1 file changed, 14 insertions(+), 22 deletions(-) (limited to 'indra/newview/llfloaterpay.cpp') diff --git a/indra/newview/llfloaterpay.cpp b/indra/newview/llfloaterpay.cpp index c2389e73a0..b37be3c1bf 100644 --- a/indra/newview/llfloaterpay.cpp +++ b/indra/newview/llfloaterpay.cpp @@ -47,6 +47,7 @@ #include "lllineeditor.h" #include "llmutelist.h" #include "llfloaterreporter.h" +#include "llslurl.h" #include "llviewerobject.h" #include "llviewerobjectlist.h" #include "llviewerregion.h" @@ -102,10 +103,6 @@ private: static void onGive(void* data); void give(S32 amount); static void processPayPriceReply(LLMessageSystem* msg, void **userdata); - void onCacheOwnerName(const LLUUID& owner_id, - const std::string& firstname, - const std::string& lastname, - BOOL is_group); void finishPayUI(const LLUUID& target_id, BOOL is_group); protected: @@ -426,33 +423,28 @@ void LLFloaterPay::payDirectly(money_callback callback, void LLFloaterPay::finishPayUI(const LLUUID& target_id, BOOL is_group) { - gCacheName->get(target_id, is_group, boost::bind(&LLFloaterPay::onCacheOwnerName, this, _1, _2, _3, _4)); - - // Make sure the amount field has focus - - childSetFocus("amount", TRUE); - - LLLineEditor* amount = getChild("amount"); - amount->selectAll(); - mTargetIsGroup = is_group; -} - -void LLFloaterPay::onCacheOwnerName(const LLUUID& owner_id, - const std::string& firstname, - const std::string& lastname, - BOOL is_group) -{ + // IDEVO + //gCacheName->get(target_id, is_group, boost::bind(&LLFloaterPay::onCacheOwnerName, this, _1, _2, _3, _4)); + std::string slurl; if (is_group) { setTitle(getString("payee_group")); + slurl = LLSLURL::buildCommand("group", target_id, "inspect"); } else { setTitle(getString("payee_resident")); + slurl = LLSLURL::buildCommand("agent", target_id, "inspect"); } + childSetText("payee_name", slurl); + + // Make sure the amount field has focus + + childSetFocus("amount", TRUE); - childSetTextArg("payee_name", "[FIRST]", firstname); - childSetTextArg("payee_name", "[LAST]", lastname); + LLLineEditor* amount = getChild("amount"); + amount->selectAll(); + mTargetIsGroup = is_group; } // static -- cgit v1.2.3 From 894261e4e4aea8a15bef33fdf34807812a1c73bb Mon Sep 17 00:00:00 2001 From: James Cook Date: Thu, 13 May 2010 16:30:15 -0700 Subject: Fix build errors introduced in last merge --- indra/newview/llfloaterpay.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/newview/llfloaterpay.cpp') diff --git a/indra/newview/llfloaterpay.cpp b/indra/newview/llfloaterpay.cpp index 7dbcc9555c..7b596e9ba3 100644 --- a/indra/newview/llfloaterpay.cpp +++ b/indra/newview/llfloaterpay.cpp @@ -430,12 +430,12 @@ void LLFloaterPay::finishPayUI(const LLUUID& target_id, BOOL is_group) if (is_group) { setTitle(getString("payee_group")); - slurl = LLSLURL::buildCommand("group", target_id, "inspect"); + slurl = LLSLURL("group", target_id, "inspect").getSLURLString(); } else { setTitle(getString("payee_resident")); - slurl = LLSLURL::buildCommand("agent", target_id, "inspect"); + slurl = LLSLURL("agent", target_id, "inspect").getSLURLString(); } childSetText("payee_name", slurl); -- cgit v1.2.3 From 3bbb622731b2a6a29fc6576dcf4885527d813699 Mon Sep 17 00:00:00 2001 From: James Cook Date: Fri, 28 May 2010 08:21:33 -0700 Subject: WIP Fix miscellaneous display names in UI --- indra/newview/llfloaterpay.cpp | 2 -- 1 file changed, 2 deletions(-) (limited to 'indra/newview/llfloaterpay.cpp') diff --git a/indra/newview/llfloaterpay.cpp b/indra/newview/llfloaterpay.cpp index 7b596e9ba3..6b811b5886 100644 --- a/indra/newview/llfloaterpay.cpp +++ b/indra/newview/llfloaterpay.cpp @@ -424,8 +424,6 @@ void LLFloaterPay::payDirectly(money_callback callback, void LLFloaterPay::finishPayUI(const LLUUID& target_id, BOOL is_group) { - // IDEVO - //gCacheName->get(target_id, is_group, boost::bind(&LLFloaterPay::onCacheOwnerName, this, _1, _2, _3, _4)); std::string slurl; if (is_group) { -- cgit v1.2.3