diff options
| author | Leyla Farazha <leyla@lindenlab.com> | 2010-10-14 14:03:16 -0700 |
|---|---|---|
| committer | Leyla Farazha <leyla@lindenlab.com> | 2010-10-14 14:03:16 -0700 |
| commit | 508686047d5e98934d5fefbb576e54f108df6fe3 (patch) | |
| tree | 6d751588cc200395d4fef41e61f4683a83a7ab86 /indra/newview/lldateutil.cpp | |
| parent | 2303ec6213ea7a591e0084e9fc9350b2afddd3c5 (diff) | |
| parent | f53f6f20df5c99311103c3d92938ce878d474f13 (diff) | |
Merge from http://hg.secondlife.com/viewer-identity (display names)
Diffstat (limited to 'indra/newview/lldateutil.cpp')
| -rw-r--r-- | indra/newview/lldateutil.cpp | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/indra/newview/lldateutil.cpp b/indra/newview/lldateutil.cpp index e575e06c5a..fcc73a07bc 100644 --- a/indra/newview/lldateutil.cpp +++ b/indra/newview/lldateutil.cpp @@ -166,3 +166,23 @@ std::string LLDateUtil::ageFromDate(const std::string& date_string) { return ageFromDate(date_string, LLDate::now()); } + +//std::string LLDateUtil::ageFromDateISO(const std::string& date_string, +// const LLDate& now) +//{ +// S32 born_month, born_day, born_year; +// S32 matched = sscanf(date_string.c_str(), "%d-%d-%d", +// &born_year, &born_month, &born_day); +// if (matched != 3) return "???"; +// date.fromYMDHMS(year, month, day); +// F64 secs_since_epoch = date.secondsSinceEpoch(); +// // Correct for the fact that specified date is in Pacific time, == UTC - 8 +// secs_since_epoch += 8.0 * 60.0 * 60.0; +// date.secondsSinceEpoch(secs_since_epoch); +// return ageFromDate(born_year, born_month, born_day, now); +//} +// +//std::string LLDateUtil::ageFromDateISO(const std::string& date_string) +//{ +// return ageFromDateISO(date_string, LLDate::now()); +//} |
