summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/newview/app_settings/settings.xml22
-rw-r--r--indra/newview/app_settings/settings_per_account.xml11
-rw-r--r--indra/newview/llinventorybridge.cpp8
-rw-r--r--indra/newview/llpanelmarketplaceinbox.cpp5
-rw-r--r--indra/newview/llpanelmarketplaceinboxinventory.cpp2
-rw-r--r--indra/newview/llpanelmarketplaceinboxinventory.h6
-rw-r--r--indra/newview/llsidepanelinventory.cpp12
7 files changed, 25 insertions, 41 deletions
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml
index 0bba25f5e4..142bf94395 100644
--- a/indra/newview/app_settings/settings.xml
+++ b/indra/newview/app_settings/settings.xml
@@ -4446,17 +4446,6 @@
<key>Value</key>
<real>2.0</real>
</map>
- <key>LastInventoryInboxExpand</key>
- <map>
- <key>Comment</key>
- <string>The last time the received items inbox was expanded.</string>
- <key>Persist</key>
- <integer>1</integer>
- <key>Type</key>
- <string>String</string>
- <key>Value</key>
- <string />
- </map>
<key>LCDDestination</key>
<map>
<key>Comment</key>
@@ -13422,17 +13411,6 @@
<integer>0</integer>
</array>
</map>
- <key>InboxFreshnessDate</key>
- <map>
- <key>Comment</key>
- <string>Last time the inbox was opened</string>
- <key>Persist</key>
- <integer>1</integer>
- <key>Type</key>
- <string>String</string>
- <key>Value</key>
- <string />
- </map>
<key>HelpFloaterOpen</key>
<map>
<key>Comment</key>
diff --git a/indra/newview/app_settings/settings_per_account.xml b/indra/newview/app_settings/settings_per_account.xml
index ff24efaf2c..1142f01232 100644
--- a/indra/newview/app_settings/settings_per_account.xml
+++ b/indra/newview/app_settings/settings_per_account.xml
@@ -33,6 +33,17 @@
<key>Value</key>
<string />
</map>
+ <key>LastInventoryInboxExpand</key>
+ <map>
+ <key>Comment</key>
+ <string>The last time the received items inbox was expanded.</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>String</string>
+ <key>Value</key>
+ <string />
+ </map>
<key>LastLogoff</key>
<map>
<key>Comment</key>
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index 75d4c4e80d..4ed39da5cb 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -2483,8 +2483,6 @@ void LLFolderBridge::staticFolderOptionsMenu()
void LLFolderBridge::folderOptionsMenu()
{
- menuentry_vec_t disabled_items;
-
LLInventoryModel* model = getInventoryModel();
if(!model) return;
@@ -2552,18 +2550,18 @@ void LLFolderBridge::folderOptionsMenu()
mItems.push_back(std::string("Remove From Outfit"));
if (!LLAppearanceMgr::getCanRemoveFromCOF(mUUID))
{
- disabled_items.push_back(std::string("Remove From Outfit"));
+ mDisabledItems.push_back(std::string("Remove From Outfit"));
}
if (!LLAppearanceMgr::instance().getCanReplaceCOF(mUUID))
{
- disabled_items.push_back(std::string("Replace Outfit"));
+ mDisabledItems.push_back(std::string("Replace Outfit"));
}
mItems.push_back(std::string("Outfit Separator"));
}
LLMenuGL* menup = dynamic_cast<LLMenuGL*>(mMenu.get());
if (menup)
{
- hide_context_entries(*menup, mItems, disabled_items, TRUE);
+ hide_context_entries(*menup, mItems, mDisabledItems, TRUE);
// Reposition the menu, in case we're adding items to an existing menu.
menup->needsArrange();
diff --git a/indra/newview/llpanelmarketplaceinbox.cpp b/indra/newview/llpanelmarketplaceinbox.cpp
index dd3daf5fbb..c505ad85a3 100644
--- a/indra/newview/llpanelmarketplaceinbox.cpp
+++ b/indra/newview/llpanelmarketplaceinbox.cpp
@@ -53,7 +53,10 @@ LLPanelMarketplaceInbox::LLPanelMarketplaceInbox(const Params& p)
LLPanelMarketplaceInbox::~LLPanelMarketplaceInbox()
{
- gSavedSettings.setString("InboxFreshnessDate", LLDate::now().asString());
+ if (getChild<LLButton>("inbox_btn")->getToggleState())
+ {
+ gSavedPerAccountSettings.setString("LastInventoryInboxExpand", LLDate::now().asString());
+ }
}
// virtual
diff --git a/indra/newview/llpanelmarketplaceinboxinventory.cpp b/indra/newview/llpanelmarketplaceinboxinventory.cpp
index 4ea6e98070..2c97d539a1 100644
--- a/indra/newview/llpanelmarketplaceinboxinventory.cpp
+++ b/indra/newview/llpanelmarketplaceinboxinventory.cpp
@@ -182,7 +182,7 @@ void LLInboxFolderViewFolder::draw()
void LLInboxFolderViewFolder::updateFlag() const
{
- LLDate saved_freshness_date = LLDate(gSavedSettings.getString("InboxFreshnessDate"));
+ LLDate saved_freshness_date = LLDate(gSavedPerAccountSettings.getString("LastInventoryInboxExpand"));
mFresh = (mCreationDate > saved_freshness_date.secondsSinceEpoch());
}
diff --git a/indra/newview/llpanelmarketplaceinboxinventory.h b/indra/newview/llpanelmarketplaceinboxinventory.h
index e12508cff4..d2d42e11f4 100644
--- a/indra/newview/llpanelmarketplaceinboxinventory.h
+++ b/indra/newview/llpanelmarketplaceinboxinventory.h
@@ -33,9 +33,9 @@
#include "llfolderviewitem.h"
-#define SUPPORTING_FRESH_ITEM_COUNT 0
-
-
+#define SUPPORTING_FRESH_ITEM_COUNT 1
+
+
class LLInboxInventoryPanel : public LLInventoryPanel
{
diff --git a/indra/newview/llsidepanelinventory.cpp b/indra/newview/llsidepanelinventory.cpp
index 65655f82cd..a0d1247b34 100644
--- a/indra/newview/llsidepanelinventory.cpp
+++ b/indra/newview/llsidepanelinventory.cpp
@@ -61,8 +61,6 @@ static LLRegisterPanelClassWrapper<LLSidepanelInventory> t_inventory("sidepanel_
// Constants
//
-static const char * const INBOX_EXPAND_TIME_SETTING = "LastInventoryInboxExpand";
-
static const char * const INBOX_BUTTON_NAME = "inbox_btn";
static const char * const OUTBOX_BUTTON_NAME = "outbox_btn";
@@ -404,7 +402,7 @@ void LLSidepanelInventory::onInboxChanged(const LLUUID& inbox_id)
// Expand the inbox since we have fresh items
LLPanelMarketplaceInbox * inbox = findChild<LLPanelMarketplaceInbox>(MARKETPLACE_INBOX_PANEL);
- if (inbox && (inbox->getFreshItemCount() > 0))
+ if (inbox)
{
getChild<LLButton>(INBOX_BUTTON_NAME)->setToggleState(true);
onToggleInboxBtn();
@@ -459,12 +457,8 @@ void LLSidepanelInventory::onToggleInboxBtn()
LLLayoutPanel* otherPanel = getChild<LLLayoutPanel>(OUTBOX_LAYOUT_PANEL_NAME);
bool inboxExpanded = manageInboxOutboxPanels(stack, pressedButton, pressedPanel, otherButton, otherPanel);
-
- if (inboxExpanded)
- {
- // Save current time as a setting for future new-ness tests
- gSavedSettings.setString(INBOX_EXPAND_TIME_SETTING, LLDate::now().asString());
- }
+
+ gSavedPerAccountSettings.setString("LastInventoryInboxExpand", LLDate::now().asString());
}
void LLSidepanelInventory::onToggleOutboxBtn()