From dcf21a1287ed20806260aa38959b6fb585ee139a Mon Sep 17 00:00:00 2001 From: Vadim Savchuk Date: Mon, 12 Jul 2010 16:52:34 +0300 Subject: Fixed Linux build. --HG-- branch : product-engine --- indra/llui/lluictrlfactory.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/llui') diff --git a/indra/llui/lluictrlfactory.h b/indra/llui/lluictrlfactory.h index ff99712c5f..dc43b311a7 100644 --- a/indra/llui/lluictrlfactory.h +++ b/indra/llui/lluictrlfactory.h @@ -182,7 +182,7 @@ public: void popFactoryFunctions(); template - static T* createWidget(typename const T::Params& params, LLView* parent = NULL) + static T* createWidget(const typename T::Params& params, LLView* parent = NULL) { T* widget = NULL; -- cgit v1.2.3 From 1c66ca72b54eb01db2c71776526462cfc5e18832 Mon Sep 17 00:00:00 2001 From: Mike Antipov Date: Mon, 12 Jul 2010 17:43:04 +0300 Subject: Backed out changeset: 412588eb49a2 That patch leaded to two issues: * broken message for empty accordion in Teleport History Panel. For now it looks like "Missing String (Didn't find... [Search].)" * there are multiple warnings like "LLTrans::getString: ONCE (10th time seen): Missing String in strings.xml: []" for accordions which have empty default strings (Friends list for ex.) --HG-- branch : product-engine --- indra/llui/llaccordionctrl.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'indra/llui') diff --git a/indra/llui/llaccordionctrl.cpp b/indra/llui/llaccordionctrl.cpp index 28125ccaaf..673631f99a 100644 --- a/indra/llui/llaccordionctrl.cpp +++ b/indra/llui/llaccordionctrl.cpp @@ -40,8 +40,6 @@ #include "llfocusmgr.h" #include "lllocalcliprect.h" -#include "lltrans.h" - #include "boost/bind.hpp" static const S32 DRAGGER_BAR_MARGIN = 4; @@ -74,7 +72,6 @@ LLAccordionCtrl::LLAccordionCtrl(const Params& params):LLPanel(params) { initNoTabsWidget(params.no_matched_tabs_text); - mNoVisibleTabsOrigString = LLTrans::getString(params.no_visible_tabs_text.initial_value().asString()); mSingleExpansion = params.single_expansion; if(mFitParent && !mSingleExpansion) { @@ -389,7 +386,7 @@ void LLAccordionCtrl::initNoTabsWidget(const LLTextBox::Params& tb_params) { LLTextBox::Params tp = tb_params; tp.rect(getLocalRect()); - mNoMatchedTabsOrigString = LLTrans::getString(tp.initial_value().asString()); + mNoMatchedTabsOrigString = tp.initial_value().asString(); mNoVisibleTabsHelpText = LLUICtrlFactory::create(tp, this); } -- cgit v1.2.3 From b80ee71bed341b6c2f316e37537f01043726e816 Mon Sep 17 00:00:00 2001 From: Monroe Linden Date: Mon, 12 Jul 2010 11:28:48 -0700 Subject: Fix for reopened EXT-8025 Fixed an issue in LLFlatListView where calling setCommitOnSelectionChange(true) wasn't always causing the commit signal to be sent when the selection changed. Reviewed by Richard at http://codereview.lindenlab.com/2579010 --- indra/llui/llflatlistview.cpp | 11 ++++++++++- indra/llui/llflatlistview.h | 1 + 2 files changed, 11 insertions(+), 1 deletion(-) (limited to 'indra/llui') diff --git a/indra/llui/llflatlistview.cpp b/indra/llui/llflatlistview.cpp index b313f8c950..3c79da64f9 100644 --- a/indra/llui/llflatlistview.cpp +++ b/indra/llui/llflatlistview.cpp @@ -327,6 +327,9 @@ U32 LLFlatListView::size(const bool only_visible_items) const void LLFlatListView::clear() { + // This will clear mSelectedItemPairs, calling all appropriate callbacks. + resetSelection(); + // do not use LLView::deleteAllChildren to avoid removing nonvisible items. drag-n-drop for ex. for (pairs_iterator_t it = mItemPairs.begin(); it != mItemPairs.end(); ++it) { @@ -335,7 +338,6 @@ void LLFlatListView::clear() delete *it; } mItemPairs.clear(); - mSelectedItemPairs.clear(); // also set items panel height to zero. Reshape it to allow reshaping of non-item children LLRect rc = mItemsPanel->getRect(); @@ -975,6 +977,7 @@ bool LLFlatListView::removeItemPair(item_pair_t* item_pair, bool rearrange) llassert(item_pair); bool deleted = false; + bool selection_changed = false; for (pairs_iterator_t it = mItemPairs.begin(); it != mItemPairs.end(); ++it) { item_pair_t* _item_pair = *it; @@ -994,6 +997,7 @@ bool LLFlatListView::removeItemPair(item_pair_t* item_pair, bool rearrange) if (selected_item_pair == item_pair) { it = mSelectedItemPairs.erase(it); + selection_changed = true; break; } } @@ -1008,6 +1012,11 @@ bool LLFlatListView::removeItemPair(item_pair_t* item_pair, bool rearrange) notifyParentItemsRectChanged(); } + if (selection_changed && mCommitOnSelectionChange) + { + onCommit(); + } + return true; } diff --git a/indra/llui/llflatlistview.h b/indra/llui/llflatlistview.h index 29b6b718af..50d06fbc94 100644 --- a/indra/llui/llflatlistview.h +++ b/indra/llui/llflatlistview.h @@ -265,6 +265,7 @@ public: void setAllowSelection(bool can_select) { mAllowSelection = can_select; } /** Sets flag whether onCommit should be fired if selection was changed */ + // FIXME: this should really be a separate signal, since "Commit" implies explicit user action, and selection changes can happen more indirectly. void setCommitOnSelectionChange(bool b) { mCommitOnSelectionChange = b; } /** Get number of selected items in the list */ -- cgit v1.2.3 From c73dcb0a2d328d786c4eceb417d959ae68c2e3a8 Mon Sep 17 00:00:00 2001 From: Alexei Arabadji Date: Tue, 13 Jul 2010 19:42:31 +0300 Subject: EXT-8341 FIXED Avoided assertion on receiving object auto return notification. Details: 1 Provided passing necessary is_group parameter to LLPostponedNotification::add method call; 3 Corrected handling group name in LLPostponedNotification::onCachedNameReceived; 2 Added check on retrieved name from cache name and replacement with fallback value. reviewed by Vadim Savchuk at https://codereview.productengine.com/secondlife/r/743/ --HG-- branch : product-engine --- indra/llui/llnotifications.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'indra/llui') diff --git a/indra/llui/llnotifications.cpp b/indra/llui/llnotifications.cpp index 621e72ce38..9e272a0949 100644 --- a/indra/llui/llnotifications.cpp +++ b/indra/llui/llnotifications.cpp @@ -34,6 +34,7 @@ #include "llnotifications.h" +#include "llinstantmessage.h" #include "llxmlnode.h" #include "lluictrl.h" #include "lluictrlfactory.h" @@ -41,6 +42,7 @@ #include "llsdserialize.h" #include "lltrans.h" #include "llnotificationslistener.h" +#include "llstring.h" #include #include @@ -1487,7 +1489,14 @@ std::ostream& operator<<(std::ostream& s, const LLNotification& notification) void LLPostponedNotification::onCachedNameReceived(const LLUUID& id, const std::string& first, const std::string& last, bool is_group) { - gCacheName->getFullName(id, mName); + mName = first + " " + last; + + LLStringUtil::trim(mName); + if (mName.empty()) + { + llwarns << "Empty name received for Id: " << id << llendl; + mName = SYSTEM_FROM; + } modifyNotificationParams(); LLNotifications::instance().add(mParams); cleanup(); -- cgit v1.2.3