aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--linden/indra/newview/llinventoryview.cpp26
-rw-r--r--linden/indra/newview/llinventoryview.h3
2 files changed, 20 insertions, 9 deletions
diff --git a/linden/indra/newview/llinventoryview.cpp b/linden/indra/newview/llinventoryview.cpp
index e6041c4..a001d65 100644
--- a/linden/indra/newview/llinventoryview.cpp
+++ b/linden/indra/newview/llinventoryview.cpp
@@ -674,14 +674,24 @@ void LLInventoryView::draw()
674{ 674{
675 if (LLInventoryModel::isEverythingFetched()) 675 if (LLInventoryModel::isEverythingFetched())
676 { 676 {
677 LLLocale locale(LLLocale::USER_LOCALE); 677 S32 item_count = gInventory.getItemCount();
678 std::ostringstream title; 678
679 title << "Inventory"; 679 //don't let llfloater work more than necessary
680 std::string item_count_string; 680 if (item_count != mOldItemCount || mOldFilterText != mFilterText)
681 LLResMgr::getInstance()->getIntegerString(item_count_string, gInventory.getItemCount()); 681 {
682 title << " (" << item_count_string << " items)"; 682 LLLocale locale(LLLocale::USER_LOCALE);
683 title << mFilterText; 683 std::ostringstream title;
684 setTitle(title.str()); 684 title << "Inventory"; //*TODO: make translatable
685 std::string item_count_string;
686 LLResMgr::getInstance()->getIntegerString(item_count_string, item_count);
687 title << " (" << item_count_string << " items)";
688 title << mFilterText;
689 setTitle(title.str());
690 }
691
692 mOldFilterText = mFilterText;
693 mOldItemCount = item_count;
694
685 } 695 }
686 if (mActivePanel && mSearchEditor) 696 if (mActivePanel && mSearchEditor)
687 { 697 {
diff --git a/linden/indra/newview/llinventoryview.h b/linden/indra/newview/llinventoryview.h
index 2650ed8..e098ac7 100644
--- a/linden/indra/newview/llinventoryview.h
+++ b/linden/indra/newview/llinventoryview.h
@@ -307,9 +307,10 @@ protected:
307 LLSaveFolderState* mSavedFolderState; 307 LLSaveFolderState* mSavedFolderState;
308 308
309 std::string mFilterText; 309 std::string mFilterText;
310 std::string mOldFilterText;
310 311
311 S32 mItemCount; 312 S32 mItemCount;
312 313 S32 mOldItemCount;
313 314
314 // This container is used to hold all active inventory views. This 315 // This container is used to hold all active inventory views. This
315 // is here to support the inventory toggle show button. 316 // is here to support the inventory toggle show button.