From 11fc2da6fa5fba0bb659dd97f8533e4529aece06 Mon Sep 17 00:00:00 2001 From: angela Date: Thu, 12 Nov 2009 21:20:18 +0800 Subject: make color and font affecting both nearby chat and toasts --- indra/newview/llimfloater.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'indra/newview/llimfloater.cpp') diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp index 5a2331aa06..2504e1e916 100644 --- a/indra/newview/llimfloater.cpp +++ b/indra/newview/llimfloater.cpp @@ -463,7 +463,7 @@ void LLIMFloater::updateMessages() if (messages.size()) { - LLUIColor chat_color = LLUIColorTable::instance().getColor("IMChatColor"); +// LLUIColor chat_color = LLUIColorTable::instance().getColor("IMChatColor"); std::ostringstream message; std::list::const_reverse_iterator iter = messages.rbegin(); @@ -476,14 +476,11 @@ void LLIMFloater::updateMessages() LLUUID from_id = msg["from_id"].asUUID(); std::string from = from_id != gAgentID ? msg["from"].asString() : LLTrans::getString("You"); std::string message = msg["message"].asString(); - LLStyle::Params style_params; - style_params.color(chat_color); LLChat chat(message); chat.mFromID = from_id; chat.mFromName = from; - - mChatHistory->appendWidgetMessage(chat, style_params); + mChatHistory->appendWidgetMessage(chat); mLastMessageIndex = msg["index"].asInteger(); } -- cgit v1.2.3 From f9cacc57e28a2dcbe5801c71becbb8e2b8eae3e4 Mon Sep 17 00:00:00 2001 From: James Cook Date: Fri, 13 Nov 2009 12:36:41 -0800 Subject: EXT-2491 IM text does not appear in private IMs --- indra/newview/llimfloater.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/newview/llimfloater.cpp') diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp index 0f32d0b313..1467e4e0e0 100644 --- a/indra/newview/llimfloater.cpp +++ b/indra/newview/llimfloater.cpp @@ -479,6 +479,7 @@ void LLIMFloater::updateMessages() LLChat chat; chat.mFromID = from_id; chat.mFromName = from; + chat.mText = message; mChatHistory->appendWidgetMessage(chat); -- cgit v1.2.3 From 1baf1d218644ac5dc00d9b41119a1ef168c709a2 Mon Sep 17 00:00:00 2001 From: angela Date: Mon, 16 Nov 2009 20:46:40 +0800 Subject: fix chat format for /me --- indra/newview/llimfloater.cpp | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) (limited to 'indra/newview/llimfloater.cpp') diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp index e3121fbc7a..dff27ee032 100644 --- a/indra/newview/llimfloater.cpp +++ b/indra/newview/llimfloater.cpp @@ -477,7 +477,33 @@ void LLIMFloater::updateMessages() chat.mFromName = from; chat.mText = message; - mChatHistory->appendWidgetMessage(chat); + LLStyle::Params append_style_params; + //Handle IRC styled /me messages. + std::string prefix = message.substr(0, 4); + if (prefix == "/me " || prefix == "/me'") + { + if (from.size() > 0) + { + append_style_params.italic= true; + chat.mText = from + " "; + mChatHistory->appendWidgetMessage(chat, append_style_params); + } + message = message.substr(3); + + LLColor4 txt_color = LLUIColorTable::instance().getColor("White"); + LLViewerChat::getChatColor(chat,txt_color); + LLFontGL* fontp = LLViewerChat::getChatFont(); + append_style_params.color(txt_color); + append_style_params.readonly_color(txt_color); + append_style_params.font(fontp); + append_style_params.underline = true; + mChatHistory->appendText(message, FALSE, append_style_params); + } + else + { + chat.mText = message; + mChatHistory->appendWidgetMessage(chat); + } mLastMessageIndex = msg["index"].asInteger(); } -- cgit v1.2.3 From 0098bf40ea73078e2164ae55a8fa2f9049d0d4e9 Mon Sep 17 00:00:00 2001 From: angela Date: Tue, 17 Nov 2009 16:33:49 +0800 Subject: undo the changes for LLStyle params; add sizeFromFont in LLFontGL ; use font.style, font.name and font.size params for font creating --- indra/newview/llimfloater.cpp | 27 ++++++++++++++++----------- 1 file changed, 16 insertions(+), 11 deletions(-) (limited to 'indra/newview/llimfloater.cpp') diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp index dff27ee032..2c6543d6ca 100644 --- a/indra/newview/llimfloater.cpp +++ b/indra/newview/llimfloater.cpp @@ -476,27 +476,32 @@ void LLIMFloater::updateMessages() chat.mFromID = from_id; chat.mFromName = from; chat.mText = message; - - LLStyle::Params append_style_params; + //Handle IRC styled /me messages. std::string prefix = message.substr(0, 4); if (prefix == "/me " || prefix == "/me'") { - if (from.size() > 0) - { - append_style_params.italic= true; - chat.mText = from + " "; - mChatHistory->appendWidgetMessage(chat, append_style_params); - } - message = message.substr(3); LLColor4 txt_color = LLUIColorTable::instance().getColor("White"); LLViewerChat::getChatColor(chat,txt_color); LLFontGL* fontp = LLViewerChat::getChatFont(); + std::string font_name = LLFontGL::nameFromFont(fontp); + std::string font_size = LLFontGL::sizeFromFont(fontp); + LLStyle::Params append_style_params; append_style_params.color(txt_color); append_style_params.readonly_color(txt_color); - append_style_params.font(fontp); - append_style_params.underline = true; + append_style_params.font.name(font_name); + append_style_params.font.size(font_size); + + if (from.size() > 0) + { + append_style_params.font.style = "ITALIC"; + chat.mText = from + " "; + mChatHistory->appendWidgetMessage(chat, append_style_params); + } + + message = message.substr(3); + append_style_params.font.style = "UNDERLINE"; mChatHistory->appendText(message, FALSE, append_style_params); } else -- cgit v1.2.3 From d43e33400a2ef9d89ed6d13067055b5b1edbde78 Mon Sep 17 00:00:00 2001 From: Alexei Arabadji Date: Tue, 17 Nov 2009 14:33:07 +0200 Subject: implemented EXT-2515 "Docked floaters should be resizeable"; --HG-- branch : product-engine --- indra/newview/llimfloater.cpp | 2 -- 1 file changed, 2 deletions(-) (limited to 'indra/newview/llimfloater.cpp') diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp index e3121fbc7a..b56e858086 100644 --- a/indra/newview/llimfloater.cpp +++ b/indra/newview/llimfloater.cpp @@ -367,8 +367,6 @@ void LLIMFloater::setDocked(bool docked, bool pop_on_undock) LLNotificationsUI::LLScreenChannel* channel = dynamic_cast (LLNotificationsUI::LLChannelManager::getInstance()-> findChannelByID(LLUUID(gSavedSettings.getString("NotificationChannelUUID")))); - - setCanResize(!docked); LLTransientDockableFloater::setDocked(docked, pop_on_undock); -- cgit v1.2.3 From 0422eadf2ad4db0308a034a2b6426e19898451c4 Mon Sep 17 00:00:00 2001 From: Igor Borovkov Date: Tue, 17 Nov 2009 16:28:47 +0200 Subject: implemented major EXT-2523 The minimize button should hide undocked IM windows, not minimize them --HG-- branch : product-engine --- indra/newview/llimfloater.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'indra/newview/llimfloater.cpp') diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp index b56e858086..00ecbb8a9d 100644 --- a/indra/newview/llimfloater.cpp +++ b/indra/newview/llimfloater.cpp @@ -377,6 +377,15 @@ void LLIMFloater::setDocked(bool docked, bool pop_on_undock) } } +void LLIMFloater::setMinimized(BOOL minimize) +{ + if(minimize && !isDocked()) + { + setVisible(FALSE); + } + LLDockableFloater::setMinimized(minimize); +} + void LLIMFloater::setVisible(BOOL visible) { LLNotificationsUI::LLScreenChannel* channel = dynamic_cast -- cgit v1.2.3 From a66aa0fd9a7aa20484521bf9b3809297e31466b0 Mon Sep 17 00:00:00 2001 From: Igor Borovkov Date: Tue, 17 Nov 2009 18:42:51 +0200 Subject: fixed major EXT-2551 Nearby Chat undocs after minimizing and opening (being docked before) --HG-- branch : product-engine --- indra/newview/llimfloater.cpp | 9 --------- 1 file changed, 9 deletions(-) (limited to 'indra/newview/llimfloater.cpp') diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp index 890f587467..c2c83191e0 100644 --- a/indra/newview/llimfloater.cpp +++ b/indra/newview/llimfloater.cpp @@ -377,15 +377,6 @@ void LLIMFloater::setDocked(bool docked, bool pop_on_undock) } } -void LLIMFloater::setMinimized(BOOL minimize) -{ - if(minimize && !isDocked()) - { - setVisible(FALSE); - } - LLDockableFloater::setMinimized(minimize); -} - void LLIMFloater::setVisible(BOOL visible) { LLNotificationsUI::LLScreenChannel* channel = dynamic_cast -- cgit v1.2.3