From 7e8d336749b42ce134a67dfe1f1990644f1b263a Mon Sep 17 00:00:00 2001 From: "maxim@mnikolenko" Date: Fri, 28 Dec 2012 15:28:19 +0200 Subject: CHUI-639 FIXED Min. width is increased to avoid overlapping --- indra/newview/skins/default/xui/en/floater_conversation_log.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra') diff --git a/indra/newview/skins/default/xui/en/floater_conversation_log.xml b/indra/newview/skins/default/xui/en/floater_conversation_log.xml index cf61348a66..256e03c4d7 100644 --- a/indra/newview/skins/default/xui/en/floater_conversation_log.xml +++ b/indra/newview/skins/default/xui/en/floater_conversation_log.xml @@ -5,7 +5,7 @@ positioning="cascading" height="200" min_height="100" - min_width="200" + min_width="230" layout="topleft" name="floater_conversation_log" save_rect="true" -- cgit v1.2.3 From d99fa985c8ff65913e85dfaa9fd91892a197c4cc Mon Sep 17 00:00:00 2001 From: AlexanderP ProductEngine Date: Fri, 28 Dec 2012 18:55:24 +0200 Subject: CHUI-566 ADD. FIX Flashing and color on Conversations FUI button and conversation line item Cancel sticking of color, if the button is pressed, or when a flashing of the previously selected button is ended --- indra/llui/llbutton.cpp | 18 +++++++++++++----- indra/newview/llimview.cpp | 16 ++++++---------- 2 files changed, 19 insertions(+), 15 deletions(-) (limited to 'indra') diff --git a/indra/llui/llbutton.cpp b/indra/llui/llbutton.cpp index 7ca9b869a8..a8149a9a1d 100644 --- a/indra/llui/llbutton.cpp +++ b/indra/llui/llbutton.cpp @@ -311,7 +311,7 @@ void LLButton::onCommit() { make_ui_sound("UISndClickRelease"); } - + if (mIsToggle) { toggleState(); @@ -613,8 +613,6 @@ void LLButton::draw() static LLCachedControl sEnableButtonFlashing(*LLUI::sSettingGroups["config"], "EnableButtonFlashing", true); F32 alpha = mUseDrawContextAlpha ? getDrawContext().mAlpha : getCurrentTransparency(); - bool flash = mFlashing && sEnableButtonFlashing; - bool pressed_by_keyboard = FALSE; if (hasFocus()) { @@ -642,6 +640,17 @@ void LLButton::draw() LLColor4 glow_color; LLRender::eBlendType glow_type = LLRender::BT_ADD_WITH_ALPHA; LLUIImage* imagep = NULL; + + // Cancel sticking of color, if the button is pressed, + // or when a flashing of the previously selected button is ended + if (mFlashingTimer + && ((selected && !mFlashingTimer->isFlashingInProgress()) || pressed)) + { + mFlashing = false; + } + + bool flash = mFlashing && sEnableButtonFlashing; + if (pressed && mDisplayPressedState) { imagep = selected ? mImagePressedSelected : mImagePressed; @@ -697,8 +706,7 @@ void LLButton::draw() imagep = mImageDisabled; } - // Selected has a higher priority than flashing. If both are set, flashing is ignored. - if (mFlashing && !selected) + if (mFlashing) { // if button should flash and we have icon for flashing, use it as image for button if(flash && mImageFlash) diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp index d736b81bb7..48cf7b3463 100644 --- a/indra/newview/llimview.cpp +++ b/indra/newview/llimview.cpp @@ -122,7 +122,7 @@ void on_new_message(const LLSD& msg) LLUUID session_id = msg["session_id"].asUUID(); LLIMModel::LLIMSession* session = LLIMModel::instance().findIMSession(session_id); - // determine action for this session + // determine action for this session if (session_id.isNull()) { @@ -148,13 +148,14 @@ void on_new_message(const LLSD& msg) action = gSavedSettings.getString("NotificationGroupChatOptions"); } - // do not show notification in "do not disturb" mode or it goes from agent + // do not show notification which goes from agent if (gAgent.getID() == participant_id) { return; } // execution of the action + LLFloaterIMContainer* im_box = LLFloaterReg::getTypedInstance("im_container"); LLFloaterIMSessionTab* session_floater = LLFloaterIMSessionTab::getConversation(session_id); @@ -173,7 +174,7 @@ void on_new_message(const LLSD& msg) if ("toast" == action) { - // Skip toasting if we have open window of IM with this session id + // Skip toasting and flashing if we have open window of IM with this session id if (session_floater && session_floater->isInVisibleChain() && session_floater->hasFocus() @@ -184,12 +185,6 @@ void on_new_message(const LLSD& msg) return; } - // Skip toasting for system messages and for nearby chat - if (participant_id.isNull()) - { - return; - } - //User is not focused on conversation containing the message if(session_floater_not_focused) { @@ -201,7 +196,8 @@ void on_new_message(const LLSD& msg) gToolBarView->flashCommand(LLCommandId("chat"), true); //Show IM toasts (upper right toasts) - if(session_id.notNull()) + // Skip toasting for system messages and for nearby chat + if(session_id.notNull() && participant_id.notNull()) { LLAvatarNameCache::get(participant_id, boost::bind(&on_avatar_name_cache_toast, _1, _2, msg)); } -- cgit v1.2.3 From a25e6eb733bb8f6a0e9f8de1094155f685c6216d Mon Sep 17 00:00:00 2001 From: AlexanderP ProductEngine Date: Fri, 28 Dec 2012 16:11:05 +0200 Subject: CHUI-453 FIXED Tooltip on chevron in torn-off conversation is incorrect: implemented suitable tool-tips; fixed a small separate bug ("tooltip_to_separate_window"/"tooltip_to_main_window" for Tear-Off Button: was shown reverse) --- indra/newview/llfloaterimsessiontab.cpp | 24 ++++++++++++++-------- .../skins/default/xui/en/floater_im_session.xml | 9 ++++++++ 2 files changed, 24 insertions(+), 9 deletions(-) (limited to 'indra') diff --git a/indra/newview/llfloaterimsessiontab.cpp b/indra/newview/llfloaterimsessiontab.cpp index 4e79bd0ac8..a79b4b3f1d 100644 --- a/indra/newview/llfloaterimsessiontab.cpp +++ b/indra/newview/llfloaterimsessiontab.cpp @@ -606,8 +606,8 @@ void LLFloaterIMSessionTab::updateHeaderAndToolbar() // prevent start conversation before its container LLFloaterIMContainer::getInstance(); - bool is_torn_off = checkIfTornOff(); - if (!is_torn_off) + bool is_not_torn_off = !checkIfTornOff(); + if (is_not_torn_off) { hideAllStandardButtons(); } @@ -616,7 +616,7 @@ void LLFloaterIMSessionTab::updateHeaderAndToolbar() // Participant list should be visible only in torn off floaters. bool is_participant_list_visible = - is_torn_off + !is_not_torn_off && gSavedSettings.getBOOL("IMShowControlPanel") && !mIsP2PChat; @@ -624,22 +624,28 @@ void LLFloaterIMSessionTab::updateHeaderAndToolbar() // Display collapse image (<<) if the floater is hosted // or if it is torn off but has an open control panel. - bool is_expanded = !is_torn_off || is_participant_list_visible; + bool is_expanded = is_not_torn_off || is_participant_list_visible; mExpandCollapseBtn->setImageOverlay(getString(is_expanded ? "collapse_icon" : "expand_icon")); + mExpandCollapseBtn->setToolTip( + is_not_torn_off? + getString("expcol_button_not_tearoff_tooltip") : + (is_expanded? + getString("expcol_button_tearoff_and_expanded_tooltip") : + getString("expcol_button_tearoff_and_collapsed_tooltip"))); // toggle floater's drag handle and title visibility if (mDragHandle) { - mDragHandle->setTitleVisible(is_torn_off); + mDragHandle->setTitleVisible(!is_not_torn_off); } // The button (>>) should be disabled for torn off P2P conversations. - mExpandCollapseBtn->setEnabled(!is_torn_off || !mIsP2PChat); + mExpandCollapseBtn->setEnabled(is_not_torn_off || !mIsP2PChat); - mTearOffBtn->setImageOverlay(getString(is_torn_off? "return_icon" : "tear_off_icon")); - mTearOffBtn->setToolTip(getString(!is_torn_off? "tooltip_to_separate_window" : "tooltip_to_main_window")); + mTearOffBtn->setImageOverlay(getString(is_not_torn_off? "tear_off_icon" : "return_icon")); + mTearOffBtn->setToolTip(getString(is_not_torn_off? "tooltip_to_separate_window" : "tooltip_to_main_window")); - mCloseBtn->setVisible(!is_torn_off && !mIsNearbyChat); + mCloseBtn->setVisible(is_not_torn_off && !mIsNearbyChat); enableDisableCallBtn(); diff --git a/indra/newview/skins/default/xui/en/floater_im_session.xml b/indra/newview/skins/default/xui/en/floater_im_session.xml index 9e2132dc3b..8f0574177f 100644 --- a/indra/newview/skins/default/xui/en/floater_im_session.xml +++ b/indra/newview/skins/default/xui/en/floater_im_session.xml @@ -49,6 +49,15 @@ + + + Date: Thu, 3 Jan 2013 14:03:33 +0200 Subject: CHUI-636 FIXED Enable group context menu options, if uuid is empty and selected model item is group chat. In addition enable Chat history item for ad-hoc and group conversations. --- indra/newview/llfloaterimcontainer.cpp | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) (limited to 'indra') diff --git a/indra/newview/llfloaterimcontainer.cpp b/indra/newview/llfloaterimcontainer.cpp index 2019a35faa..61a67a1f9f 100644 --- a/indra/newview/llfloaterimcontainer.cpp +++ b/indra/newview/llfloaterimcontainer.cpp @@ -1101,12 +1101,20 @@ bool LLFloaterIMContainer::enableContextMenuItem(const LLSD& userdata) uuid_vec_t uuids; getParticipantUUIDs(uuids); + //Enable Chat history item for ad-hoc and group conversations + if ("can_chat_history" == item) + { + if (getCurSelectedViewModelItem()->getType() != LLConversationItem::CONV_PARTICIPANT) + { + return isConversationLoggingAllowed(); + } + } - // If nothing is selected, everything needs to be disabled + // If nothing is selected(and selected item is not group chat), everything needs to be disabled if (uuids.size() <= 0) - { - return false; - } + { + return getCurSelectedViewModelItem()->getType() == LLConversationItem::CONV_SESSION_GROUP; + } if("can_activate_group" == item) { @@ -1123,7 +1131,7 @@ bool LLFloaterIMContainer::enableContextMenuItem(const std::string& item, uuid_v { return gSavedSettings.getBOOL("KeepConversationLogTranscripts"); } - + // Extract the single select info bool is_single_select = (uuids.size() == 1); const LLUUID& single_id = uuids.front(); -- cgit v1.2.3 From f4902521f58956eda7701770eec51763a7663d3c Mon Sep 17 00:00:00 2001 From: AlexanderP ProductEngine Date: Thu, 3 Jan 2013 15:12:11 +0200 Subject: CHUI-631 FIXED 'Nearby chat' is not selected in Conversations floater after closing separate conversation if list of participants was expand in Conversations floater: force select 'Nearby chat' when session floater is destroyed --- indra/newview/llfloaterimsessiontab.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'indra') diff --git a/indra/newview/llfloaterimsessiontab.cpp b/indra/newview/llfloaterimsessiontab.cpp index a79b4b3f1d..76643b0235 100644 --- a/indra/newview/llfloaterimsessiontab.cpp +++ b/indra/newview/llfloaterimsessiontab.cpp @@ -82,6 +82,13 @@ LLFloaterIMSessionTab::LLFloaterIMSessionTab(const LLSD& session_id) LLFloaterIMSessionTab::~LLFloaterIMSessionTab() { delete mRefreshTimer; + + // Select Nearby Chat session + LLFloaterIMContainer* container = LLFloaterReg::getTypedInstance("im_container"); + if (container) + { + container->selectConversationPair(LLUUID(NULL), true); + } } //static -- cgit v1.2.3 From 799c1f241f66db6d8701ee8c4339a5cce41c3c47 Mon Sep 17 00:00:00 2001 From: AlexanderP ProductEngine Date: Thu, 3 Jan 2013 18:59:20 +0200 Subject: CHUI-628 FIXED Open conversation log menu option not active in conversation floater when nearby chat is selected: Determination of the availability menu item was moved to the right place --- indra/newview/llfloaterimcontainer.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'indra') diff --git a/indra/newview/llfloaterimcontainer.cpp b/indra/newview/llfloaterimcontainer.cpp index 61a67a1f9f..50acd4ae24 100644 --- a/indra/newview/llfloaterimcontainer.cpp +++ b/indra/newview/llfloaterimcontainer.cpp @@ -1101,6 +1101,11 @@ bool LLFloaterIMContainer::enableContextMenuItem(const LLSD& userdata) uuid_vec_t uuids; getParticipantUUIDs(uuids); + if ("conversation_log" == item) + { + return gSavedSettings.getBOOL("KeepConversationLogTranscripts"); + } + //Enable Chat history item for ad-hoc and group conversations if ("can_chat_history" == item) { @@ -1127,11 +1132,6 @@ bool LLFloaterIMContainer::enableContextMenuItem(const LLSD& userdata) bool LLFloaterIMContainer::enableContextMenuItem(const std::string& item, uuid_vec_t& uuids) { - if ("conversation_log" == item) - { - return gSavedSettings.getBOOL("KeepConversationLogTranscripts"); - } - // Extract the single select info bool is_single_select = (uuids.size() == 1); const LLUUID& single_id = uuids.front(); -- cgit v1.2.3 From 0e6ff3e7021b2e72f02b22550bbb96bc3674cba4 Mon Sep 17 00:00:00 2001 From: Merov Linden Date: Thu, 3 Jan 2013 14:37:24 -0800 Subject: CHUI-654 : Fixed! Select the Nearby Chat directly when one conversation only left, don't finesse with a root UUID that might not be NULL --- indra/newview/llfloaterimcontainer.cpp | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) (limited to 'indra') diff --git a/indra/newview/llfloaterimcontainer.cpp b/indra/newview/llfloaterimcontainer.cpp index 50acd4ae24..9fe67e99da 100644 --- a/indra/newview/llfloaterimcontainer.cpp +++ b/indra/newview/llfloaterimcontainer.cpp @@ -1430,11 +1430,10 @@ bool LLFloaterIMContainer::removeConversationListItem(const LLUUID& uuid, bool c { is_widget_selected = widget->isSelected(); new_selection = mConversationsRoot->getNextFromChild(widget); - if(new_selection == NULL) + if (!new_selection) { new_selection = mConversationsRoot->getPreviousFromChild(widget); } - widget->destroyView(); } @@ -1446,14 +1445,20 @@ bool LLFloaterIMContainer::removeConversationListItem(const LLUUID& uuid, bool c if (change_focus) { setFocus(TRUE); - if(new_selection != NULL) + if (new_selection) { if (mConversationsWidgets.size() == 1) - new_selection = new_selection->getParentFolder(); - LLConversationItem* vmi = dynamic_cast(new_selection->getViewModelItem()); - if(vmi != NULL) { - selectConversationPair(vmi->getUUID(), true); + // If only one widget is left, it has to be the Nearby Chat. Select it directly. + selectConversationPair(LLUUID(NULL), true); + } + else + { + LLConversationItem* vmi = dynamic_cast(new_selection->getViewModelItem()); + if (vmi) + { + selectConversationPair(vmi->getUUID(), true); + } } } } -- cgit v1.2.3 From 3d1feec7641051386733405186cfe81b68a929ca Mon Sep 17 00:00:00 2001 From: Merov Linden Date: Thu, 3 Jan 2013 15:11:53 -0800 Subject: CHUI-656 : Fixed. getTypedInstance() will create an instance if not found. Do not use that in destructors (bad...) or in places where creation is not required. Use findTypedInstance() instead. --- indra/newview/llfloaterimsessiontab.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indra') diff --git a/indra/newview/llfloaterimsessiontab.cpp b/indra/newview/llfloaterimsessiontab.cpp index 76643b0235..7b34a86f24 100644 --- a/indra/newview/llfloaterimsessiontab.cpp +++ b/indra/newview/llfloaterimsessiontab.cpp @@ -84,7 +84,7 @@ LLFloaterIMSessionTab::~LLFloaterIMSessionTab() delete mRefreshTimer; // Select Nearby Chat session - LLFloaterIMContainer* container = LLFloaterReg::getTypedInstance("im_container"); + LLFloaterIMContainer* container = LLFloaterReg::findTypedInstance("im_container"); if (container) { container->selectConversationPair(LLUUID(NULL), true); @@ -329,7 +329,7 @@ void LLFloaterIMSessionTab::onFocusReceived() LLTransientDockableFloater::onFocusReceived(); - LLFloaterIMContainer* container = LLFloaterReg::getTypedInstance("im_container"); + LLFloaterIMContainer* container = LLFloaterReg::findTypedInstance("im_container"); if (container) { container->selectConversationPair(mSessionID, true); -- cgit v1.2.3 From 9d687cc0042a6972a603778359055394c1cf0850 Mon Sep 17 00:00:00 2001 From: "maxim@mnikolenko" Date: Fri, 4 Jan 2013 15:14:24 +0200 Subject: CHUI-637 FIXED Call requestArrange() to update widget state. --- indra/newview/llfloaterimcontainer.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'indra') diff --git a/indra/newview/llfloaterimcontainer.cpp b/indra/newview/llfloaterimcontainer.cpp index 9fe67e99da..22db4dd0eb 100644 --- a/indra/newview/llfloaterimcontainer.cpp +++ b/indra/newview/llfloaterimcontainer.cpp @@ -678,6 +678,7 @@ void LLFloaterIMContainer::collapseConversationsPane(bool collapse) { widget->setOpen(false); } + widget->requestArrange(); } } } -- cgit v1.2.3