From 36e0f729d33a2e87809f8185cb73016e54ba76a5 Mon Sep 17 00:00:00 2001 From: Dmitry Oleshko Date: Thu, 12 Nov 2009 12:59:04 +0200 Subject: final fix for (EXT-989) IM chiclets should expand to show active voice indicator (EXT-988) Change indication of unread messges in chiclets fixed chiclets' behavior in the Message Well Window --HG-- branch : product-engine --- indra/newview/llchiclet.cpp | 44 ++++++++++++++++------ indra/newview/llsyswellwindow.cpp | 9 +++-- .../skins/default/xui/en/panel_activeim_row.xml | 42 +++++++++++++++++++-- 3 files changed, 77 insertions(+), 18 deletions(-) (limited to 'indra') diff --git a/indra/newview/llchiclet.cpp b/indra/newview/llchiclet.cpp index b919195fb2..e416151748 100644 --- a/indra/newview/llchiclet.cpp +++ b/indra/newview/llchiclet.cpp @@ -54,10 +54,12 @@ static LLDefaultChildRegistry::Register t1("chiclet_panel"); static LLDefaultChildRegistry::Register t2("chiclet_notification"); static LLDefaultChildRegistry::Register t3("chiclet_im_p2p"); static LLDefaultChildRegistry::Register t4("chiclet_im_group"); +static LLDefaultChildRegistry::Register t5("chiclet_im_adhoc"); static const LLRect CHICLET_RECT(0, 25, 25, 0); -static const LLRect CHICLET_ICON_RECT(0, 24, 24, 0); +static const LLRect CHICLET_ICON_RECT(0, 22, 22, 0); static const LLRect VOICE_INDICATOR_RECT(25, 25, 45, 0); +static const S32 OVERLAY_ICON_SHIFT = 2; // used for shifting of an overlay icon for new massages in a chiclet // static const S32 LLChicletPanel::s_scroll_ratio = 10; @@ -217,13 +219,15 @@ LLIMChiclet::LLIMChiclet(const LLIMChiclet::Params& p) icon_params.visible = false; icon_params.image = LLUI::getUIImage(p.new_messages_icon_name); mNewMessagesIcon = LLUICtrlFactory::create(icon_params); + addChild(mNewMessagesIcon); + // adjust size and position of an icon LLRect chiclet_rect = p.rect; - LLRect overlay_icon_rect = LLRect(chiclet_rect.getWidth()/2, chiclet_rect.mTop, chiclet_rect.mRight, chiclet_rect.getHeight()/2); - // shift an icon a little bit to the right and up corner of a chiclet - overlay_icon_rect.translate(overlay_icon_rect.getWidth()/5, overlay_icon_rect.getHeight()/5); + LLRect overlay_icon_rect = LLRect(chiclet_rect.getWidth()/2, chiclet_rect.getHeight(), chiclet_rect.getWidth(), chiclet_rect.getHeight()/2); mNewMessagesIcon->setRect(overlay_icon_rect); - addChild(mNewMessagesIcon); + + // shift an icon a little bit to the right and up corner of a chiclet + overlay_icon_rect.translate(OVERLAY_ICON_SHIFT, OVERLAY_ICON_SHIFT); setShowCounter(false); } @@ -602,6 +606,9 @@ BOOL LLAdHocChiclet::handleRightMouseDown(S32 x, S32 y, MASK mask) LLIMGroupChiclet::Params::Params() : group_icon("group_icon") +, unread_notifications("unread_notifications") +, speaker("speaker") +, show_speaker("show_speaker") { rect(CHICLET_RECT); @@ -880,19 +887,34 @@ BOOL LLChicletPanel::postBuild() void LLChicletPanel::onCurrentVoiceChannelChanged(const LLUUID& session_id) { - for(chiclet_list_t::iterator it = mChicletList.begin(); it != mChicletList.end(); ++it) + static LLUUID s_previous_active_voice_session_id; + + std::list chiclets = LLIMChiclet::sFindChicletsSignal(session_id); + + for(std::list::iterator it = chiclets.begin(); it != chiclets.end(); ++it) { LLIMChiclet* chiclet = dynamic_cast(*it); if(chiclet) { - if(chiclet->getSessionId() == session_id) + chiclet->setShowSpeaker(true); + } + } + + if(!s_previous_active_voice_session_id.isNull() && s_previous_active_voice_session_id != session_id) + { + chiclets = LLIMChiclet::sFindChicletsSignal(s_previous_active_voice_session_id); + + for(std::list::iterator it = chiclets.begin(); it != chiclets.end(); ++it) + { + LLIMChiclet* chiclet = dynamic_cast(*it); + if(chiclet) { - chiclet->setShowSpeaker(true); - continue; + chiclet->setShowSpeaker(false); } - chiclet->setShowSpeaker(false); - } + } } + + s_previous_active_voice_session_id = session_id; } S32 LLChicletPanel::calcChickletPanleWidth() diff --git a/indra/newview/llsyswellwindow.cpp b/indra/newview/llsyswellwindow.cpp index 4422c4b672..2fb6550107 100644 --- a/indra/newview/llsyswellwindow.cpp +++ b/indra/newview/llsyswellwindow.cpp @@ -501,14 +501,14 @@ LLSysWellWindow::RowPanel::RowPanel(const LLSysWellWindow* parent, const LLUUID& switch (im_chiclet_type) { case LLIMChiclet::TYPE_GROUP: + mChiclet = getChild("group_chiclet"); + break; case LLIMChiclet::TYPE_AD_HOC: - mChiclet = getChild("group_chiclet"); - childSetVisible("p2p_chiclet", false); + mChiclet = getChild("adhoc_chiclet"); break; case LLIMChiclet::TYPE_UNKNOWN: // assign mChiclet a non-null value anyway case LLIMChiclet::TYPE_IM: - mChiclet = getChild("p2p_chiclet"); - childSetVisible("group_chiclet", false); + mChiclet = getChild("p2p_chiclet"); break; } @@ -517,6 +517,7 @@ LLSysWellWindow::RowPanel::RowPanel(const LLSysWellWindow* parent, const LLUUID& mChiclet->setSessionId(sessionId); mChiclet->setIMSessionName(name); mChiclet->setOtherParticipantId(otherParticipantId); + mChiclet->setVisible(true); LLTextBox* contactName = getChild("contact_name"); contactName->setValue(name); diff --git a/indra/newview/skins/default/xui/en/panel_activeim_row.xml b/indra/newview/skins/default/xui/en/panel_activeim_row.xml index 8b815b0f71..5562ec8406 100644 --- a/indra/newview/skins/default/xui/en/panel_activeim_row.xml +++ b/indra/newview/skins/default/xui/en/panel_activeim_row.xml @@ -15,7 +15,16 @@ top="3" left="5" height="25" - width="25"> + width="25" + visible="false" + speaker.name="speaker_p2p" + speaker.width="20" + speaker.height="25" + speaker.left="25" + speaker.top="25" + speaker.auto_update="true" + speaker.draw_border="false" + speaker.visible="false"> + width="25" + visible="false" + speaker.name="speaker_grp" + speaker.width="20" + speaker.height="25" + speaker.left="25" + speaker.top="25" + speaker.auto_update="true" + speaker.draw_border="false" + speaker.visible="false"> + + Date: Thu, 12 Nov 2009 13:29:27 +0200 Subject: Fixed Low bug EXT-2345-There is wrong direction arrow in IM window, after this window has been closed and restored (refer to screenshot) --HG-- branch : product-engine --- indra/newview/llimfloater.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'indra') diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp index 54fc6f02fb..5ea900e46d 100644 --- a/indra/newview/llimfloater.cpp +++ b/indra/newview/llimfloater.cpp @@ -211,6 +211,7 @@ BOOL LLIMFloater::postBuild() } mControlPanel->setSessionId(mSessionID); + mControlPanel->setVisible(gSavedSettings.getBOOL("IMShowControlPanel")); LLButton* slide_left = getChild("slide_left_btn"); slide_left->setVisible(mControlPanel->getVisible()); @@ -356,8 +357,6 @@ LLIMFloater* LLIMFloater::show(const LLUUID& session_id) LLDockControl::TOP, boost::bind(&LLIMFloater::getAllowedRect, floater, _1))); } - floater->childSetVisible("panel_im_control_panel", gSavedSettings.getBOOL("IMShowControlPanel")); - return floater; } -- cgit v1.2.3 From 01d90c3d3e90321be326db04ecd2e09328cb189e Mon Sep 17 00:00:00 2001 From: Mike Antipov Date: Thu, 12 Nov 2009 14:25:34 +0200 Subject: Work on major sub-task EXT-991 (Update bottom bar behavior on resize) increased chat bar text field to compensate changes in changeset: 4652 : d0832cfa71c6 (for EXT-2356 Replace Log button in bottom tray with up arrow) --HG-- branch : product-engine --- indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra') diff --git a/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml b/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml index 1ef845b769..a77094e942 100644 --- a/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml +++ b/indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml @@ -27,7 +27,7 @@ name="chat_box" tool_tip="Press Enter to say, Ctrl+Enter to shout" top="0" - width="250" /> + width="279" />