--- indra/newview/llfloaterchat.cpp Tue Jun 26 16:49:34 2007 +++ indra/newview/llfloaterchat.cpp Thu Jun 28 22:35:15 2007 @@ -162,24 +162,22 @@ } // static void LLFloaterChat::addChatHistory(const LLChat& chat, bool log_to_file) { if ( gSavedPerAccountSettings.getBOOL("LogChat") && log_to_file) { log_chat_text(chat); } LLColor4 color = get_text_color(chat); - if (!log_to_file) color = LLColor4::grey; //Recap from log file. - if (chat.mChatType == CHAT_TYPE_DEBUG_MSG) { LLFloaterScriptDebug::addScriptLine(chat.mText, chat.mFromName, color, chat.mFromID); if (!gSavedSettings.getBOOL("ScriptErrorsAsChat")) { return; } } @@ -362,31 +360,38 @@ if (!invisible_script_debug_chat && !chat.mMuted && gConsole && !local_agent) { F32 size = CHAT_MSG_SIZE; if(from_instant_message) { text_color = INSTANT_MSG_COLOR; size = INSTANT_MSG_SIZE; + if(gSavedSettings.getBOOL("IMInChatHistory")) + gConsole->addLine(chat.mText, size, text_color); + } + else + { + gConsole->addLine(chat.mText, size, text_color); } - gConsole->addLine(chat.mText, size, text_color); } if(from_instant_message && gSavedPerAccountSettings.getBOOL("LogChatIM")) log_chat_text(chat); if(from_instant_message && gSavedSettings.getBOOL("IMInChatHistory")) + { addChatHistory(chat,false); + } if(!from_instant_message) addChatHistory(chat); } LLColor4 get_text_color(const LLChat& chat) { LLColor4 text_color; if(chat.mMuted) { @@ -429,30 +434,36 @@ if (!chat.mPosAgent.isExactlyZero()) { LLVector3 pos_agent = gAgent.getPositionAgent(); F32 distance = dist_vec(pos_agent, chat.mPosAgent); if (distance > gAgent.getNearChatRadius()) { // diminish far-off chat text_color.mV[VALPHA] = 0.8f; } } + + if (chat.mAudible == CHAT_AUDIBLE_NOT) + { + text_color.mV[VALPHA] = 0.7f; + } } return text_color; } //static void LLFloaterChat::loadHistory() { LLLogChat::loadHistory("chat", &chatFromLogFile, (void *)gFloaterChat); } //static void LLFloaterChat::chatFromLogFile(LLString line, void* userdata) { LLChat chat; chat.mText = line; + chat.mAudible = CHAT_AUDIBLE_NOT; addChatHistory(chat, FALSE); }