diff options
author | Leslie Linden <leslie@lindenlab.com> | 2011-09-08 11:45:12 -0700 |
---|---|---|
committer | Leslie Linden <leslie@lindenlab.com> | 2011-09-08 11:45:12 -0700 |
commit | ea18429a2c3b76aee4293f0031b8b5d5a8ee9aba (patch) | |
tree | f3fb0c4eeacd725c552c870e2e08c6c08910478f | |
parent | 1c7b1532e994f8c4d1c69e419e34f07c1a9ee918 (diff) |
EXP-1194 FIX -- Update New tag behavior to update Newness timestamp when Received Items panel is open and do not auto open Received Items panel
The freshness calculation now takes into account the timezone difference between LLDate's return value of GMT and the inventory server's GMT-7 times.
-rw-r--r-- | indra/newview/llpanelmarketplaceinboxinventory.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/indra/newview/llpanelmarketplaceinboxinventory.cpp b/indra/newview/llpanelmarketplaceinboxinventory.cpp index 47f34434db..ac517f3f3e 100644 --- a/indra/newview/llpanelmarketplaceinboxinventory.cpp +++ b/indra/newview/llpanelmarketplaceinboxinventory.cpp @@ -196,14 +196,16 @@ void LLInboxFolderViewFolder::computeFreshness() if (!last_expansion.empty()) { - LLDate saved_freshness_date = LLDate(last_expansion); + // Inventory DB timezone is hardcoded to PDT or GMT-7, which is 7 hours behind GMT + const time_t SEVEN_HOURS_IN_SECONDS = 7 * 60 * 60; + const time_t saved_freshness_inventory_db_timezone = LLDate(last_expansion).secondsSinceEpoch() - SEVEN_HOURS_IN_SECONDS; - mFresh = (mCreationDate > saved_freshness_date.secondsSinceEpoch()); + mFresh = (mCreationDate > saved_freshness_inventory_db_timezone); #if DEBUGGING_FRESHNESS if (mFresh) { - llinfos << "Item is fresh! -- creation " << mCreationDate << ", saved_freshness_date " << saved_freshness_date.secondsSinceEpoch() << llendl; + llinfos << "Item is fresh! -- creation " << mCreationDate << ", saved_freshness_date " << saved_freshness_inventory_db_timezone << llendl; } #endif } |