diff options
Diffstat (limited to 'indra/newview/lllogchat.cpp')
-rw-r--r-- | indra/newview/lllogchat.cpp | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/indra/newview/lllogchat.cpp b/indra/newview/lllogchat.cpp index 485d4677b1..b9194c6c67 100644 --- a/indra/newview/lllogchat.cpp +++ b/indra/newview/lllogchat.cpp @@ -132,15 +132,9 @@ void append_to_last_message(std::list<LLSD>& messages, const std::string& line) class LLLogChatTimeScanner: public LLSingleton<LLLogChatTimeScanner> { -public: - LLLogChatTimeScanner() - { - // Note, date/time facets will be destroyed by string streams - mDateStream.imbue(std::locale(mDateStream.getloc(), new date_input_facet(DATE_FORMAT))); - mTimeStream.imbue(std::locale(mTimeStream.getloc(), new time_facet(TIME_FORMAT))); - mTimeStream.imbue(std::locale(mTimeStream.getloc(), new time_input_facet(DATE_FORMAT))); - } + LLSINGLETON(LLLogChatTimeScanner); +public: date getTodayPacificDate() { typedef boost::date_time::local_adjustor<ptime, -8, no_dst> pst; @@ -205,6 +199,15 @@ private: std::stringstream mTimeStream; }; +inline +LLLogChatTimeScanner::LLLogChatTimeScanner() +{ + // Note, date/time facets will be destroyed by string streams + mDateStream.imbue(std::locale(mDateStream.getloc(), new date_input_facet(DATE_FORMAT))); + mTimeStream.imbue(std::locale(mTimeStream.getloc(), new time_facet(TIME_FORMAT))); + mTimeStream.imbue(std::locale(mTimeStream.getloc(), new time_input_facet(DATE_FORMAT))); +} + LLLogChat::save_history_signal_t * LLLogChat::sSaveHistorySignal = NULL; std::map<LLUUID,LLLoadHistoryThread *> LLLogChat::sLoadHistoryThreads; |