From 53be27e742b642c1642c3289e3e11b300a14d360 Mon Sep 17 00:00:00 2001 From: Yuri Chebotarev Date: Tue, 17 Nov 2009 14:40:02 +0200 Subject: fox4 low task EXT-2480 Open Blocked List panel when blocking an object from nearby chat console --HG-- branch : product-engine --- indra/newview/llchathistory.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'indra/newview/llchathistory.cpp') diff --git a/indra/newview/llchathistory.cpp b/indra/newview/llchathistory.cpp index 028bb7a384..9916175775 100644 --- a/indra/newview/llchathistory.cpp +++ b/indra/newview/llchathistory.cpp @@ -46,6 +46,8 @@ #include "llfloaterreg.h" #include "llmutelist.h" +#include "llsidetray.h"//for blocked objects panel + static LLDefaultChildRegistry::Register r("chat_history"); std::string formatCurrentTime() @@ -92,6 +94,8 @@ public: else if (level == "block") { LLMuteList::getInstance()->add(LLMute(getAvatarId(), mFrom, LLMute::OBJECT)); + + LLSideTray::getInstance()->showPanel("panel_block_list_sidetray", LLSD().insert("blocked_to_select", getAvatarId())); } } -- cgit v1.2.3 From b3cb61a26a0e4c7bfc3c18fd2705325a795684b8 Mon Sep 17 00:00:00 2001 From: Eugene Kondrashev Date: Wed, 18 Nov 2009 17:57:47 +0200 Subject: Fixed major bug EXT-2532-IM timestamp is when message is viewed, not when it was sent and received. Time str from the arriving message used now instead of constructing it dynamicly. --HG-- branch : product-engine --- indra/newview/llchathistory.cpp | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) (limited to 'indra/newview/llchathistory.cpp') diff --git a/indra/newview/llchathistory.cpp b/indra/newview/llchathistory.cpp index cd5c5edac0..4ce3b50ed5 100644 --- a/indra/newview/llchathistory.cpp +++ b/indra/newview/llchathistory.cpp @@ -50,21 +50,6 @@ static LLDefaultChildRegistry::Register r("chat_history"); -std::string formatCurrentTime() -{ - time_t utc_time; - utc_time = time_corrected(); - std::string timeStr ="["+ LLTrans::getString("TimeHour")+"]:[" - +LLTrans::getString("TimeMin")+"]"; - - LLSD substitution; - - substitution["datetime"] = (S32) utc_time; - LLStringUtil::format (timeStr, substitution); - - return timeStr; -} - class LLChatHistoryHeader: public LLPanel { public: @@ -219,7 +204,7 @@ public: LLTextBox* timeBox = getChild("time_box"); - timeBox->setValue(formatCurrentTime()); + timeBox->setValue(chat.mTimeStr); LLAvatarIconCtrl* icon = getChild("avatar_icon"); @@ -352,7 +337,7 @@ LLView* LLChatHistory::getHeader(const LLChat& chat,const LLStyle::Params& style void LLChatHistory::appendWidgetMessage(const LLChat& chat, const LLStyle::Params& input_append_params) { LLView* view = NULL; - std::string view_text = "\n[" + formatCurrentTime() + "] "; + std::string view_text = "\n[" + chat.mTimeStr + "] "; if (utf8str_trim(chat.mFromName).size() != 0 && chat.mFromName != SYSTEM_FROM) view_text += chat.mFromName + ": "; -- cgit v1.2.3