summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/llui/llmenugl.cpp2
-rw-r--r--indra/newview/llagent.cpp5
-rw-r--r--indra/newview/llagent.h1
-rw-r--r--indra/newview/llavatarlist.cpp7
-rw-r--r--indra/newview/llavatarlistitem.cpp192
-rw-r--r--indra/newview/llavatarlistitem.h66
-rw-r--r--indra/newview/llbottomtray.cpp14
-rw-r--r--indra/newview/llfloaterchat.cpp6
-rw-r--r--indra/newview/llfloatergroups.cpp9
-rw-r--r--indra/newview/llgroupactions.cpp6
-rw-r--r--indra/newview/llimfloater.cpp10
-rw-r--r--indra/newview/llimfloater.h1
-rw-r--r--indra/newview/llimview.cpp19
-rw-r--r--indra/newview/llimview.h5
-rw-r--r--indra/newview/llinspectavatar.cpp1
-rw-r--r--indra/newview/llpanelavatar.cpp18
-rw-r--r--indra/newview/llpanelgroup.cpp18
-rw-r--r--indra/newview/llpanelgroupgeneral.cpp11
-rw-r--r--indra/newview/llpanelpeople.cpp8
-rw-r--r--indra/newview/llpanelplaces.h4
-rw-r--r--indra/newview/llpanelteleporthistory.cpp2
-rw-r--r--indra/newview/llparticipantlist.cpp8
-rw-r--r--indra/newview/llscreenchannel.cpp14
-rw-r--r--indra/newview/llscreenchannel.h2
-rw-r--r--indra/newview/llspeakers.cpp5
-rw-r--r--indra/newview/llspeakers.h2
-rw-r--r--indra/newview/llsyswellwindow.cpp4
-rw-r--r--indra/newview/llsyswellwindow.h3
-rw-r--r--indra/newview/llteleporthistorystorage.cpp7
-rw-r--r--indra/newview/lltoastnotifypanel.cpp4
-rw-r--r--indra/newview/llviewermessage.cpp56
-rw-r--r--indra/newview/skins/default/xui/en/notifications.xml10
-rw-r--r--indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml17
-rw-r--r--indra/newview/skins/default/xui/en/panel_avatar_list_item.xml7
-rw-r--r--indra/newview/skins/default/xui/en/panel_bottomtray.xml39
-rw-r--r--indra/newview/skins/default/xui/en/panel_edit_profile.xml3
-rw-r--r--indra/newview/skins/default/xui/en/panel_group_control_panel.xml20
-rw-r--r--indra/newview/skins/default/xui/en/panel_group_list_item.xml1
-rw-r--r--indra/newview/skins/default/xui/en/panel_my_profile.xml17
-rw-r--r--indra/newview/skins/default/xui/en/panel_nearby_chat_bar.xml4
-rw-r--r--indra/newview/skins/default/xui/en/panel_profile.xml17
41 files changed, 408 insertions, 237 deletions
diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp
index bd67949c2a..21f3f15739 100644
--- a/indra/llui/llmenugl.cpp
+++ b/indra/llui/llmenugl.cpp
@@ -2966,7 +2966,7 @@ void LLMenuGL::showPopup(LLView* spawning_view, LLMenuGL* menu, S32 x, S32 y)
LLUI::getMousePositionLocal(menu->getParent(), &mouse_x, &mouse_y);
LLMenuHolderGL::sContextMenuSpawnPos.set(mouse_x,mouse_y);
- const LLRect menu_region_rect = LLMenuGL::sMenuContainer->getMenuRect();
+ const LLRect menu_region_rect = LLMenuGL::sMenuContainer->getRect();
const S32 HPAD = 2;
LLRect rect = menu->getRect();
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp
index 5e2e374df6..35b28d8ec0 100644
--- a/indra/newview/llagent.cpp
+++ b/indra/newview/llagent.cpp
@@ -5157,6 +5157,11 @@ BOOL LLAgent::setUserGroupFlags(const LLUUID& group_id, BOOL accept_notices, BOO
return FALSE;
}
+BOOL LLAgent::canJoinGroups() const
+{
+ return mGroups.count() < MAX_AGENT_GROUPS;
+}
+
LLQuaternion LLAgent::getHeadRotation()
{
if (mAvatarObject.isNull() || !mAvatarObject->mPelvisp || !mAvatarObject->mHeadp)
diff --git a/indra/newview/llagent.h b/indra/newview/llagent.h
index 2e95dc72be..beede7fbe3 100644
--- a/indra/newview/llagent.h
+++ b/indra/newview/llagent.h
@@ -972,6 +972,7 @@ public:
BOOL setGroupContribution(const LLUUID& group_id, S32 contribution);
BOOL setUserGroupFlags(const LLUUID& group_id, BOOL accept_notices, BOOL list_in_profile);
const std::string &getGroupName() const { return mGroupName; }
+ BOOL canJoinGroups() const;
private:
std::string mGroupName;
LLUUID mGroupID;
diff --git a/indra/newview/llavatarlist.cpp b/indra/newview/llavatarlist.cpp
index 5df73a994e..19e9e52ddf 100644
--- a/indra/newview/llavatarlist.cpp
+++ b/indra/newview/llavatarlist.cpp
@@ -82,7 +82,7 @@ void LLAvatarList::setSpeakingIndicatorsVisible(bool visible)
getItems(items);
for( std::vector<LLPanel*>::const_iterator it = items.begin(); it != items.end(); it++)
{
- static_cast<LLAvatarListItem*>(*it)->setSpeakingIndicatorVisible(mShowSpeakingIndicator);
+ static_cast<LLAvatarListItem*>(*it)->showSpeakingIndicator(mShowSpeakingIndicator);
}
}
@@ -323,18 +323,15 @@ boost::signals2::connection LLAvatarList::setRefreshCompleteCallback(const commi
void LLAvatarList::addNewItem(const LLUUID& id, const std::string& name, BOOL is_online, EAddPosition pos)
{
LLAvatarListItem* item = new LLAvatarListItem();
- item->showInfoBtn(true);
- item->showSpeakingIndicator(true);
item->setName(name);
item->setAvatarId(id, mIgnoreOnlineStatus);
item->setOnline(mIgnoreOnlineStatus ? true : is_online);
item->showLastInteractionTime(mShowLastInteractionTime);
- item->childSetVisible("info_btn", false);
item->setAvatarIconVisible(mShowIcons);
item->setShowInfoBtn(mShowInfoBtn);
item->setShowProfileBtn(mShowProfileBtn);
- item->setSpeakingIndicatorVisible(mShowSpeakingIndicator);
+ item->showSpeakingIndicator(mShowSpeakingIndicator);
addItem(item, id, pos);
}
diff --git a/indra/newview/llavatarlistitem.cpp b/indra/newview/llavatarlistitem.cpp
index 6945ac6932..a2e17db3d8 100644
--- a/indra/newview/llavatarlistitem.cpp
+++ b/indra/newview/llavatarlistitem.cpp
@@ -44,10 +44,10 @@
#include "llbutton.h"
bool LLAvatarListItem::sStaticInitialized = false;
-S32 LLAvatarListItem::sIconWidth = 0;
-S32 LLAvatarListItem::sInfoBtnWidth = 0;
-S32 LLAvatarListItem::sProfileBtnWidth = 0;
-S32 LLAvatarListItem::sSpeakingIndicatorWidth = 0;
+S32 LLAvatarListItem::sLeftPadding = 0;
+S32 LLAvatarListItem::sRightNamePadding = 0;
+S32 LLAvatarListItem::sChildrenWidths[LLAvatarListItem::ALIC_COUNT];
+
LLAvatarListItem::LLAvatarListItem(bool not_from_ui_factory/* = true*/)
: LLPanel(),
@@ -95,10 +95,7 @@ BOOL LLAvatarListItem::postBuild()
// so that we can hide and show the icon again later.
if (!sStaticInitialized)
{
- sIconWidth = mAvatarName->getRect().mLeft - mAvatarIcon->getRect().mLeft;
- sInfoBtnWidth = mInfoBtn->getRect().mRight - mSpeakingIndicator->getRect().mRight;
- sProfileBtnWidth = mProfileBtn->getRect().mRight - mInfoBtn->getRect().mRight;
- sSpeakingIndicatorWidth = mSpeakingIndicator->getRect().mRight - mAvatarName->getRect().mRight;
+ initChildrenWidths(this);
sStaticInitialized = true;
}
@@ -137,6 +134,8 @@ void LLAvatarListItem::onMouseEnter(S32 x, S32 y, MASK mask)
mProfileBtn->setVisible(mShowProfileBtn);
LLPanel::onMouseEnter(x, y, mask);
+
+ updateChildren();
}
void LLAvatarListItem::onMouseLeave(S32 x, S32 y, MASK mask)
@@ -146,6 +145,8 @@ void LLAvatarListItem::onMouseLeave(S32 x, S32 y, MASK mask)
mProfileBtn->setVisible(false);
LLPanel::onMouseLeave(x, y, mask);
+
+ updateChildren();
}
// virtual, called by LLAvatarTracker
@@ -215,12 +216,8 @@ void LLAvatarListItem::showLastInteractionTime(bool show)
if (show)
return;
- LLRect name_rect = mAvatarName->getRect();
- LLRect time_rect = mLastInteractionTime->getRect();
-
mLastInteractionTime->setVisible(false);
- name_rect.mRight += (time_rect.mRight - name_rect.mRight);
- mAvatarName->setRect(name_rect);
+ updateChildren();
}
void LLAvatarListItem::setLastInteractionTime(U32 secs_since)
@@ -234,12 +231,6 @@ void LLAvatarListItem::setShowInfoBtn(bool show)
if(mShowInfoBtn == show)
return;
mShowInfoBtn = show;
- S32 width_delta = show ? - sInfoBtnWidth : sInfoBtnWidth;
-
- //Translating speaking indicator
- mSpeakingIndicator->translate(width_delta, 0);
- //Reshaping avatar name
- mAvatarName->reshape(mAvatarName->getRect().getWidth() + width_delta, mAvatarName->getRect().getHeight());
}
void LLAvatarListItem::setShowProfileBtn(bool show)
@@ -248,24 +239,15 @@ void LLAvatarListItem::setShowProfileBtn(bool show)
if(mShowProfileBtn == show)
return;
mShowProfileBtn = show;
- S32 width_delta = show ? - sProfileBtnWidth : sProfileBtnWidth;
-
- //Translating speaking indicator
- mSpeakingIndicator->translate(width_delta, 0);
- //Reshaping avatar name
- mAvatarName->reshape(mAvatarName->getRect().getWidth() + width_delta, mAvatarName->getRect().getHeight());
}
-void LLAvatarListItem::setSpeakingIndicatorVisible(bool visible)
+void LLAvatarListItem::showSpeakingIndicator(bool visible)
{
// Already done? Then do nothing.
if (mSpeakingIndicator->getVisible() == (BOOL)visible)
return;
mSpeakingIndicator->setVisible(visible);
- S32 width_delta = visible ? - sSpeakingIndicatorWidth : sSpeakingIndicatorWidth;
-
- //Reshaping avatar name
- mAvatarName->reshape(mAvatarName->getRect().getWidth() + width_delta, mAvatarName->getRect().getHeight());
+ updateChildren();
}
void LLAvatarListItem::setAvatarIconVisible(bool visible)
@@ -276,11 +258,7 @@ void LLAvatarListItem::setAvatarIconVisible(bool visible)
// Show/hide avatar icon.
mAvatarIcon->setVisible(visible);
-
- // Move the avatar name horizontally by icon size + its distance from the avatar name.
- LLRect name_rect = mAvatarName->getRect();
- name_rect.mLeft += visible ? sIconWidth : -sIconWidth;
- mAvatarName->setRect(name_rect);
+ updateChildren();
}
void LLAvatarListItem::onInfoBtnClick()
@@ -344,21 +322,6 @@ void LLAvatarListItem::onNameCache(const std::string& first_name, const std::str
setName(name);
}
-void LLAvatarListItem::reshapeAvatarName()
-{
- S32 width_delta = 0;
- width_delta += mShowProfileBtn ? sProfileBtnWidth : 0;
- width_delta += mSpeakingIndicator->getVisible() ? sSpeakingIndicatorWidth : 0;
- width_delta += mAvatarIcon->getVisible() ? sIconWidth : 0;
- width_delta += mShowInfoBtn ? sInfoBtnWidth : 0;
- width_delta += mLastInteractionTime->getVisible() ? mLastInteractionTime->getRect().getWidth() : 0;
-
- S32 height = mAvatarName->getRect().getHeight();
- S32 width = getRect().getWidth() - width_delta;
-
- mAvatarName->reshape(width, height);
-}
-
// Convert given number of seconds to a string like "23 minutes", "15 hours" or "3 years",
// taking i18n into account. The format string to use is taken from the panel XML.
std::string LLAvatarListItem::formatSeconds(U32 secs)
@@ -492,4 +455,133 @@ LLAvatarListItem::icon_color_map_t& LLAvatarListItem::getItemIconColorMap()
return item_icon_color_map;
}
+// static
+void LLAvatarListItem::initChildrenWidths(LLAvatarListItem* avatar_item)
+{
+ //profile btn width + padding
+ S32 profile_btn_width = avatar_item->getRect().getWidth() - avatar_item->mProfileBtn->getRect().mLeft;
+
+ //info btn width + padding
+ S32 info_btn_width = avatar_item->mProfileBtn->getRect().mLeft - avatar_item->mInfoBtn->getRect().mLeft;
+
+ //speaking indicator width + padding
+ S32 speaking_indicator_width = avatar_item->mInfoBtn->getRect().mLeft - avatar_item->mSpeakingIndicator->getRect().mLeft;
+
+ // last interaction time textbox width + padding
+ S32 last_interaction_time_width = avatar_item->mSpeakingIndicator->getRect().mLeft - avatar_item->mLastInteractionTime->getRect().mLeft;
+
+ // icon width + padding
+ S32 icon_width = avatar_item->mAvatarName->getRect().mLeft - avatar_item->mAvatarIcon->getRect().mLeft;
+
+ sLeftPadding = avatar_item->mAvatarIcon->getRect().mLeft;
+ sRightNamePadding = avatar_item->mLastInteractionTime->getRect().mLeft - avatar_item->mAvatarName->getRect().mRight;
+
+ S32 index = ALIC_COUNT;
+ sChildrenWidths[--index] = icon_width;
+ sChildrenWidths[--index] = 0; // for avatar name we don't need its width, it will be calculated as "left available space"
+ sChildrenWidths[--index] = last_interaction_time_width;
+ sChildrenWidths[--index] = speaking_indicator_width;
+ sChildrenWidths[--index] = info_btn_width;
+ sChildrenWidths[--index] = profile_btn_width;
+}
+
+void LLAvatarListItem::updateChildren()
+{
+ LL_DEBUGS("AvatarItemReshape") << LL_ENDL;
+ LL_DEBUGS("AvatarItemReshape") << "Updating for: " << getAvatarName() << LL_ENDL;
+
+ S32 name_new_width = getRect().getWidth();
+ S32 ctrl_new_left = name_new_width;
+ S32 name_new_left = sLeftPadding;
+
+ // iterate through all children and set them into correct position depend on each child visibility
+ // assume that child indexes are in back order: the first in Enum is the last (right) in the item
+ // iterate & set child views starting from right to left
+ for (S32 i = 0; i < ALIC_COUNT; ++i)
+ {
+ // skip "name" textbox, it will be processed out of loop later
+ if (ALIC_NAME == i) continue;
+
+ LLView* control = getItemChildView((EAvatarListItemChildIndex)i);
+
+ LL_DEBUGS("AvatarItemReshape") << "Processing control: " << control->getName() << LL_ENDL;
+ // skip invisible views
+ if (!control->getVisible()) continue;
+
+ S32 ctrl_width = sChildrenWidths[i]; // including space between current & left controls
+
+ // decrease available for
+ name_new_width -= ctrl_width;
+ LL_DEBUGS("AvatarItemReshape") << "width: " << ctrl_width << ", name_new_width: " << name_new_width << LL_ENDL;
+
+ LLRect control_rect = control->getRect();
+ LL_DEBUGS("AvatarItemReshape") << "rect before: " << control_rect << LL_ENDL;
+
+ if (ALIC_ICON == i)
+ {
+ // assume that this is the last iteration,
+ // so it is not necessary to save "ctrl_new_left" value calculated on previous iterations
+ ctrl_new_left = sLeftPadding;
+ name_new_left = ctrl_new_left + ctrl_width;
+ }
+ else
+ {
+ ctrl_new_left -= ctrl_width;
+ }
+
+ LL_DEBUGS("AvatarItemReshape") << "ctrl_new_left: " << ctrl_new_left << LL_ENDL;
+
+ control_rect.setLeftTopAndSize(
+ ctrl_new_left,
+ control_rect.mTop,
+ control_rect.getWidth(),
+ control_rect.getHeight());
+
+ LL_DEBUGS("AvatarItemReshape") << "rect after: " << control_rect << LL_ENDL;
+ control->setShape(control_rect);
+ }
+
+ // set size and position of the "name" child
+ LLView* name_view = getItemChildView(ALIC_NAME);
+ LLRect name_view_rect = name_view->getRect();
+ LL_DEBUGS("AvatarItemReshape") << "name rect before: " << name_view_rect << LL_ENDL;
+
+ // apply paddings
+ name_new_width -= sLeftPadding;
+ name_new_width -= sRightNamePadding;
+
+ name_view_rect.setLeftTopAndSize(
+ name_new_left,
+ name_view_rect.mTop,
+ name_new_width,
+ name_view_rect.getHeight());
+
+ name_view->setShape(name_view_rect);
+
+ LL_DEBUGS("AvatarItemReshape") << "name rect after: " << name_view_rect << LL_ENDL;
+}
+
+LLView* LLAvatarListItem::getItemChildView(EAvatarListItemChildIndex child_view_index)
+{
+ LLView* child_view = mAvatarName;
+ if (child_view_index < 0 || ALIC_COUNT <= child_view_index)
+ {
+ LL_WARNS("AvatarItemReshape") << "Child view index is out of range: " << child_view_index << LL_ENDL;
+ return child_view;
+ }
+ switch (child_view_index)
+ {
+ case ALIC_ICON: child_view = mAvatarIcon; break;
+ case ALIC_NAME: child_view = mAvatarName; break;
+ case ALIC_INTERACTION_TIME: child_view = mLastInteractionTime; break;
+ case ALIC_SPEAKER_INDICATOR: child_view = mSpeakingIndicator; break;
+ case ALIC_INFO_BUTTON: child_view = mInfoBtn; break;
+ case ALIC_PROFILE_BUTTON: child_view = mProfileBtn; break;
+ default:
+ LL_WARNS("AvatarItemReshape") << "Unexpected child view index is passed: " << child_view_index << LL_ENDL;
+ }
+
+ return child_view;
+}
+
// EOF
diff --git a/indra/newview/llavatarlistitem.h b/indra/newview/llavatarlistitem.h
index 96097bc9b5..868ee546d4 100644
--- a/indra/newview/llavatarlistitem.h
+++ b/indra/newview/llavatarlistitem.h
@@ -88,7 +88,8 @@ public:
//Show/hide profile/info btn, translating speaker indicator and avatar name coordinates accordingly
void setShowProfileBtn(bool show);
void setShowInfoBtn(bool show);
- void setSpeakingIndicatorVisible(bool visible);
+ void showSpeakingIndicator(bool show);
+ void showLastInteractionTime(bool show);
void setAvatarIconVisible(bool visible);
const LLUUID& getAvatarId() const;
@@ -97,17 +98,6 @@ public:
void onInfoBtnClick();
void onProfileBtnClick();
- void showSpeakingIndicator(bool show) { mSpeakingIndicator->setVisible(show); }
- void showInfoBtn(bool show_info_btn) {mInfoBtn->setVisible(show_info_btn); }
- void showLastInteractionTime(bool show);
-
- /**
- * This method was added to fix EXT-2364 (Items in group/ad-hoc IM participant list (avatar names) should be reshaped when adding/removing the "(Moderator)" label)
- * But this is a *HACK. The real reason of it was in incorrect logic while hiding profile/info/speaker buttons
- * *TODO: new reshape method should be provided in lieu of this one to be called when visibility if those buttons is changed
- */
- void reshapeAvatarName();
-
protected:
/**
* Contains indicator to show voice activity.
@@ -124,6 +114,23 @@ private:
E_UNKNOWN,
} EOnlineStatus;
+ /**
+ * Enumeration of item elements in order from right to left.
+ *
+ * updateChildren() assumes that indexes are in the such order to process avatar icon easier.
+ *
+ * @see updateChildren()
+ */
+ typedef enum e_avatar_item_child {
+ ALIC_PROFILE_BUTTON,
+ ALIC_INFO_BUTTON,
+ ALIC_SPEAKER_INDICATOR,
+ ALIC_INTERACTION_TIME,
+ ALIC_NAME,
+ ALIC_ICON,
+ ALIC_COUNT,
+ } EAvatarListItemChildIndex;
+
void setNameInternal(const std::string& name, const std::string& highlight);
void onNameCache(const std::string& first_name, const std::string& last_name);
@@ -135,6 +142,26 @@ private:
typedef std::map<EItemState, LLColor4> icon_color_map_t;
static icon_color_map_t& getItemIconColorMap();
+ /**
+ * Initializes widths of all children to use them while changing visibility of any of them.
+ *
+ * @see updateChildren()
+ */
+ static void initChildrenWidths(LLAvatarListItem* self);
+
+ /**
+ * Updates position and rectangle of visible children to fit all available item's width.
+ */
+ void updateChildren();
+
+ /**
+ * Gets child view specified by index.
+ *
+ * This method implemented via switch by all EAvatarListItemChildIndex values.
+ * It is used to not store children in array or vector to avoid of increasing memory usage.
+ */
+ LLView* getItemChildView(EAvatarListItemChildIndex child_index);
+
LLTextBox* mAvatarName;
LLTextBox* mLastInteractionTime;
LLStyle::Params mAvatarNameStyle;
@@ -151,10 +178,17 @@ private:
bool mShowProfileBtn;
static bool sStaticInitialized; // this variable is introduced to improve code readability
- static S32 sIconWidth; // icon width + padding
- static S32 sInfoBtnWidth; //info btn width + padding
- static S32 sProfileBtnWidth; //profile btn width + padding
- static S32 sSpeakingIndicatorWidth; //speaking indicator width + padding
+ static S32 sLeftPadding; // padding to first left visible child (icon or name)
+ static S32 sRightNamePadding; // right padding from name to next visible child
+
+ /**
+ * Contains widths of each child specified by EAvatarListItemChildIndex
+ * including padding to the next right one.
+ *
+ * @see initChildrenWidths()
+ */
+ static S32 sChildrenWidths[ALIC_COUNT];
+
};
#endif //LL_LLAVATARLISTITEM_H
diff --git a/indra/newview/llbottomtray.cpp b/indra/newview/llbottomtray.cpp
index 976b312509..8c90fffa0a 100644
--- a/indra/newview/llbottomtray.cpp
+++ b/indra/newview/llbottomtray.cpp
@@ -251,14 +251,24 @@ void LLBottomTray::setVisible(BOOL visible)
{
LLView* viewp = *child_it;
std::string name = viewp->getName();
-
- if ("chat_bar" == name || "movement_panel" == name || "cam_panel" == name || "snapshot_panel" == name || "gesture_panel" == name)
+
+ // Chat bar is always shown. But the move, camera, gesture and snapshot buttons shouldn't be displayed when we are in mouselook mode. See EXT-3988.
+ if ("chat_bar" == name || (visibility && ("movement_panel" == name || "cam_panel" == name || "snapshot_panel" == name || "gesture_panel" == name)))
continue;
else
{
viewp->setVisible(visibility);
}
}
+
+ // Apply the saved settings when we are not in mouselook mode, see EXT-3988.
+ if (visibility)
+ {
+ showCameraButton(gSavedSettings.getBOOL("ShowCameraButton"));
+ showSnapshotButton(gSavedSettings.getBOOL("ShowSnapshotButton"));
+ showMoveButton(gSavedSettings.getBOOL("ShowMoveButton"));
+ showGestureButton(gSavedSettings.getBOOL("ShowGestureButton"));
+ }
}
}
diff --git a/indra/newview/llfloaterchat.cpp b/indra/newview/llfloaterchat.cpp
index b9e0f928f1..8f91424f59 100644
--- a/indra/newview/llfloaterchat.cpp
+++ b/indra/newview/llfloaterchat.cpp
@@ -311,8 +311,10 @@ void LLFloaterChat::addChat(const LLChat& chat, BOOL from_instant_message, BOOL
triggerAlerts(chat.mText);
// Add the sender to the list of people with which we've recently interacted.
- if(chat.mSourceType == CHAT_SOURCE_AGENT && chat.mFromID.notNull())
- LLRecentPeople::instance().add(chat.mFromID);
+ // this is not the best place to add _all_ messages to recent list
+ // comment this for now, may remove later on code cleanup
+ //if(chat.mSourceType == CHAT_SOURCE_AGENT && chat.mFromID.notNull())
+ // LLRecentPeople::instance().add(chat.mFromID);
bool add_chat = true;
bool log_chat = true;
diff --git a/indra/newview/llfloatergroups.cpp b/indra/newview/llfloatergroups.cpp
index 7cb925bc0b..29f415bd43 100644
--- a/indra/newview/llfloatergroups.cpp
+++ b/indra/newview/llfloatergroups.cpp
@@ -247,14 +247,7 @@ void LLPanelGroups::enableButtons()
childDisable("IM");
childDisable("Leave");
}
- if(gAgent.mGroups.count() < MAX_AGENT_GROUPS)
- {
- childEnable("Create");
- }
- else
- {
- childDisable("Create");
- }
+ childSetEnabled("Create", gAgent.canJoinGroups());
}
diff --git a/indra/newview/llgroupactions.cpp b/indra/newview/llgroupactions.cpp
index 7dd8ea694e..a78a0a43b4 100644
--- a/indra/newview/llgroupactions.cpp
+++ b/indra/newview/llgroupactions.cpp
@@ -146,6 +146,12 @@ void LLGroupActions::startCall(const LLUUID& group_id)
// static
void LLGroupActions::join(const LLUUID& group_id)
{
+ if (!gAgent.canJoinGroups())
+ {
+ LLNotificationsUtil::add("JoinedTooManyGroups");
+ return;
+ }
+
LLGroupMgrGroupData* gdatap =
LLGroupMgr::getInstance()->getGroupData(group_id);
diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp
index b05568f353..02eb29eedd 100644
--- a/indra/newview/llimfloater.cpp
+++ b/indra/newview/llimfloater.cpp
@@ -484,16 +484,6 @@ void LLIMFloater::setDocked(bool docked, bool pop_on_undock)
}
}
-void LLIMFloater::setTornOff(bool torn_off)
-{
- // When IM Floater isn't torn off, "close" button should be hidden.
- // This call will just disables it, since there is a hack in LLFloater::updateButton,
- // which prevents hiding of close button in that case.
- setCanClose(torn_off);
-
- LLTransientDockableFloater::setTornOff(torn_off);
-}
-
void LLIMFloater::setVisible(BOOL visible)
{
LLNotificationsUI::LLScreenChannel* channel = dynamic_cast<LLNotificationsUI::LLScreenChannel*>
diff --git a/indra/newview/llimfloater.h b/indra/newview/llimfloater.h
index bc7a43e852..87ccad1d34 100644
--- a/indra/newview/llimfloater.h
+++ b/indra/newview/llimfloater.h
@@ -64,7 +64,6 @@ public:
// LLFloater overrides
/*virtual*/ void onClose(bool app_quitting);
/*virtual*/ void setDocked(bool docked, bool pop_on_undock = true);
- /*virtual*/ void setTornOff(bool torn_off);
// Make IM conversion visible and update the message history
static LLIMFloater* show(const LLUUID& session_id);
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp
index daabf1f717..e9661003ea 100644
--- a/indra/newview/llimview.cpp
+++ b/indra/newview/llimview.cpp
@@ -382,10 +382,6 @@ void LLIMModel::LLIMSession::addMessage(const std::string& from, const LLUUID& f
mSpeakers->speakerChatted(from_id);
mSpeakers->setSpeakerTyping(from_id, FALSE);
}
-
- if( mSessionType == P2P_SESSION ||
- mSessionType == ADHOC_SESSION)
- LLRecentPeople::instance().add(from_id);
}
void LLIMModel::LLIMSession::addMessagesFromHistory(const std::list<LLSD>& history)
@@ -684,6 +680,12 @@ bool LLIMModel::addMessage(const LLUUID& session_id, const std::string& from, co
LLIMSession* session = addMessageSilently(session_id, from, from_id, utf8_text, log2file);
if (!session) return false;
+ //good place to add some1 to recent list
+ //other places may be called from message history.
+ if( !from_id.isNull() &&
+ ( session->isP2PSessionType() || session->isAdHocSessionType() ) )
+ LLRecentPeople::instance().add(from_id);
+
// notify listeners
LLSD arg;
arg["session_id"] = session_id;
@@ -1377,7 +1379,7 @@ void LLCallDialogManager::onVoiceChannelChanged(const LLUUID &session_id)
}
sSession = session;
- sSession->mVoiceChannel->setStateChangedCallback(LLCallDialogManager::onVoiceChannelStateChanged);
+ sSession->mVoiceChannel->setStateChangedCallback(boost::bind(LLCallDialogManager::onVoiceChannelStateChanged, _1, _2, _3));
if(sCurrentSessionlName != session->mName)
{
sPreviousSessionlName = sCurrentSessionlName;
@@ -1601,7 +1603,12 @@ void LLOutgoingCallDialog::show(const LLSD& key)
if (!mPayload["disconnected_channel_name"].asString().empty())
{
- childSetTextArg("nearby", "[VOICE_CHANNEL_NAME]", mPayload["disconnected_channel_name"].asString());
+ std::string channel_name = mPayload["disconnected_channel_name"].asString();
+ if (LLIMModel::LLIMSession::AVALINE_SESSION == mPayload["session_type"].asInteger())
+ {
+ channel_name = LLTextUtil::formatPhoneNumber(channel_name);
+ }
+ childSetTextArg("nearby", "[VOICE_CHANNEL_NAME]", channel_name);
childSetTextArg("nearby_P2P", "[VOICE_CHANNEL_NAME]", mPayload["disconnected_channel_name"].asString());
}
diff --git a/indra/newview/llimview.h b/indra/newview/llimview.h
index 20d8e28392..e72bda6c2b 100644
--- a/indra/newview/llimview.h
+++ b/indra/newview/llimview.h
@@ -78,6 +78,11 @@ public:
bool isP2P();
bool isOtherParticipantAvaline();
+ bool isP2PSessionType() const { return mSessionType == P2P_SESSION;}
+ bool isAdHocSessionType() const { return mSessionType == ADHOC_SESSION;}
+ bool isGroupSessionType() const { return mSessionType == GROUP_SESSION;}
+ bool isAvalineSessionType() const { return mSessionType == AVALINE_SESSION;}
+
LLUUID mSessionID;
std::string mName;
EInstantMessage mType;
diff --git a/indra/newview/llinspectavatar.cpp b/indra/newview/llinspectavatar.cpp
index 8f4fba244d..0374a1d25b 100644
--- a/indra/newview/llinspectavatar.cpp
+++ b/indra/newview/llinspectavatar.cpp
@@ -418,6 +418,7 @@ void LLInspectAvatar::updateModeratorPanel()
LLPointer<LLSpeaker> selected_speakerp = speaker_mgr->findSpeaker(mAvatarID);
if(speaker_mgr->isVoiceActive() && selected_speakerp &&
+ selected_speakerp->isInVoiceChannel() &&
((self_speakerp && self_speakerp->mIsModerator) || gAgent.isGodlike()))
{
getChild<LLUICtrl>("enable_voice")->setVisible(selected_speakerp->mModeratorMutedVoice);
diff --git a/indra/newview/llpanelavatar.cpp b/indra/newview/llpanelavatar.cpp
index fb898f7cdf..85e95ca1d6 100644
--- a/indra/newview/llpanelavatar.cpp
+++ b/indra/newview/llpanelavatar.cpp
@@ -52,6 +52,7 @@
#include "llfloaterreg.h"
#include "llnotificationsutil.h"
#include "llvoiceclient.h"
+#include "llnamebox.h"
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Class LLDropTarget
@@ -595,7 +596,10 @@ void LLPanelAvatarProfile::processGroupProperties(const LLAvatarGroups* avatar_g
groups += ", ";
std::string group_name = LLURI::escape(it->first);
- std::string group_url="[secondlife:///app/group/" + it->second.asString() + "/about " + group_name + "]";
+ std::string group_url= it->second.notNull()
+ ? "[secondlife:///app/group/" + it->second.asString() + "/about " + group_name + "]"
+ : getString("no_group_text");
+
groups += group_url;
}
@@ -621,19 +625,15 @@ void LLPanelAvatarProfile::fillCommonData(const LLAvatarData* avatar_data)
void LLPanelAvatarProfile::fillPartnerData(const LLAvatarData* avatar_data)
{
+ LLNameBox* name_box = getChild<LLNameBox>("partner_text");
if (avatar_data->partner_id.notNull())
{
- std::string first, last;
- BOOL found = gCacheName->getName(avatar_data->partner_id, first, last);
- if (found)
- {
- childSetTextArg("partner_text", "[FIRST]", first);
- childSetTextArg("partner_text", "[LAST]", last);
- }
+ name_box->setNameID(avatar_data->partner_id, FALSE);
}
else
{
- childSetTextArg("partner_text", "[FIRST]", getString("no_partner_text"));
+ name_box->setNameID(LLUUID::null, FALSE);
+ name_box->setText(getString("no_partner_text"));
}
}
diff --git a/indra/newview/llpanelgroup.cpp b/indra/newview/llpanelgroup.cpp
index 94de17c17d..50f92ef116 100644
--- a/indra/newview/llpanelgroup.cpp
+++ b/indra/newview/llpanelgroup.cpp
@@ -423,6 +423,9 @@ void LLPanelGroup::setGroupID(const LLUUID& group_id)
getChild<LLUICtrl>("group_name")->setVisible(true);
getChild<LLUICtrl>("group_name_editor")->setVisible(false);
+
+ if(button_apply)
+ button_apply->setVisible(is_member);
}
reposButtons();
@@ -471,12 +474,17 @@ void LLPanelGroup::draw()
childEnable("btn_refresh");
}
- bool enable = false;
- std::string mesg;
- for(std::vector<LLPanelGroupTab* >::iterator it = mTabs.begin();it!=mTabs.end();++it)
- enable = enable || (*it)->needsApply(mesg);
+ LLButton* button_apply = findChild<LLButton>("btn_apply");
+
+ if(button_apply && button_apply->getVisible())
+ {
+ bool enable = false;
+ std::string mesg;
+ for(std::vector<LLPanelGroupTab* >::iterator it = mTabs.begin();it!=mTabs.end();++it)
+ enable = enable || (*it)->needsApply(mesg);
- childSetEnabled("btn_apply", enable);
+ childSetEnabled("btn_apply", enable);
+ }
}
void LLPanelGroup::refreshData()
diff --git a/indra/newview/llpanelgroupgeneral.cpp b/indra/newview/llpanelgroupgeneral.cpp
index 31dfdde887..21b253223f 100644
--- a/indra/newview/llpanelgroupgeneral.cpp
+++ b/indra/newview/llpanelgroupgeneral.cpp
@@ -580,7 +580,6 @@ void LLPanelGroupGeneral::update(LLGroupChange gc)
}
}
- mComboActiveTitle->resetDirty();
}
// If this was just a titles update, we are done.
@@ -595,8 +594,6 @@ void LLPanelGroupGeneral::update(LLGroupChange gc)
{
mCtrlShowInGroupList->set(gdatap->mShowInList);
mCtrlShowInGroupList->setEnabled(mAllowEdit && can_change_ident);
- mCtrlShowInGroupList->resetDirty();
-
}
if (mComboMature)
{
@@ -610,19 +607,16 @@ void LLPanelGroupGeneral::update(LLGroupChange gc)
}
mComboMature->setEnabled(mAllowEdit && can_change_ident);
mComboMature->setVisible( !gAgent.isTeen() );
- mComboMature->resetDirty();
}
if (mCtrlOpenEnrollment)
{
mCtrlOpenEnrollment->set(gdatap->mOpenEnrollment);
mCtrlOpenEnrollment->setEnabled(mAllowEdit && can_change_member_opts);
- mCtrlOpenEnrollment->resetDirty();
}
if (mCtrlEnrollmentFee)
{
mCtrlEnrollmentFee->set(gdatap->mMembershipFee > 0);
mCtrlEnrollmentFee->setEnabled(mAllowEdit && can_change_member_opts);
- mCtrlEnrollmentFee->resetDirty();
}
if (mSpinEnrollmentFee)
@@ -632,7 +626,6 @@ void LLPanelGroupGeneral::update(LLGroupChange gc)
mSpinEnrollmentFee->setEnabled( mAllowEdit &&
(fee > 0) &&
can_change_member_opts);
- mSpinEnrollmentFee->resetDirty();
}
if (mCtrlReceiveNotices)
{
@@ -641,7 +634,6 @@ void LLPanelGroupGeneral::update(LLGroupChange gc)
{
mCtrlReceiveNotices->setEnabled(mAllowEdit);
}
- mCtrlReceiveNotices->resetDirty();
}
@@ -665,7 +657,6 @@ void LLPanelGroupGeneral::update(LLGroupChange gc)
if (mEditCharter)
{
mEditCharter->setText(gdatap->mCharter);
- mEditCharter->resetDirty();
}
if (mListVisibleMembers)
@@ -693,6 +684,8 @@ void LLPanelGroupGeneral::update(LLGroupChange gc)
mListVisibleMembers->addElement(row);
}
}
+
+ resetDirty();
}
void LLPanelGroupGeneral::updateMembers()
diff --git a/indra/newview/llpanelpeople.cpp b/indra/newview/llpanelpeople.cpp
index e14a5778ad..03cc870a59 100644
--- a/indra/newview/llpanelpeople.cpp
+++ b/indra/newview/llpanelpeople.cpp
@@ -35,6 +35,7 @@
// libs
#include "llfloaterreg.h"
#include "llmenugl.h"
+#include "llnotificationsutil.h"
#include "llfiltereditor.h"
#include "lltabcontainer.h"
#include "lluictrlfactory.h"
@@ -750,7 +751,6 @@ void LLPanelPeople::updateButtons()
LLPanel* groups_panel = mTabContainer->getCurrentPanel();
groups_panel->childSetEnabled("activate_btn", item_selected && !cur_group_active); // "none" or a non-active group selected
- groups_panel->childSetEnabled("plus_btn", item_selected);
groups_panel->childSetEnabled("minus_btn", item_selected && selected_id.notNull());
}
else
@@ -1138,6 +1138,12 @@ void LLPanelPeople::onAvatarPicked(
void LLPanelPeople::onGroupPlusButtonClicked()
{
+ if (!gAgent.canJoinGroups())
+ {
+ LLNotificationsUtil::add("JoinedTooManyGroups");
+ return;
+ }
+
LLMenuGL* plus_menu = (LLMenuGL*)mGroupPlusMenuHandle.get();
if (!plus_menu)
return;
diff --git a/indra/newview/llpanelplaces.h b/indra/newview/llpanelplaces.h
index 5ee8704992..b134cf0cba 100644
--- a/indra/newview/llpanelplaces.h
+++ b/indra/newview/llpanelplaces.h
@@ -71,6 +71,10 @@ public:
void setItem(LLInventoryItem* item);
+ LLInventoryItem* getItem() { return mItem; }
+
+ std::string getPlaceInfoType() { return mPlaceInfoType; }
+
private:
void onLandmarkLoaded(LLLandmark* landmark);
void onFilterEdit(const std::string& search_string, bool force_filter);
diff --git a/indra/newview/llpanelteleporthistory.cpp b/indra/newview/llpanelteleporthistory.cpp
index 65a3d9d41b..0a2217fc51 100644
--- a/indra/newview/llpanelteleporthistory.cpp
+++ b/indra/newview/llpanelteleporthistory.cpp
@@ -550,7 +550,7 @@ void LLTeleportHistoryPanel::updateVerbs()
LLTeleportHistoryFlatItem* itemp = dynamic_cast<LLTeleportHistoryFlatItem *> (mLastSelectedFlatlList->getSelectedItem());
- mTeleportBtn->setEnabled(NULL != itemp && itemp->getIndex() < (S32)mTeleportHistory->getItems().size() - 1);
+ mTeleportBtn->setEnabled(NULL != itemp);
mShowOnMapBtn->setEnabled(NULL != itemp);
}
diff --git a/indra/newview/llparticipantlist.cpp b/indra/newview/llparticipantlist.cpp
index e2da4c4475..b6f78d08f1 100644
--- a/indra/newview/llparticipantlist.cpp
+++ b/indra/newview/llparticipantlist.cpp
@@ -166,7 +166,6 @@ void LLParticipantList::onAvatarListRefreshed(LLUICtrl* ctrl, const LLSD& param)
{
name.erase(found, moderator_indicator_len);
item->setName(name);
- item->reshapeAvatarName();
}
}
}
@@ -188,7 +187,6 @@ void LLParticipantList::onAvatarListRefreshed(LLUICtrl* ctrl, const LLSD& param)
name += " ";
name += moderator_indicator;
item->setName(name);
- item->reshapeAvatarName();
}
}
}
@@ -279,6 +277,9 @@ bool LLParticipantList::onModeratorUpdateEvent(LLPointer<LLOldEvents::LLEvent> e
mModeratorList.erase(id);
}
}
+
+ // apply changes immediately
+ onAvatarListRefreshed(mAvatarList, LLSD());
}
}
return true;
@@ -592,8 +593,7 @@ bool LLParticipantList::LLParticipantListMenu::enableContextMenuItem(const LLSD&
if (speakerp.notNull())
{
// not in voice participants can not be moderated
- return speakerp->mStatus == LLSpeaker::STATUS_VOICE_ACTIVE
- || speakerp->mStatus == LLSpeaker::STATUS_MUTED;
+ return speakerp->isInVoiceChannel();
}
}
return false;
diff --git a/indra/newview/llscreenchannel.cpp b/indra/newview/llscreenchannel.cpp
index da3f1543dd..d0b537cdfc 100644
--- a/indra/newview/llscreenchannel.cpp
+++ b/indra/newview/llscreenchannel.cpp
@@ -357,7 +357,6 @@ void LLScreenChannel::loadStoredToastByNotificationIDToChannel(LLUUID id)
toast->setIsHidden(false);
toast->resetTimer();
mToastList.push_back((*it));
- mStoredToastList.erase(it);
redrawToasts();
}
@@ -779,6 +778,19 @@ void LLScreenChannel::hideToastsFromScreen()
}
//--------------------------------------------------------------------------
+void LLScreenChannel::hideToast(const LLUUID& notification_id)
+{
+ std::vector<ToastElem>::iterator it = find(mToastList.begin(), mToastList.end(), notification_id);
+ if(mToastList.end() != it)
+ {
+ ToastElem te = *it;
+ te.toast->setVisible(FALSE);
+ te.toast->stopTimer();
+ mToastList.erase(it);
+ }
+}
+
+//--------------------------------------------------------------------------
void LLScreenChannel::removeToastsFromChannel()
{
hideToastsFromScreen();
diff --git a/indra/newview/llscreenchannel.h b/indra/newview/llscreenchannel.h
index 38f27f756b..661b9e4e60 100644
--- a/indra/newview/llscreenchannel.h
+++ b/indra/newview/llscreenchannel.h
@@ -176,6 +176,8 @@ public:
void modifyToastByNotificationID(LLUUID id, LLPanel* panel);
// hide all toasts from screen, but not remove them from a channel
void hideToastsFromScreen();
+ // hide toast by notification id
+ void hideToast(const LLUUID& notification_id);
// removes all toasts from a channel
void removeToastsFromChannel();
// show all toasts in a channel
diff --git a/indra/newview/llspeakers.cpp b/indra/newview/llspeakers.cpp
index 010dfd1b33..0dd9203c6d 100644
--- a/indra/newview/llspeakers.cpp
+++ b/indra/newview/llspeakers.cpp
@@ -88,6 +88,11 @@ void LLSpeaker::onAvatarNameLookup(const LLUUID& id, const std::string& first, c
mDisplayName = first + " " + last;
}
+bool LLSpeaker::isInVoiceChannel()
+{
+ return mStatus == LLSpeaker::STATUS_VOICE_ACTIVE || mStatus == LLSpeaker::STATUS_MUTED;
+}
+
LLSpeakerUpdateModeratorEvent::LLSpeakerUpdateModeratorEvent(LLSpeaker* source)
: LLEvent(source, "Speaker add moderator event"),
mSpeakerID (source->mID),
diff --git a/indra/newview/llspeakers.h b/indra/newview/llspeakers.h
index 1a8c23f56a..da8dfdf548 100644
--- a/indra/newview/llspeakers.h
+++ b/indra/newview/llspeakers.h
@@ -67,6 +67,8 @@ public:
void onAvatarNameLookup(const LLUUID& id, const std::string& first, const std::string& last, BOOL is_group);
+ bool isInVoiceChannel();
+
ESpeakerStatus mStatus; // current activity status in speech group
F32 mLastSpokeTime; // timestamp when this speaker last spoke
F32 mSpeechVolume; // current speech amplitude (timea average rms amplitude?)
diff --git a/indra/newview/llsyswellwindow.cpp b/indra/newview/llsyswellwindow.cpp
index 44cf82540a..b5884e8364 100644
--- a/indra/newview/llsyswellwindow.cpp
+++ b/indra/newview/llsyswellwindow.cpp
@@ -701,7 +701,11 @@ void LLNotificationWellWindow::onItemClick(LLSysWellItem* item)
{
LLUUID id = item->getID();
if(mChannel)
+ {
+ mChannel->hideToast(mLoadedToastId);
mChannel->loadStoredToastByNotificationIDToChannel(id);
+ mLoadedToastId = id;
+ }
}
void LLNotificationWellWindow::onItemClose(LLSysWellItem* item)
diff --git a/indra/newview/llsyswellwindow.h b/indra/newview/llsyswellwindow.h
index ded3abcbf4..0c81d1f369 100644
--- a/indra/newview/llsyswellwindow.h
+++ b/indra/newview/llsyswellwindow.h
@@ -162,6 +162,9 @@ private:
void onItemClick(LLSysWellItem* item);
void onItemClose(LLSysWellItem* item);
+ // ID of a toast loaded by user (by clicking notification well item)
+ LLUUID mLoadedToastId;
+
};
/**
diff --git a/indra/newview/llteleporthistorystorage.cpp b/indra/newview/llteleporthistorystorage.cpp
index d3bbda1c72..c635f91423 100644
--- a/indra/newview/llteleporthistorystorage.cpp
+++ b/indra/newview/llteleporthistorystorage.cpp
@@ -246,13 +246,6 @@ void LLTeleportHistoryStorage::goToItem(S32 idx)
dump();
return;
}
-
- if (idx == (S32)mItems.size() - 1)
- {
- llwarns << "Will not teleport to the same location." << llendl;
- dump();
- return;
- }
// Attempt to teleport to the requested item.
gAgent.teleportViaLocation(mItems[idx].mGlobalPos);
diff --git a/indra/newview/lltoastnotifypanel.cpp b/indra/newview/lltoastnotifypanel.cpp
index 766cf83a01..d0c125eb77 100644
--- a/indra/newview/lltoastnotifypanel.cpp
+++ b/indra/newview/lltoastnotifypanel.cpp
@@ -179,7 +179,9 @@ void LLToastNotifyPanel::adjustPanelForScriptNotice(const LLNotificationFormPtr
//adjust layout
LLRect button_rect = mControlPanel->getRect();
reshape(getRect().getWidth(), mInfoPanel->getRect().getHeight() + button_panel_height);
+ button_rect.set(0, button_rect.mBottom + button_panel_height, button_rect.getWidth(), button_rect.mBottom);
mControlPanel->reshape(button_rect.getWidth(), button_panel_height);
+ mControlPanel->setRect(button_rect);
}
// static
@@ -217,7 +219,7 @@ LLButton* LLToastNotifyPanel::addButton(const std::string& name, const std::stri
S32 ignore_pad = 0;
S32 button_index = mNumButtons;
S32 index = button_index;
- S32 x = (HPAD * 4) + 32;
+ S32 x = HPAD * 2; // *2 - to make a nice offset
if (mIsScriptDialog)
{
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp
index 3362142807..4e5655274d 100644
--- a/indra/newview/llviewermessage.cpp
+++ b/indra/newview/llviewermessage.cpp
@@ -904,7 +904,19 @@ void open_inventory_offer(const std::vector<LLUUID>& items, const std::string& f
LLPanelPlaces *places_panel = dynamic_cast<LLPanelPlaces*>(LLSideTray::getInstance()->showPanel("panel_places", LLSD()));
if (places_panel)
{
- places_panel->setItem(item);
+ // we are creating a landmark
+ if("create_landmark" == places_panel->getPlaceInfoType() && !places_panel->getItem())
+ {
+ places_panel->setItem(item);
+ }
+ // we are opening a group notice attachment
+ else
+ {
+ LLSD args;
+ args["type"] = "landmark";
+ args["id"] = item_id;
+ LLSideTray::getInstance()->showPanel("panel_places", args);
+ }
}
}
}
@@ -1098,28 +1110,6 @@ bool LLOfferInfo::inventory_offer_callback(const LLSD& notification, const LLSD&
gCacheName->get(mFromID, mFromGroup, boost::bind(&inventory_offer_mute_callback,_1,_2,_3,_4,this));
}
- // *NOTE dzaporozhan
- // Restored from viewer-1-23 to fix EXT-3520
- // Saves Group Notice Attachments to inventory.
- LLMessageSystem* msg = gMessageSystem;
- msg->newMessageFast(_PREHASH_ImprovedInstantMessage);
- msg->nextBlockFast(_PREHASH_AgentData);
- msg->addUUIDFast(_PREHASH_AgentID, gAgent.getID());
- msg->addUUIDFast(_PREHASH_SessionID, gAgent.getSessionID());
- msg->nextBlockFast(_PREHASH_MessageBlock);
- msg->addBOOLFast(_PREHASH_FromGroup, FALSE);
- msg->addUUIDFast(_PREHASH_ToAgentID, mFromID);
- msg->addU8Fast(_PREHASH_Offline, IM_ONLINE);
- msg->addUUIDFast(_PREHASH_ID, mTransactionID);
- msg->addU32Fast(_PREHASH_Timestamp, NO_TIMESTAMP); // no timestamp necessary
- std::string name;
- LLAgentUI::buildFullname(name);
- msg->addStringFast(_PREHASH_FromAgentName, name);
- msg->addStringFast(_PREHASH_Message, "");
- msg->addU32Fast(_PREHASH_ParentEstateID, 0);
- msg->addUUIDFast(_PREHASH_RegionID, LLUUID::null);
- msg->addVector3Fast(_PREHASH_Position, gAgent.getPositionAgent());
-
std::string from_string; // Used in the pop-up.
std::string chatHistory_string; // Used in chat history.
@@ -1155,8 +1145,10 @@ bool LLOfferInfo::inventory_offer_callback(const LLSD& notification, const LLSD&
}
}
break;
- case IM_TASK_INVENTORY_OFFERED:
case IM_GROUP_NOTICE:
+ send_auto_receive_response();
+ break;
+ case IM_TASK_INVENTORY_OFFERED:
case IM_GROUP_NOTICE_REQUESTED:
// This is an offer from a task or group.
// We don't use a new instance of an opener
@@ -1171,10 +1163,6 @@ bool LLOfferInfo::inventory_offer_callback(const LLSD& notification, const LLSD&
// end switch (mIM)
case IOR_ACCEPT:
- msg->addU8Fast(_PREHASH_Dialog, (U8)(mIM + 1));
- msg->addBinaryDataFast(_PREHASH_BinaryBucket, &(mFolderID.mData), sizeof(mFolderID.mData));
- msg->sendReliable(mHost);
-
//don't spam them if they are getting flooded
if (check_offer_throttle(mFromName, true))
{
@@ -1197,7 +1185,10 @@ bool LLOfferInfo::inventory_offer_callback(const LLSD& notification, const LLSD&
{
chat.mMuted = TRUE;
}
- LLFloaterChat::addChatHistory(chat);
+
+ // *NOTE dzaporozhan
+ // Disabled logging to old chat floater to fix crash in group notices - EXT-4149
+ // LLFloaterChat::addChatHistory(chat);
LLInventoryFetchComboObserver::folder_ref_t folders;
LLInventoryFetchComboObserver::item_ref_t items;
@@ -1768,10 +1759,9 @@ void process_improved_im(LLMessageSystem *msg, void **user_data)
}
else if (from_id.isNull())
{
- // Messages from "Second Life" ID don't go to IM history
- // messages which should be routed to IM window come from a user ID with name=SYSTEM_NAME
- chat.mText = name + ": " + message;
- LLFloaterChat::addChat(chat, FALSE, FALSE);
+ LLSD args;
+ args["MESSAGE"] = message;
+ LLNotificationsUtil::add("SystemMessage", args);
}
else if (to_id.isNull())
{
diff --git a/indra/newview/skins/default/xui/en/notifications.xml b/indra/newview/skins/default/xui/en/notifications.xml
index 410c398ea5..b4ce0df6a2 100644
--- a/indra/newview/skins/default/xui/en/notifications.xml
+++ b/indra/newview/skins/default/xui/en/notifications.xml
@@ -2917,6 +2917,16 @@ You have reached your maximum number of groups. Please leave another group befor
<notification
icon="alert.tga"
+ name="JoinedTooManyGroups"
+ type="alert">
+You have reached your maximum number of groups. Please leave some group before joining or creating a new one.
+ <usetemplate
+ name="okbutton"
+ yestext="OK"/>
+ </notification>
+
+ <notification
+ icon="alert.tga"
name="KickUser"
type="alert">
Kick this user with what message?
diff --git a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
index 6c54532a3a..28a6995186 100644
--- a/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_adhoc_control_panel.xml
@@ -4,7 +4,7 @@
follows="all"
height="215"
name="panel_im_control_panel"
- width="180">
+ width="150">
<layout_stack
mouse_opaque="false"
border_size="0"
@@ -16,15 +16,16 @@
name="vertical_stack"
orientation="vertical"
top="0"
- width="177">
+ width="147">
<layout_panel
auto_resize="true"
follows="top|left"
height="130"
layout="topleft"
+ left="0"
min_height="0"
mouse_opaque="false"
- width="180"
+ width="147"
top="0"
name="speakers_list_panel"
user_resize="false">
@@ -39,7 +40,7 @@
show_info_btn="false"
show_profile_btn="false"
show_speaking_indicator="false"
- width="180" />
+ width="147" />
</layout_panel>
<layout_panel
auto_resize="false"
@@ -47,7 +48,7 @@
height="25"
layout="topleft"
min_height="25"
- width="160"
+ width="130"
name="call_btn_panel"
user_resize="false"
visible="false">
@@ -56,7 +57,7 @@
height="20"
label="Call"
name="call_btn"
- width="160"
+ width="130"
top="5" />
</layout_panel>
<layout_panel
@@ -65,7 +66,7 @@
height="25"
layout="topleft"
min_height="25"
- width="160"
+ width="130"
name="end_call_btn_panel"
user_resize="false"
visible="false">
@@ -82,7 +83,7 @@
height="25"
layout="topleft"
min_height="25"
- width="160"
+ width="130"
name="voice_ctrls_btn_panel"
user_resize="false"
visible="false">
diff --git a/indra/newview/skins/default/xui/en/panel_avatar_list_item.xml b/indra/newview/skins/default/xui/en/panel_avatar_list_item.xml
index 45f9d9c7b6..615ade99a2 100644
--- a/indra/newview/skins/default/xui/en/panel_avatar_list_item.xml
+++ b/indra/newview/skins/default/xui/en/panel_avatar_list_item.xml
@@ -58,13 +58,13 @@
top="6"
use_ellipses="true"
value="Unknown"
- width="182" />
+ width="180" />
<text
follows="right"
font="SansSerifSmall"
height="15"
layout="topleft"
- left_pad="8"
+ left_pad="5"
name="last_interaction"
text_color="LtGray_50"
value="0s"
@@ -75,7 +75,7 @@
draw_border="false"
height="16"
layout="topleft"
- left_pad="0"
+ left_pad="5"
mouse_opaque="true"
name="speaking_indicator"
visible="true"
@@ -98,6 +98,7 @@
left_pad="5"
right="-3"
name="profile_btn"
+ tool_tip="View profile"
top_delta="-2"
width="20" />
</panel>
diff --git a/indra/newview/skins/default/xui/en/panel_bottomtray.xml b/indra/newview/skins/default/xui/en/panel_bottomtray.xml
index aeaa049f1f..ca547a79e2 100644
--- a/indra/newview/skins/default/xui/en/panel_bottomtray.xml
+++ b/indra/newview/skins/default/xui/en/panel_bottomtray.xml
@@ -33,10 +33,10 @@
height="10"
image_name="spacer24.tga"
layout="topleft"
- min_width="4"
+ min_width="2"
left="0"
top="0"
- width="4" />
+ width="2" />
<layout_panel
mouse_opaque="false"
auto_resize="false"
@@ -71,7 +71,7 @@
layout="topleft"
left="0"
name="talk"
- top="4"
+ top="5"
width="100">
<show_button>
<show_button.init_callback
@@ -110,7 +110,7 @@
layout="topleft"
name="Gesture"
left="0"
- top="4"
+ top="5"
width="82"
tool_tip="Shows/hides gestures">
<gesture_combo_box.drop_down_button
@@ -153,7 +153,7 @@
layout="topleft"
name="movement_btn"
tool_tip="Shows/hides movement controls"
- top="4"
+ top="5"
width="80">
<button.init_callback
function="Button.SetDockableFloaterToggle"
@@ -195,7 +195,7 @@
layout="topleft"
left="0"
tool_tip="Shows/hides camera controls"
- top="4"
+ top="5"
name="camera_btn"
width="80">
<button.init_callback
@@ -235,7 +235,7 @@
layout="topleft"
name="snapshots"
width="36"
- top="4"
+ top="5"
is_toggle="true"
image_overlay="Snapshot_Off"
tool_tip="Take snapshot">
@@ -338,7 +338,7 @@ as for parent layout_panel (chiclet_list_panel) to resize bottom tray properly.
layout="topleft"
left="0"
name="im_well"
- top="4"
+ top="5"
width="35">
<!--
Emulate 4 states of button by background images, see details in EXT-3147. The same should be for notification_well button
@@ -362,8 +362,6 @@ image_pressed_selected "Lit" + "Selected" - there are new messages and the Well
label_color="Black"
left="0"
name="Unread IM messages"
- pad_left="0"
- pad_right="0"
tool_tip="Conversations"
width="35" >
<button.init_callback
@@ -381,8 +379,8 @@ image_pressed_selected "Lit" + "Selected" - there are new messages and the Well
top="0"
left_pad="3"
name="notification_well_panel"
- width="35"
- min_width="35"
+ width="40"
+ min_width="40"
user_resize="false">
<chiclet_notification
flash_period="0.25"
@@ -392,7 +390,7 @@ image_pressed_selected "Lit" + "Selected" - there are new messages and the Well
left="0"
max_displayed_count="99"
name="notification_well"
- top="4"
+ top="5"
width="35">
<button
bottom_pad="3"
@@ -405,11 +403,11 @@ image_pressed_selected "Lit" + "Selected" - there are new messages and the Well
follows="right"
flash_color="ChicletFlashColor"
label_color="Black"
- left="5"
+ left="0"
name="Unread"
image_overlay="Notices_Unread"
image_overlay_alignment="center"
- pad_right="5"
+ pad_right="15"
tool_tip="Notifications"
width="35" >
<button.init_callback
@@ -418,16 +416,5 @@ image_pressed_selected "Lit" + "Selected" - there are new messages and the Well
</button>
</chiclet_notification>
</layout_panel>
- <icon
- auto_resize="false"
- color="0 0 0 0"
- follows="left|right"
- height="10"
- image_name="spacer24.tga"
- layout="topleft"
- min_width="4"
- right="-1"
- top="0"
- width="4"/>
</layout_stack>
</panel>
diff --git a/indra/newview/skins/default/xui/en/panel_edit_profile.xml b/indra/newview/skins/default/xui/en/panel_edit_profile.xml
index be3c0bbd96..172cf18fc4 100644
--- a/indra/newview/skins/default/xui/en/panel_edit_profile.xml
+++ b/indra/newview/skins/default/xui/en/panel_edit_profile.xml
@@ -301,14 +301,13 @@
left="10"
name="partner_data_panel"
width="285">
- <text
+ <name_box
follows="left|top|right"
height="30"
layout="topleft"
left="0"
name="partner_text"
top="0"
- value="[FIRST] [LAST]"
width="285"
word_wrap="true" />
</panel>
diff --git a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
index 4073ef158b..aa7d621e4c 100644
--- a/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_control_panel.xml
@@ -4,7 +4,7 @@
follows="all"
height="238"
name="panel_im_control_panel"
- width="180">
+ width="150">
<layout_stack
mouse_opaque="false"
border_size="0"
@@ -16,7 +16,7 @@
name="vertical_stack"
orientation="vertical"
top="0"
- width="175">
+ width="145">
<layout_panel
auto_resize="true"
follows="top|left"
@@ -24,7 +24,7 @@
layout="topleft"
min_height="0"
mouse_opaque="false"
- width="180"
+ width="145"
top="0"
name="speakers_list_panel"
user_resize="false">
@@ -39,7 +39,7 @@
show_info_btn="false"
show_profile_btn="false"
show_speaking_indicator="false"
- width="180" />
+ width="145" />
</layout_panel>
<layout_panel
auto_resize="false"
@@ -47,7 +47,7 @@
height="28"
layout="topleft"
min_height="28"
- width="160"
+ width="130"
name="group_info_btn_panel"
user_resize="false">
<button
@@ -57,7 +57,7 @@
name="group_info_btn"
use_ellipses="true"
top="5"
- width="160" />
+ width="130" />
</layout_panel>
<layout_panel
auto_resize="false"
@@ -65,7 +65,7 @@
height="28"
layout="topleft"
min_height="28"
- width="160"
+ width="130"
name="call_btn_panel"
user_resize="false">
<button
@@ -74,7 +74,7 @@
label="Call Group"
name="call_btn"
use_ellipses="true"
- width="160" />
+ width="130" />
</layout_panel>
<layout_panel
auto_resize="false"
@@ -82,7 +82,7 @@
height="28"
layout="topleft"
min_height="28"
- width="160"
+ width="130"
name="end_call_btn_panel"
user_resize="false"
visible="false">
@@ -99,7 +99,7 @@
height="28"
layout="topleft"
min_height="28"
- width="160"
+ width="130"
name="voice_ctrls_btn_panel"
user_resize="false"
visible="false">
diff --git a/indra/newview/skins/default/xui/en/panel_group_list_item.xml b/indra/newview/skins/default/xui/en/panel_group_list_item.xml
index 5f6b911620..c243d08b97 100644
--- a/indra/newview/skins/default/xui/en/panel_group_list_item.xml
+++ b/indra/newview/skins/default/xui/en/panel_group_list_item.xml
@@ -65,6 +65,7 @@
left_pad="5"
right="-3"
name="profile_btn"
+ tool_tip="View profile"
top_delta="-2"
width="20" />
</panel>
diff --git a/indra/newview/skins/default/xui/en/panel_my_profile.xml b/indra/newview/skins/default/xui/en/panel_my_profile.xml
index 8327edfdd0..038d48cdd6 100644
--- a/indra/newview/skins/default/xui/en/panel_my_profile.xml
+++ b/indra/newview/skins/default/xui/en/panel_my_profile.xml
@@ -28,6 +28,9 @@
name="no_partner_text"
value="None" />
<string
+ name="no_group_text"
+ value="None" />
+ <string
name="RegisterDateFormat">
[REG_DATE] ([AGE])
</string>
@@ -62,10 +65,11 @@
<panel
layout="topleft"
follows="left|top|right"
+ height="505"
name="scroll_content_panel"
top="0"
left="0"
- width="303">
+ width="297">
<panel
follows="left|top|right"
height="117"
@@ -73,7 +77,7 @@
left="10"
name="second_life_image_panel"
top="0"
- width="300">
+ width="297">
<texture_picker
allow_no_texture="true"
default_image_name="None"
@@ -114,7 +118,7 @@
textbox.max_length="512"
name="sl_description_edit"
top_pad="-3"
- width="188"
+ width="181"
expanded_bg_visible="true"
expanded_bg_color="DkGray">
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean viverra orci et justo sagittis aliquet. Nullam malesuada mauris sit amet ipsum. adipiscing elit. Aenean viverra orci et justo sagittis aliquet. Nullam malesuada mauris sit amet ipsum. adipiscing elit. Aenean viverra orci et justo sagittis aliquet. Nullam malesuada mauris sit amet ipsum.
@@ -127,7 +131,7 @@
top_pad="10"
left="10"
name="first_life_image_panel"
- width="300">
+ width="297">
<texture_picker
allow_no_texture="true"
default_image_name="None"
@@ -167,7 +171,7 @@
textbox.max_length="512"
name="fl_description_edit"
top_pad="-3"
- width="188"
+ width="181"
expanded_bg_visible="true"
expanded_bg_color="DkGray">
Lorem ipsum dolor sit amet, consectetur adlkjpiscing elit moose moose. Aenean viverra orci et justo sagittis aliquet. Nullam malesuada mauris sit amet. adipiscing elit. Aenean rigviverra orci et justo sagittis aliquet. Nullam malesuada mauris sit amet sorbet ipsum. adipiscing elit. Aenean viverra orci et justo sagittis aliquet. Nullam malesuada mauris sit amet ipsum.
@@ -260,14 +264,13 @@
name="partner_data_panel"
top_pad="0"
width="300">
- <text
+ <name_box
follows="left|top"
height="10"
layout="topleft"
left="0"
name="partner_text"
top="0"
- value="[FIRST] [LAST]"
width="300"
word_wrap="true" />
</panel>
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 f09a0e03ed..2b361c0628 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 @@
max_length="512"
name="chat_box"
tool_tip="Press Enter to say, Ctrl+Enter to shout"
- top="1"
+ top="2"
width="283" />
<output_monitor
auto_update="true"
@@ -45,7 +45,7 @@
follows="right"
is_toggle="true"
width="20"
- top="1"
+ top="2"
layout="topleft"
left_pad="4"
image_disabled="ComboButton_UpOff"
diff --git a/indra/newview/skins/default/xui/en/panel_profile.xml b/indra/newview/skins/default/xui/en/panel_profile.xml
index 43947262ec..ec697838f6 100644
--- a/indra/newview/skins/default/xui/en/panel_profile.xml
+++ b/indra/newview/skins/default/xui/en/panel_profile.xml
@@ -28,6 +28,9 @@
name="no_partner_text"
value="None" />
<string
+ name="no_group_text"
+ value="None" />
+ <string
name="RegisterDateFormat">
[REG_DATE] ([AGE])
</string>
@@ -62,10 +65,11 @@
<panel
layout="topleft"
follows="left|top|right"
+ height="505"
name="profile_scroll_panel"
top="0"
left="0"
- width="303">
+ width="297">
<panel
follows="left|top|right"
height="117"
@@ -73,7 +77,7 @@
left="10"
name="second_life_image_panel"
top="0"
- width="303">
+ width="297">
<texture_picker
allow_no_texture="true"
default_image_name="None"
@@ -117,7 +121,7 @@
top_pad="10"
left="10"
name="first_life_image_panel"
- width="303">
+ width="297">
<texture_picker
allow_no_texture="true"
default_image_name="None"
@@ -240,14 +244,13 @@
name="partner_data_panel"
top_pad="0"
width="300">
- <text
+ <name_box
follows="left|top"
height="10"
layout="topleft"
left="0"
name="partner_text"
top="0"
- value="[FIRST] [LAST]"
width="300"
word_wrap="true" />
</panel>
@@ -269,7 +272,7 @@
left="7"
name="sl_groups"
top_pad="0"
- width="298"
+ width="290"
expanded_bg_visible="true"
expanded_bg_color="DkGray">
Lorem ipsum dolor sit amet, consectetur adlkjpiscing elit moose moose. Aenean viverra orci et justo sagittis aliquet. Nullam malesuada mauris sit amet. adipiscing elit. Aenean rigviverra orci et justo sagittis aliquet. Nullam malesuada mauris sit amet sorbet ipsum. adipiscing elit. Aenean viverra orci et justo sagittis aliquet. Nullam malesuada mauris sit amet ipsum. Aenean viverra tulip moosetop. Slan de heelish marfnik tooplod. Sum sum to whop de wompam booster copm.
@@ -375,4 +378,4 @@
</layout_panel>
</layout_stack>
-</panel> \ No newline at end of file
+</panel>