summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2012-12-05 20:26:26 -0800
committerMerov Linden <merov@lindenlab.com>2012-12-05 20:26:26 -0800
commit42a60e6ca5f4179738fa9a7376d1e842bc058ac4 (patch)
tree8e1f74ebf472a2ea9ae74f4ea65409c418555218 /indra
parent3a49beed0e96a797a6d663bcae5e932437ca3661 (diff)
parent32d7131b1034d03fa9d3fdde8b86ee9880bb4f67 (diff)
Pull merge from dev repo
Diffstat (limited to 'indra')
-rw-r--r--indra/llui/llbutton.cpp2
-rw-r--r--indra/llui/llflashtimer.cpp9
-rw-r--r--indra/llui/llflashtimer.h6
-rwxr-xr-xindra/llui/llfolderviewitem.cpp46
-rwxr-xr-xindra/llui/llfolderviewitem.h10
-rw-r--r--indra/llui/llnotifications.cpp3
-rw-r--r--indra/llui/llnotifications.h13
-rw-r--r--indra/llui/lltabcontainer.cpp11
-rw-r--r--indra/llui/lltabcontainer.h4
-rw-r--r--indra/newview/llchiclet.cpp882
-rw-r--r--indra/newview/llchiclet.h555
-rw-r--r--indra/newview/llchicletbar.cpp104
-rw-r--r--indra/newview/llchicletbar.h16
-rw-r--r--indra/newview/llconversationmodel.cpp25
-rwxr-xr-xindra/newview/llconversationview.cpp21
-rw-r--r--indra/newview/llfloaterimcontainer.cpp81
-rw-r--r--indra/newview/llfloaterimcontainer.h1
-rw-r--r--indra/newview/llfloaterimnearbychat.cpp1
-rw-r--r--indra/newview/llfloaterimnearbychathandler.cpp5
-rw-r--r--indra/newview/llfloaterimsession.cpp11
-rw-r--r--indra/newview/llfloaterimsessiontab.cpp11
-rw-r--r--indra/newview/llimview.cpp20
-rw-r--r--indra/newview/llinventorybridge.cpp5
-rw-r--r--indra/newview/llinventorybridge.h1
-rw-r--r--indra/newview/llinventorypanel.cpp24
-rw-r--r--indra/newview/llinventorypanel.h7
-rw-r--r--indra/newview/llnotificationofferhandler.cpp1
-rw-r--r--indra/newview/llscriptfloater.cpp121
-rwxr-xr-xindra/newview/llstartup.cpp7
-rw-r--r--indra/newview/llsyswellwindow.cpp289
-rw-r--r--indra/newview/llsyswellwindow.h66
-rwxr-xr-xindra/newview/llviewermessage.cpp5
-rw-r--r--indra/newview/skins/default/textures/bottomtray/Notices_Unread.pngbin3693 -> 0 bytes
-rw-r--r--indra/newview/skins/default/textures/bottomtray/VoicePTT_Lvl1_Dark.pngbin602 -> 0 bytes
-rw-r--r--indra/newview/skins/default/textures/bottomtray/VoicePTT_Lvl2_Dark.pngbin669 -> 0 bytes
-rw-r--r--indra/newview/skins/default/textures/bottomtray/VoicePTT_Lvl3_Dark.pngbin639 -> 0 bytes
-rw-r--r--indra/newview/skins/default/textures/bottomtray/VoicePTT_Off_Dark.pngbin547 -> 0 bytes
-rw-r--r--indra/newview/skins/default/textures/bottomtray/VoicePTT_On_Dark.pngbin526 -> 0 bytes
-rw-r--r--indra/newview/skins/default/textures/textures.xml8
-rw-r--r--indra/newview/skins/default/xui/da/menu_im_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/da/menu_notification_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/de/menu_im_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/de/menu_notification_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/en/floater_camera.xml2
-rw-r--r--indra/newview/skins/default/xui/en/floater_destinations.xml7
-rw-r--r--indra/newview/skins/default/xui/en/floater_im_container.xml9
-rw-r--r--indra/newview/skins/default/xui/en/floater_im_session.xml6
-rw-r--r--indra/newview/skins/default/xui/en/floater_moveview.xml2
-rw-r--r--indra/newview/skins/default/xui/en/menu_conversation.xml12
-rw-r--r--indra/newview/skins/default/xui/en/menu_notification_well_button.xml16
-rw-r--r--indra/newview/skins/default/xui/en/panel_activeim_row.xml97
-rw-r--r--indra/newview/skins/default/xui/en/panel_chiclet_bar.xml44
-rw-r--r--indra/newview/skins/default/xui/en/strings.xml2
-rw-r--r--indra/newview/skins/default/xui/en/widgets/chiclet_im_adhoc.xml55
-rw-r--r--indra/newview/skins/default/xui/en/widgets/chiclet_im_group.xml56
-rw-r--r--indra/newview/skins/default/xui/en/widgets/chiclet_im_p2p.xml56
-rw-r--r--indra/newview/skins/default/xui/es/menu_im_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/es/menu_notification_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/fr/menu_im_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/fr/menu_notification_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/it/menu_im_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/it/menu_notification_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/ja/menu_im_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/ja/menu_notification_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/pl/menu_im_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/pl/menu_notification_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/pt/menu_im_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/pt/menu_notification_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/ru/menu_im_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/ru/menu_notification_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/tr/menu_im_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/tr/menu_notification_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/zh/menu_im_well_button.xml4
-rw-r--r--indra/newview/skins/default/xui/zh/menu_notification_well_button.xml4
74 files changed, 358 insertions, 2465 deletions
diff --git a/indra/llui/llbutton.cpp b/indra/llui/llbutton.cpp
index 97547208ec..f82cdc64a9 100644
--- a/indra/llui/llbutton.cpp
+++ b/indra/llui/llbutton.cpp
@@ -286,7 +286,7 @@ LLButton::~LLButton()
if (mFlashingTimer)
{
- delete mFlashingTimer;
+ mFlashingTimer->unset();
}
}
diff --git a/indra/llui/llflashtimer.cpp b/indra/llui/llflashtimer.cpp
index de7a4ab265..e49628acd5 100644
--- a/indra/llui/llflashtimer.cpp
+++ b/indra/llui/llflashtimer.cpp
@@ -35,6 +35,7 @@ LLFlashTimer::LLFlashTimer(callback_t cb, S32 count, F32 period)
, mCurrentTickCount(0)
, mIsFlashingInProgress(false)
, mIsCurrentlyHighlighted(false)
+ , mUnset(false)
{
mEventTimer.stop();
@@ -48,6 +49,12 @@ LLFlashTimer::LLFlashTimer(callback_t cb, S32 count, F32 period)
}
}
+void LLFlashTimer::unset()
+{
+ mUnset = true;
+ mCallback = NULL;
+}
+
BOOL LLFlashTimer::tick()
{
mIsCurrentlyHighlighted = !mIsCurrentlyHighlighted;
@@ -62,7 +69,7 @@ BOOL LLFlashTimer::tick()
stopFlashing();
}
- return FALSE;
+ return mUnset;
}
void LLFlashTimer::startFlashing()
diff --git a/indra/llui/llflashtimer.h b/indra/llui/llflashtimer.h
index 5c8860b097..c60f99a8ea 100644
--- a/indra/llui/llflashtimer.h
+++ b/indra/llui/llflashtimer.h
@@ -52,6 +52,11 @@ public:
bool isFlashingInProgress();
bool isCurrentlyHighlighted();
+ /*
+ * Use this instead of deleting this object.
+ * The next call to tick() will return true and that will destroy this object.
+ */
+ void unset();
private:
callback_t mCallback;
@@ -62,6 +67,7 @@ private:
S32 mCurrentTickCount;
bool mIsCurrentlyHighlighted;
bool mIsFlashingInProgress;
+ bool mUnset;
};
#endif /* LL_FLASHTIMER_H */
diff --git a/indra/llui/llfolderviewitem.cpp b/indra/llui/llfolderviewitem.cpp
index 261f53d6b6..60a6d3e3ea 100755
--- a/indra/llui/llfolderviewitem.cpp
+++ b/indra/llui/llfolderviewitem.cpp
@@ -47,16 +47,14 @@ static LLDefaultChildRegistry::Register<LLFolderViewItem> r("folder_view_item");
// statics
std::map<U8, LLFontGL*> LLFolderViewItem::sFonts; // map of styles to fonts
+bool LLFolderViewItem::sColorSetInitialized = false;
LLUIColor LLFolderViewItem::sFgColor;
LLUIColor LLFolderViewItem::sHighlightBgColor;
-LLUIColor LLFolderViewItem::sHighlightFgColor;
LLUIColor LLFolderViewItem::sFocusOutlineColor;
LLUIColor LLFolderViewItem::sMouseOverColor;
LLUIColor LLFolderViewItem::sFilterBGColor;
LLUIColor LLFolderViewItem::sFilterTextColor;
LLUIColor LLFolderViewItem::sSuffixColor;
-LLUIColor LLFolderViewItem::sLibraryColor;
-LLUIColor LLFolderViewItem::sLinkColor;
LLUIColor LLFolderViewItem::sSearchStatusColor;
// only integers can be initialized in header
@@ -106,6 +104,8 @@ LLFolderViewItem::Params::Params()
item_top_pad("item_top_pad"),
creation_date(),
allow_open("allow_open", true),
+ font_color("font_color"),
+ font_highlight_color("font_highlight_color"),
left_pad("left_pad", 0),
icon_pad("icon_pad", 0),
icon_width("icon_width", 0),
@@ -113,7 +113,7 @@ LLFolderViewItem::Params::Params()
text_pad_right("text_pad_right", 0),
arrow_size("arrow_size", 0),
max_folder_item_overlap("max_folder_item_overlap", 0)
-{}
+{ }
// Default constructor
LLFolderViewItem::LLFolderViewItem(const LLFolderViewItem::Params& p)
@@ -137,6 +137,8 @@ LLFolderViewItem::LLFolderViewItem(const LLFolderViewItem::Params& p)
mViewModelItem(p.listener),
mIsMouseOverTitle(false),
mAllowOpen(p.allow_open),
+ mFontColor(p.font_color),
+ mFontHighlightColor(p.font_highlight_color),
mLeftPad(p.left_pad),
mIconPad(p.icon_pad),
mIconWidth(p.icon_width),
@@ -145,17 +147,18 @@ LLFolderViewItem::LLFolderViewItem(const LLFolderViewItem::Params& p)
mArrowSize(p.arrow_size),
mMaxFolderItemOverlap(p.max_folder_item_overlap)
{
- sFgColor = LLUIColorTable::instance().getColor("MenuItemEnabledColor", DEFAULT_WHITE);
- sHighlightBgColor = LLUIColorTable::instance().getColor("MenuItemHighlightBgColor", DEFAULT_WHITE);
- sHighlightFgColor = LLUIColorTable::instance().getColor("MenuItemHighlightFgColor", DEFAULT_WHITE);
- sFocusOutlineColor = LLUIColorTable::instance().getColor("InventoryFocusOutlineColor", DEFAULT_WHITE);
- sMouseOverColor = LLUIColorTable::instance().getColor("InventoryMouseOverColor", DEFAULT_WHITE);
- sFilterBGColor = LLUIColorTable::instance().getColor("FilterBackgroundColor", DEFAULT_WHITE);
- sFilterTextColor = LLUIColorTable::instance().getColor("FilterTextColor", DEFAULT_WHITE);
- sSuffixColor = LLUIColorTable::instance().getColor("InventoryItemColor", DEFAULT_WHITE);
- sLibraryColor = LLUIColorTable::instance().getColor("InventoryItemLibraryColor", DEFAULT_WHITE);
- sLinkColor = LLUIColorTable::instance().getColor("InventoryItemLinkColor", DEFAULT_WHITE);
- sSearchStatusColor = LLUIColorTable::instance().getColor("InventorySearchStatusColor", DEFAULT_WHITE);
+ if (!sColorSetInitialized)
+ {
+ sFgColor = LLUIColorTable::instance().getColor("MenuItemEnabledColor", DEFAULT_WHITE);
+ sHighlightBgColor = LLUIColorTable::instance().getColor("MenuItemHighlightBgColor", DEFAULT_WHITE);
+ sFocusOutlineColor = LLUIColorTable::instance().getColor("InventoryFocusOutlineColor", DEFAULT_WHITE);
+ sMouseOverColor = LLUIColorTable::instance().getColor("InventoryMouseOverColor", DEFAULT_WHITE);
+ sFilterBGColor = LLUIColorTable::instance().getColor("FilterBackgroundColor", DEFAULT_WHITE);
+ sFilterTextColor = LLUIColorTable::instance().getColor("FilterTextColor", DEFAULT_WHITE);
+ sSuffixColor = LLUIColorTable::instance().getColor("InventoryItemColor", DEFAULT_WHITE);
+ sSearchStatusColor = LLUIColorTable::instance().getColor("InventorySearchStatusColor", DEFAULT_WHITE);
+ sColorSetInitialized = true;
+ }
if (mViewModelItem)
{
@@ -501,7 +504,7 @@ BOOL LLFolderViewItem::handleMouseDown( S32 x, S32 y, MASK mask )
// No handler needed for focus lost since this class has no
// state that depends on it.
gFocusMgr.setMouseCapture( this );
-
+
if (!mIsSelected)
{
if(mask & MASK_CONTROL)
@@ -518,6 +521,11 @@ BOOL LLFolderViewItem::handleMouseDown( S32 x, S32 y, MASK mask )
}
make_ui_sound("UISndClick");
}
+ //Just re-select the item since it is clicked without ctrl or shift
+ else if(!(mask & (MASK_CONTROL | MASK_SHIFT)))
+ {
+ getRoot()->setSelection(this, FALSE);
+ }
else
{
mSelectPending = TRUE;
@@ -780,10 +788,6 @@ void LLFolderViewItem::drawHighlight(const BOOL showContent, const BOOL hasKeybo
void LLFolderViewItem::drawLabel(const LLFontGL * font, const F32 x, const F32 y, const LLColor4& color, F32 &right_x)
{
- //TODO RN: implement this in terms of getColor()
- //if (highlight_link) color = sLinkColor;
- //if (gInventory.isObjectDescendentOf(getViewModelItem()->getUUID(), gInventory.getLibraryRootFolderID())) color = sLibraryColor;
-
//--------------------------------------------------------------------------------//
// Draw the actual label text
//
@@ -852,7 +856,7 @@ void LLFolderViewItem::draw()
box_image->draw(box_rect, sFilterBGColor);
}
- LLColor4 color = (mIsSelected && filled) ? sHighlightFgColor : sFgColor;
+ LLColor4 color = (mIsSelected && filled) ? mFontHighlightColor : mFontColor;
drawLabel(font, text_left, y, color, right_x);
//--------------------------------------------------------------------------------//
diff --git a/indra/llui/llfolderviewitem.h b/indra/llui/llfolderviewitem.h
index 2e633a39e5..f33f21c8f8 100755
--- a/indra/llui/llfolderviewitem.h
+++ b/indra/llui/llfolderviewitem.h
@@ -61,6 +61,9 @@ public:
Optional<time_t> creation_date;
Optional<bool> allow_open;
+ Optional<LLUIColor> font_color;
+ Optional<LLUIColor> font_highlight_color;
+
Optional<S32> left_pad,
icon_pad,
icon_width,
@@ -116,19 +119,20 @@ protected:
mIsMouseOverTitle,
mAllowOpen,
mSelectPending;
+
+ LLUIColor mFontColor;
+ LLUIColor mFontHighlightColor;
// For now assuming all colors are the same in derived classes.
+ static bool sColorSetInitialized;
static LLUIColor sFgColor;
static LLUIColor sFgDisabledColor;
static LLUIColor sHighlightBgColor;
- static LLUIColor sHighlightFgColor;
static LLUIColor sFocusOutlineColor;
static LLUIColor sMouseOverColor;
static LLUIColor sFilterBGColor;
static LLUIColor sFilterTextColor;
static LLUIColor sSuffixColor;
- static LLUIColor sLibraryColor;
- static LLUIColor sLinkColor;
static LLUIColor sSearchStatusColor;
// this is an internal method used for adding items to folders. A
diff --git a/indra/llui/llnotifications.cpp b/indra/llui/llnotifications.cpp
index 66144671c9..fd9bfec203 100644
--- a/indra/llui/llnotifications.cpp
+++ b/indra/llui/llnotifications.cpp
@@ -475,7 +475,8 @@ LLNotification::LLNotification(const LLSDParamAdapter<Params>& p) :
mCancelled(false),
mIgnored(false),
mResponderObj(NULL),
- mId(p.id.isProvided() ? p.id : LLUUID::generateNewID())
+ mId(p.id.isProvided() ? p.id : LLUUID::generateNewID()),
+ mOfferFromAgent(p.offer_from_agent)
{
if (p.functor.name.isChosen())
{
diff --git a/indra/llui/llnotifications.h b/indra/llui/llnotifications.h
index 088931858a..372b9ce46f 100644
--- a/indra/llui/llnotifications.h
+++ b/indra/llui/llnotifications.h
@@ -316,6 +316,7 @@ public:
expiry;
Optional<LLNotificationContext*> context;
Optional<void*> responder;
+ Optional<bool> offer_from_agent;
struct Functor : public LLInitParam::ChoiceBlock<Functor>
{
@@ -339,7 +340,8 @@ public:
payload("payload"),
form_elements("form"),
substitutions("substitutions"),
- expiry("expiry")
+ expiry("expiry"),
+ offer_from_agent("offer_from_agent", false)
{
time_stamp = LLDate::now();
responder = NULL;
@@ -352,7 +354,8 @@ public:
payload("payload"),
form_elements("form"),
substitutions("substitutions"),
- expiry("expiry")
+ expiry("expiry"),
+ offer_from_agent("offer_from_agent", false)
{
functor.name = _name;
name = _name;
@@ -378,6 +381,7 @@ private:
LLNotificationFormPtr mForm;
void* mResponderObj; // TODO - refactor/remove this field
LLNotificationResponderPtr mResponder;
+ bool mOfferFromAgent;
// a reference to the template
LLNotificationTemplatePtr mTemplatep;
@@ -513,6 +517,11 @@ public:
return mTimestamp;
}
+ bool getOfferFromAgent() const
+ {
+ return mOfferFromAgent;
+ }
+
std::string getType() const;
std::string getMessage() const;
std::string getFooter() const;
diff --git a/indra/llui/lltabcontainer.cpp b/indra/llui/lltabcontainer.cpp
index 3c1dfc1184..91527c68f2 100644
--- a/indra/llui/lltabcontainer.cpp
+++ b/indra/llui/lltabcontainer.cpp
@@ -1556,17 +1556,6 @@ BOOL LLTabContainer::setTab(S32 which)
return is_visible;
}
-
-void LLTabContainer::hideAllTabs()
-{
- setCurrentPanelIndex(-1);
- for(tuple_list_t::iterator iter = mTabList.begin(); iter != mTabList.end(); ++iter)
- {
- (* iter)->mTabPanel->setVisible(FALSE);
- }
-}
-
-
BOOL LLTabContainer::selectTabByName(const std::string& name)
{
LLPanel* panel = getPanelByName(name);
diff --git a/indra/llui/lltabcontainer.h b/indra/llui/lltabcontainer.h
index a9cdf22b16..57862fc626 100644
--- a/indra/llui/lltabcontainer.h
+++ b/indra/llui/lltabcontainer.h
@@ -192,7 +192,7 @@ public:
BOOL selectTabPanel( LLPanel* child );
BOOL selectTab(S32 which);
BOOL selectTabByName(const std::string& title);
- void hideAllTabs();
+ void setCurrentPanelIndex(S32 index) { mCurrentTabIdx = index; }
BOOL getTabPanelFlashing(LLPanel* child);
void setTabPanelFlashing(LLPanel* child, BOOL state);
@@ -243,8 +243,6 @@ private:
void setTabsHidden(BOOL hidden) { mTabsHidden = hidden; }
BOOL getTabsHidden() const { return mTabsHidden; }
-
- void setCurrentPanelIndex(S32 index) { mCurrentTabIdx = index; }
void scrollPrev() { mScrollPos = llmax(0, mScrollPos-1); } // No wrap
void scrollNext() { mScrollPos = llmin(mScrollPos+1, mMaxScrollPos); } // No wrap
diff --git a/indra/newview/llchiclet.cpp b/indra/newview/llchiclet.cpp
index a665aeb6bd..1acbdd32b7 100644
--- a/indra/newview/llchiclet.cpp
+++ b/indra/newview/llchiclet.cpp
@@ -27,35 +27,15 @@
#include "llviewerprecompiledheaders.h" // must be first include
#include "llchiclet.h"
-#include "llagent.h"
-#include "llavataractions.h"
-#include "llchicletbar.h"
-#include "lleventtimer.h"
-#include "llgroupactions.h"
-#include "lliconctrl.h"
#include "llfloaterimsession.h"
#include "llfloaterimcontainer.h"
-#include "llimview.h"
#include "llfloaterreg.h"
#include "lllocalcliprect.h"
-#include "llmenugl.h"
#include "llnotifications.h"
-#include "llnotificationsutil.h"
-#include "lloutputmonitorctrl.h"
#include "llscriptfloater.h"
-#include "llspeakers.h"
-#include "lltextbox.h"
-#include "llvoiceclient.h"
-#include "llgroupmgr.h"
-#include "llnotificationmanager.h"
-#include "lltransientfloatermgr.h"
-#include "llsyswellwindow.h"
+#include "llsingleton.h"
static LLDefaultChildRegistry::Register<LLChicletPanel> t1("chiclet_panel");
-static LLDefaultChildRegistry::Register<LLNotificationChiclet> t2("chiclet_notification");
-static LLDefaultChildRegistry::Register<LLIMP2PChiclet> t3("chiclet_im_p2p");
-static LLDefaultChildRegistry::Register<LLIMGroupChiclet> t4("chiclet_im_group");
-static LLDefaultChildRegistry::Register<LLAdHocChiclet> t5("chiclet_im_adhoc");
static LLDefaultChildRegistry::Register<LLScriptChiclet> t6("chiclet_script");
static LLDefaultChildRegistry::Register<LLInvOfferChiclet> t7("chiclet_offer");
@@ -66,192 +46,6 @@ boost::signals2::signal<LLChiclet* (const LLUUID&),
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
-
-LLSysWellChiclet::Params::Params()
-: button("button")
-, unread_notifications("unread_notifications")
-, max_displayed_count("max_displayed_count", 99)
-{
- button.name = "button";
- button.tab_stop = FALSE;
- button.label = LLStringUtil::null;
-}
-
-LLSysWellChiclet::LLSysWellChiclet(const Params& p)
-: LLChiclet(p)
-, mButton(NULL)
-, mCounter(0)
-, mMaxDisplayedCount(p.max_displayed_count)
-, mIsNewMessagesState(false)
-, mFlashToLitTimer(NULL)
-, mContextMenu(NULL)
-{
- LLButton::Params button_params = p.button;
- mButton = LLUICtrlFactory::create<LLButton>(button_params);
- addChild(mButton);
-
-
- mFlashToLitTimer = new LLFlashTimer(boost::bind(&LLSysWellChiclet::changeLitState, this, _1));
-}
-
-LLSysWellChiclet::~LLSysWellChiclet()
-{
- delete mFlashToLitTimer;
-}
-
-void LLSysWellChiclet::setCounter(S32 counter)
-{
- // do nothing if the same counter is coming. EXT-3678.
- if (counter == mCounter) return;
-
- // note same code in LLChicletNotificationCounterCtrl::setCounter(S32 counter)
- std::string s_count;
- if(counter != 0)
- {
- static std::string more_messages_exist("+");
- std::string more_messages(counter > mMaxDisplayedCount ? more_messages_exist : "");
- s_count = llformat("%d%s"
- , llmin(counter, mMaxDisplayedCount)
- , more_messages.c_str()
- );
- }
-
- mButton->setLabel(s_count);
-
- mCounter = counter;
-}
-
-boost::signals2::connection LLSysWellChiclet::setClickCallback(
- const commit_callback_t& cb)
-{
- return mButton->setClickedCallback(cb);
-}
-
-void LLSysWellChiclet::setToggleState(BOOL toggled) {
- mButton->setToggleState(toggled);
-}
-
-void LLSysWellChiclet::changeLitState(bool blink)
-{
- setNewMessagesState(!mIsNewMessagesState);
-}
-
-void LLSysWellChiclet::setNewMessagesState(bool new_messages)
-{
- /*
- Emulate 4 states of button by background images, see detains in EXT-3147
- xml attribute Description
- image_unselected "Unlit" - there are no new messages
- image_selected "Unlit" + "Selected" - there are no new messages and the Well is open
- image_pressed "Lit" - there are new messages
- image_pressed_selected "Lit" + "Selected" - there are new messages and the Well is open
- */
- mButton->setForcePressedState(new_messages);
-
- mIsNewMessagesState = new_messages;
-}
-
-void LLSysWellChiclet::updateWidget(bool is_window_empty)
-{
- mButton->setEnabled(!is_window_empty);
-
- if (LLChicletBar::instanceExists())
- {
- LLChicletBar::getInstance()->showWellButton(getName(), !is_window_empty);
- }
-}
-// virtual
-BOOL LLSysWellChiclet::handleRightMouseDown(S32 x, S32 y, MASK mask)
-{
- if(!mContextMenu)
- {
- createMenu();
- }
- if (mContextMenu)
- {
- mContextMenu->show(x, y);
- LLMenuGL::showPopup(this, mContextMenu, x, y);
- }
- return TRUE;
-}
-
-/************************************************************************/
-/* LLNotificationChiclet implementation */
-/************************************************************************/
-LLNotificationChiclet::LLNotificationChiclet(const Params& p)
-: LLSysWellChiclet(p),
- mUreadSystemNotifications(0)
-{
- mNotificationChannel.reset(new ChicletNotificationChannel(this));
- // ensure that notification well window exists, to synchronously
- // handle toast add/delete events.
- LLNotificationWellWindow::getInstance()->setSysWellChiclet(this);
-}
-
-void LLNotificationChiclet::onMenuItemClicked(const LLSD& user_data)
-{
- std::string action = user_data.asString();
- if("close all" == action)
- {
- LLNotificationWellWindow::getInstance()->closeAll();
- }
-}
-
-bool LLNotificationChiclet::enableMenuItem(const LLSD& user_data)
-{
- std::string item = user_data.asString();
- if (item == "can close all")
- {
- return mUreadSystemNotifications != 0;
- }
- return true;
-}
-
-void LLNotificationChiclet::createMenu()
-{
- if(mContextMenu)
- {
- llwarns << "Menu already exists" << llendl;
- return;
- }
-
- LLUICtrl::CommitCallbackRegistry::ScopedRegistrar registrar;
- registrar.add("NotificationWellChicletMenu.Action",
- boost::bind(&LLNotificationChiclet::onMenuItemClicked, this, _2));
-
- LLUICtrl::EnableCallbackRegistry::ScopedRegistrar enable_registrar;
- enable_registrar.add("NotificationWellChicletMenu.EnableItem",
- boost::bind(&LLNotificationChiclet::enableMenuItem, this, _2));
-
- mContextMenu = LLUICtrlFactory::getInstance()->createFromFile<LLContextMenu>
- ("menu_notification_well_button.xml",
- LLMenuGL::sMenuContainer,
- LLViewerMenuHolderGL::child_registry_t::instance());
-}
-
-/*virtual*/
-void LLNotificationChiclet::setCounter(S32 counter)
-{
- LLSysWellChiclet::setCounter(counter);
- updateWidget(getCounter() == 0);
-
-}
-
-bool LLNotificationChiclet::ChicletNotificationChannel::filterNotification( LLNotificationPtr notification )
-{
- if( !(notification->canLogToIM() && notification->hasFormElements())
- && (!notification->getPayload().has("give_inventory_notification")
- || notification->getPayload()["give_inventory_notification"]))
- {
- return true;
- }
- return false;
-}
-
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-
LLChiclet::Params::Params()
: show_counter("show_counter", true)
, enable_counter("enable_counter", false)
@@ -303,7 +97,9 @@ LLSD LLChiclet::getValue() const
void LLChiclet::setValue(const LLSD& value)
{
if(value.isUUID())
+ {
setSessionId(value.asUUID());
+ }
}
//////////////////////////////////////////////////////////////////////////
@@ -315,12 +111,9 @@ LLIMChiclet::LLIMChiclet(const LLIMChiclet::Params& p)
, mShowSpeaker(false)
, mDefaultWidth(p.rect().getWidth())
, mNewMessagesIcon(NULL)
-, mSpeakerCtrl(NULL)
-, mCounterCtrl(NULL)
, mChicletButton(NULL)
, mPopupMenu(NULL)
{
- enableCounterControl(p.enable_counter);
}
/* virtual*/
@@ -331,107 +124,14 @@ BOOL LLIMChiclet::postBuild()
mChicletButton->setDoubleClickCallback(boost::bind(&LLIMChiclet::onMouseDown, this));
return TRUE;
}
-void LLIMChiclet::setShowSpeaker(bool show)
-{
- bool needs_resize = getShowSpeaker() != show;
- if(needs_resize)
- {
- mShowSpeaker = show;
- }
-
- toggleSpeakerControl();
-}
-
-void LLIMChiclet::enableCounterControl(bool enable)
-{
- mCounterEnabled = enable;
- if(!enable)
- {
- LLChiclet::setShowCounter(false);
- }
-}
-
-void LLIMChiclet::setShowCounter(bool show)
-{
- if(!mCounterEnabled)
- {
- return;
- }
-
- bool needs_resize = getShowCounter() != show;
- if(needs_resize)
- {
- LLChiclet::setShowCounter(show);
- toggleCounterControl();
- }
-}
-
-void LLIMChiclet::initSpeakerControl()
-{
- // virtual
-}
void LLIMChiclet::setRequiredWidth()
{
- bool show_speaker = getShowSpeaker();
- bool show_counter = getShowCounter();
S32 required_width = mDefaultWidth;
-
- if (show_counter)
- {
- required_width += mCounterCtrl->getRect().getWidth();
- }
- if (show_speaker)
- {
- required_width += mSpeakerCtrl->getRect().getWidth();
- }
-
reshape(required_width, getRect().getHeight());
-
onChicletSizeChanged();
}
-void LLIMChiclet::toggleSpeakerControl()
-{
- if(getShowSpeaker())
- {
- // move speaker to the right of chiclet icon
- LLRect speaker_rc = mSpeakerCtrl->getRect();
- speaker_rc.setLeftTopAndSize(mDefaultWidth, speaker_rc.mTop, speaker_rc.getWidth(), speaker_rc.getHeight());
- mSpeakerCtrl->setRect(speaker_rc);
-
- if(getShowCounter())
- {
- // move speaker to the right of counter
- mSpeakerCtrl->translate(mCounterCtrl->getRect().getWidth(), 0);
- }
-
- initSpeakerControl();
- }
-
- setRequiredWidth();
- mSpeakerCtrl->setSpeakerId(LLUUID::null);
- mSpeakerCtrl->setVisible(getShowSpeaker());
-}
-
-void LLIMChiclet::setCounter(S32 counter)
-{
- if (mCounterCtrl->getCounter() == counter)
- {
- return;
- }
-
- mCounterCtrl->setCounter(counter);
- setShowCounter(counter);
- setShowNewMessagesIcon(counter);
-}
-
-void LLIMChiclet::toggleCounterControl()
-{
- setRequiredWidth();
- mCounterCtrl->setVisible(getShowCounter());
-}
-
void LLIMChiclet::setShowNewMessagesIcon(bool show)
{
if(mNewMessagesIcon)
@@ -449,7 +149,6 @@ bool LLIMChiclet::getShowNewMessagesIcon()
void LLIMChiclet::onMouseDown()
{
LLFloaterIMSession::toggle(getSessionId());
- setCounter(0);
}
void LLIMChiclet::setToggleState(bool toggle)
@@ -457,52 +156,6 @@ void LLIMChiclet::setToggleState(bool toggle)
mChicletButton->setToggleState(toggle);
}
-void LLIMChiclet::draw()
-{
- LLUICtrl::draw();
-}
-
-// static
-LLIMChiclet::EType LLIMChiclet::getIMSessionType(const LLUUID& session_id)
-{
- EType type = TYPE_UNKNOWN;
-
- if(session_id.isNull())
- return type;
-
- EInstantMessage im_type = LLIMModel::getInstance()->getType(session_id);
- if (IM_COUNT == im_type)
- {
- llassert_always(0 && "IM session not found"); // should never happen
- return type;
- }
-
- switch(im_type)
- {
- case IM_NOTHING_SPECIAL:
- case IM_SESSION_P2P_INVITE:
- type = TYPE_IM;
- break;
- case IM_SESSION_GROUP_START:
- case IM_SESSION_INVITE:
- if (gAgent.isInGroup(session_id))
- {
- type = TYPE_GROUP;
- }
- else
- {
- type = TYPE_AD_HOC;
- }
- break;
- case IM_SESSION_CONFERENCE_START:
- type = TYPE_AD_HOC;
- default:
- break;
- }
-
- return type;
-}
-
BOOL LLIMChiclet::handleRightMouseDown(S32 x, S32 y, MASK mask)
{
if(!mPopupMenu)
@@ -538,382 +191,6 @@ bool LLIMChiclet::canCreateMenu()
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
-LLIMP2PChiclet::Params::Params()
-: avatar_icon("avatar_icon")
-, chiclet_button("chiclet_button")
-, unread_notifications("unread_notifications")
-, speaker("speaker")
-, new_message_icon("new_message_icon")
-, show_speaker("show_speaker")
-{
-}
-
-LLIMP2PChiclet::LLIMP2PChiclet(const Params& p)
-: LLIMChiclet(p)
-, mChicletIconCtrl(NULL)
-{
- LLButton::Params button_params = p.chiclet_button;
- mChicletButton = LLUICtrlFactory::create<LLButton>(button_params);
- addChild(mChicletButton);
-
- LLIconCtrl::Params new_msg_params = p.new_message_icon;
- mNewMessagesIcon = LLUICtrlFactory::create<LLIconCtrl>(new_msg_params);
- addChild(mNewMessagesIcon);
-
- LLChicletAvatarIconCtrl::Params avatar_params = p.avatar_icon;
- mChicletIconCtrl = LLUICtrlFactory::create<LLChicletAvatarIconCtrl>(avatar_params);
- addChild(mChicletIconCtrl);
-
- LLChicletNotificationCounterCtrl::Params unread_params = p.unread_notifications;
- mCounterCtrl = LLUICtrlFactory::create<LLChicletNotificationCounterCtrl>(unread_params);
- addChild(mCounterCtrl);
-
- setCounter(getCounter());
- setShowCounter(getShowCounter());
-
- LLChicletSpeakerCtrl::Params speaker_params = p.speaker;
- mSpeakerCtrl = LLUICtrlFactory::create<LLChicletSpeakerCtrl>(speaker_params);
- addChild(mSpeakerCtrl);
-
- sendChildToFront(mNewMessagesIcon);
- setShowSpeaker(p.show_speaker);
-}
-
-void LLIMP2PChiclet::initSpeakerControl()
-{
- mSpeakerCtrl->setSpeakerId(getOtherParticipantId());
-}
-
-void LLIMP2PChiclet::setOtherParticipantId(const LLUUID& other_participant_id)
-{
- LLIMChiclet::setOtherParticipantId(other_participant_id);
- mChicletIconCtrl->setValue(getOtherParticipantId());
-}
-
-void LLIMP2PChiclet::updateMenuItems()
-{
- if(!mPopupMenu)
- return;
- if(getSessionId().isNull())
- return;
-
- LLFloaterIMSession* open_im_floater = LLFloaterIMSession::findInstance(getSessionId());
- bool open_window_exists = open_im_floater && open_im_floater->getVisible();
- mPopupMenu->getChild<LLUICtrl>("Send IM")->setEnabled(!open_window_exists);
-
- bool is_friend = LLAvatarActions::isFriend(getOtherParticipantId());
- mPopupMenu->getChild<LLUICtrl>("Add Friend")->setEnabled(!is_friend);
-}
-
-void LLIMP2PChiclet::createPopupMenu()
-{
- if(!canCreateMenu())
- return;
-
- LLUICtrl::CommitCallbackRegistry::ScopedRegistrar registrar;
- registrar.add("IMChicletMenu.Action", boost::bind(&LLIMP2PChiclet::onMenuItemClicked, this, _2));
-
- mPopupMenu = LLUICtrlFactory::getInstance()->createFromFile<LLMenuGL>
- ("menu_imchiclet_p2p.xml", gMenuHolder, LLViewerMenuHolderGL::child_registry_t::instance());
-}
-
-void LLIMP2PChiclet::onMenuItemClicked(const LLSD& user_data)
-{
- std::string level = user_data.asString();
- LLUUID other_participant_id = getOtherParticipantId();
-
- if("profile" == level)
- {
- LLAvatarActions::showProfile(other_participant_id);
- }
- else if("im" == level)
- {
- LLAvatarActions::startIM(other_participant_id);
- }
- else if("add" == level)
- {
- LLAvatarActions::requestFriendshipDialog(other_participant_id);
- }
- else if("end" == level)
- {
- LLAvatarActions::endIM(other_participant_id);
- }
-}
-
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-
-LLAdHocChiclet::Params::Params()
-: avatar_icon("avatar_icon")
-, chiclet_button("chiclet_button")
-, unread_notifications("unread_notifications")
-, speaker("speaker")
-, new_message_icon("new_message_icon")
-, show_speaker("show_speaker")
-, avatar_icon_color("avatar_icon_color", LLColor4::green)
-{
-}
-
-LLAdHocChiclet::LLAdHocChiclet(const Params& p)
-: LLIMChiclet(p)
-, mChicletIconCtrl(NULL)
-{
- LLButton::Params button_params = p.chiclet_button;
- mChicletButton = LLUICtrlFactory::create<LLButton>(button_params);
- addChild(mChicletButton);
-
- LLIconCtrl::Params new_msg_params = p.new_message_icon;
- mNewMessagesIcon = LLUICtrlFactory::create<LLIconCtrl>(new_msg_params);
- addChild(mNewMessagesIcon);
-
- LLChicletAvatarIconCtrl::Params avatar_params = p.avatar_icon;
- mChicletIconCtrl = LLUICtrlFactory::create<LLChicletAvatarIconCtrl>(avatar_params);
- //Make the avatar modified
- mChicletIconCtrl->setColor(p.avatar_icon_color);
- addChild(mChicletIconCtrl);
-
- LLChicletNotificationCounterCtrl::Params unread_params = p.unread_notifications;
- mCounterCtrl = LLUICtrlFactory::create<LLChicletNotificationCounterCtrl>(unread_params);
- addChild(mCounterCtrl);
-
- setCounter(getCounter());
- setShowCounter(getShowCounter());
-
- LLChicletSpeakerCtrl::Params speaker_params = p.speaker;
- mSpeakerCtrl = LLUICtrlFactory::create<LLChicletSpeakerCtrl>(speaker_params);
- addChild(mSpeakerCtrl);
-
- sendChildToFront(mNewMessagesIcon);
- setShowSpeaker(p.show_speaker);
-}
-
-void LLAdHocChiclet::setSessionId(const LLUUID& session_id)
-{
- LLChiclet::setSessionId(session_id);
- LLIMModel::LLIMSession* im_session = LLIMModel::getInstance()->findIMSession(session_id);
- mChicletIconCtrl->setValue(im_session->mOtherParticipantID);
-}
-
-void LLAdHocChiclet::draw()
-{
- switchToCurrentSpeaker();
- LLIMChiclet::draw();
-}
-
-void LLAdHocChiclet::initSpeakerControl()
-{
- switchToCurrentSpeaker();
-}
-
-void LLAdHocChiclet::switchToCurrentSpeaker()
-{
- LLUUID speaker_id;
- LLSpeakerMgr::speaker_list_t speaker_list;
-
- LLIMModel::getInstance()->findIMSession(getSessionId())->mSpeakers->getSpeakerList(&speaker_list, FALSE);
- for (LLSpeakerMgr::speaker_list_t::iterator i = speaker_list.begin(); i != speaker_list.end(); ++i)
- {
- LLPointer<LLSpeaker> s = *i;
- if (s->mSpeechVolume > 0 || s->mStatus == LLSpeaker::STATUS_SPEAKING)
- {
- speaker_id = s->mID;
- break;
- }
- }
-
- mSpeakerCtrl->setSpeakerId(speaker_id);
-}
-
-void LLAdHocChiclet::createPopupMenu()
-{
- if(!canCreateMenu())
- return;
-
- LLUICtrl::CommitCallbackRegistry::ScopedRegistrar registrar;
- registrar.add("IMChicletMenu.Action", boost::bind(&LLAdHocChiclet::onMenuItemClicked, this, _2));
-
- mPopupMenu = LLUICtrlFactory::getInstance()->createFromFile<LLMenuGL>
- ("menu_imchiclet_adhoc.xml", gMenuHolder, LLViewerMenuHolderGL::child_registry_t::instance());
-}
-
-void LLAdHocChiclet::onMenuItemClicked(const LLSD& user_data)
-{
- std::string level = user_data.asString();
- LLUUID group_id = getSessionId();
-
- if("end" == level)
- {
- LLGroupActions::endIM(group_id);
- }
-}
-
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-
-LLIMGroupChiclet::Params::Params()
-: group_icon("group_icon")
-, chiclet_button("chiclet_button")
-, unread_notifications("unread_notifications")
-, speaker("speaker")
-, new_message_icon("new_message_icon")
-, show_speaker("show_speaker")
-{
-}
-
-LLIMGroupChiclet::LLIMGroupChiclet(const Params& p)
-: LLIMChiclet(p)
-, LLGroupMgrObserver(LLUUID::null)
-, mChicletIconCtrl(NULL)
-{
- LLButton::Params button_params = p.chiclet_button;
- mChicletButton = LLUICtrlFactory::create<LLButton>(button_params);
- addChild(mChicletButton);
-
- LLIconCtrl::Params new_msg_params = p.new_message_icon;
- mNewMessagesIcon = LLUICtrlFactory::create<LLIconCtrl>(new_msg_params);
- addChild(mNewMessagesIcon);
-
- LLChicletGroupIconCtrl::Params avatar_params = p.group_icon;
- mChicletIconCtrl = LLUICtrlFactory::create<LLChicletGroupIconCtrl>(avatar_params);
- addChild(mChicletIconCtrl);
-
- LLChicletNotificationCounterCtrl::Params unread_params = p.unread_notifications;
- mCounterCtrl = LLUICtrlFactory::create<LLChicletNotificationCounterCtrl>(unread_params);
- addChild(mCounterCtrl);
-
- setCounter(getCounter());
- setShowCounter(getShowCounter());
-
- LLChicletSpeakerCtrl::Params speaker_params = p.speaker;
- mSpeakerCtrl = LLUICtrlFactory::create<LLChicletSpeakerCtrl>(speaker_params);
- addChild(mSpeakerCtrl);
-
- sendChildToFront(mNewMessagesIcon);
- setShowSpeaker(p.show_speaker);
-}
-
-LLIMGroupChiclet::~LLIMGroupChiclet()
-{
- LLGroupMgr::getInstance()->removeObserver(this);
-}
-
-void LLIMGroupChiclet::draw()
-{
- if(getShowSpeaker())
- {
- switchToCurrentSpeaker();
- }
- LLIMChiclet::draw();
-}
-
-void LLIMGroupChiclet::initSpeakerControl()
-{
- switchToCurrentSpeaker();
-}
-
-void LLIMGroupChiclet::switchToCurrentSpeaker()
-{
- LLUUID speaker_id;
- LLSpeakerMgr::speaker_list_t speaker_list;
-
- LLIMModel::getInstance()->findIMSession(getSessionId())->mSpeakers->getSpeakerList(&speaker_list, FALSE);
- for (LLSpeakerMgr::speaker_list_t::iterator i = speaker_list.begin(); i != speaker_list.end(); ++i)
- {
- LLPointer<LLSpeaker> s = *i;
- if (s->mSpeechVolume > 0 || s->mStatus == LLSpeaker::STATUS_SPEAKING)
- {
- speaker_id = s->mID;
- break;
- }
- }
-
- mSpeakerCtrl->setSpeakerId(speaker_id);
-}
-
-void LLIMGroupChiclet::setSessionId(const LLUUID& session_id)
-{
- LLChiclet::setSessionId(session_id);
-
- LLGroupMgr* grp_mgr = LLGroupMgr::getInstance();
- LLGroupMgrGroupData* group_data = grp_mgr->getGroupData(session_id);
- if (group_data && group_data->mInsigniaID.notNull())
- {
- mChicletIconCtrl->setValue(group_data->mInsigniaID);
- }
- else
- {
- if(getSessionId() != mID)
- {
- grp_mgr->removeObserver(this);
- mID = getSessionId();
- grp_mgr->addObserver(this);
- }
- grp_mgr->sendGroupPropertiesRequest(session_id);
- }
-}
-
-void LLIMGroupChiclet::changed(LLGroupChange gc)
-{
- if (GC_PROPERTIES == gc)
- {
- LLGroupMgrGroupData* group_data = LLGroupMgr::getInstance()->getGroupData(getSessionId());
- if (group_data)
- {
- mChicletIconCtrl->setValue(group_data->mInsigniaID);
- }
- }
-}
-
-void LLIMGroupChiclet::updateMenuItems()
-{
- if(!mPopupMenu)
- return;
- if(getSessionId().isNull())
- return;
-
- LLFloaterIMSession* open_im_floater = LLFloaterIMSession::findInstance(getSessionId());
- bool open_window_exists = open_im_floater && open_im_floater->getVisible();
- mPopupMenu->getChild<LLUICtrl>("Chat")->setEnabled(!open_window_exists);
-}
-
-void LLIMGroupChiclet::createPopupMenu()
-{
- if(!canCreateMenu())
- return;
-
- LLUICtrl::CommitCallbackRegistry::ScopedRegistrar registrar;
- registrar.add("IMChicletMenu.Action", boost::bind(&LLIMGroupChiclet::onMenuItemClicked, this, _2));
-
- mPopupMenu = LLUICtrlFactory::getInstance()->createFromFile<LLMenuGL>
- ("menu_imchiclet_group.xml", gMenuHolder, LLViewerMenuHolderGL::child_registry_t::instance());
-}
-
-void LLIMGroupChiclet::onMenuItemClicked(const LLSD& user_data)
-{
- std::string level = user_data.asString();
- LLUUID group_id = getSessionId();
-
- if("group chat" == level)
- {
- LLGroupActions::startIM(group_id);
- }
- else if("info" == level)
- {
- LLGroupActions::show(group_id);
- }
- else if("end" == level)
- {
- LLGroupActions::endIM(group_id);
- }
-}
-
-
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-
LLChicletPanel::Params::Params()
: chiclet_padding("chiclet_padding")
, scrolling_offset("scrolling_offset")
@@ -964,20 +241,6 @@ void LLChicletPanel::onMessageCountChanged(const LLSD& data)
{
unread = 0;
}
-
- std::list<LLChiclet*> chiclets = LLIMChiclet::sFindChicletsSignal(session_id);
- std::list<LLChiclet *>::iterator iter;
- for (iter = chiclets.begin(); iter != chiclets.end(); iter++) {
- LLChiclet* chiclet = *iter;
- if (chiclet != NULL)
- {
- chiclet->setCounter(unread);
- }
- else
- {
- llwarns << "Unable to set counter for chiclet " << session_id << llendl;
- }
- }
}
void LLChicletPanel::objectChicletCallback(const LLSD& data)
@@ -992,10 +255,6 @@ void LLChicletPanel::objectChicletCallback(const LLSD& data)
LLIMChiclet* chiclet = dynamic_cast<LLIMChiclet*>(*iter);
if (chiclet != NULL)
{
- if(data.has("unread"))
- {
- chiclet->setCounter(data["unread"]);
- }
chiclet->setShowNewMessagesIcon(new_message);
}
}
@@ -1037,7 +296,6 @@ void LLChicletPanel::onCurrentVoiceChannelChanged(const LLUUID& session_id)
LLIMChiclet* chiclet = dynamic_cast<LLIMChiclet*>(*it);
if(chiclet)
{
- chiclet->setShowSpeaker(true);
if (gSavedSettings.getBOOL("OpenIMOnVoice"))
{
LLFloaterIMContainer::getInstance()->showConversation(session_id);
@@ -1045,20 +303,6 @@ void LLChicletPanel::onCurrentVoiceChannelChanged(const LLUUID& session_id)
}
}
- 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<LLChiclet *>::iterator it = chiclets.begin(); it != chiclets.end(); ++it)
- {
- LLIMChiclet* chiclet = dynamic_cast<LLIMChiclet*>(*it);
- if(chiclet)
- {
- chiclet->setShowSpeaker(false);
- }
- }
- }
-
s_previous_active_voice_session_id = session_id;
}
@@ -1544,85 +788,6 @@ bool LLChicletPanel::isAnyIMFloaterDoked()
return res;
}
-S32 LLChicletPanel::getTotalUnreadIMCount()
-{
- S32 count = 0;
- chiclet_list_t::const_iterator it = mChicletList.begin();
- for( ; mChicletList.end() != it; ++it)
- {
- LLIMChiclet* chiclet = dynamic_cast<LLIMChiclet*>(*it);
- if(chiclet)
- {
- count += chiclet->getCounter();
- }
- }
- return count;
-}
-
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-LLChicletNotificationCounterCtrl::Params::Params()
-: max_displayed_count("max_displayed_count", 99)
-{
-}
-
-LLChicletNotificationCounterCtrl::LLChicletNotificationCounterCtrl(const Params& p)
- : LLTextBox(p)
- , mCounter(0)
- , mInitialWidth(0)
- , mMaxDisplayedCount(p.max_displayed_count)
-{
- mInitialWidth = getRect().getWidth();
-}
-
-void LLChicletNotificationCounterCtrl::setCounter(S32 counter)
-{
- mCounter = counter;
-
- // note same code in LLSysWellChiclet::setCounter(S32 counter)
- std::string s_count;
- if(counter != 0)
- {
- static std::string more_messages_exist("+");
- std::string more_messages(counter > mMaxDisplayedCount ? more_messages_exist : "");
- s_count = llformat("%d%s"
- , llmin(counter, mMaxDisplayedCount)
- , more_messages.c_str()
- );
- }
-
- if(mCounter != 0)
- {
- setText(s_count);
- }
- else
- {
- setText(std::string(""));
- }
-}
-
-LLRect LLChicletNotificationCounterCtrl::getRequiredRect()
-{
- LLRect rc;
- S32 text_width = getTextPixelWidth();
-
- rc.mRight = rc.mLeft + llmax(text_width, mInitialWidth);
-
- return rc;
-}
-
-void LLChicletNotificationCounterCtrl::setValue(const LLSD& value)
-{
- if(value.isInteger())
- setCounter(value.asInteger());
-}
-
-LLSD LLChicletNotificationCounterCtrl::getValue() const
-{
- return LLSD(getCounter());
-}
-
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
@@ -1632,28 +797,6 @@ LLChicletAvatarIconCtrl::LLChicletAvatarIconCtrl(const Params& p)
{
}
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-
-LLChicletGroupIconCtrl::LLChicletGroupIconCtrl(const Params& p)
-: LLIconCtrl(p)
-, mDefaultIcon(p.default_icon)
-{
- setValue(LLUUID::null);
-}
-
-void LLChicletGroupIconCtrl::setValue(const LLSD& value )
-{
- if(value.asUUID().isNull())
- {
- LLIconCtrl::setValue(mDefaultIcon);
- }
- else
- {
- LLIconCtrl::setValue(value);
- }
-}
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
@@ -1681,15 +824,6 @@ void LLChicletInvOfferIconCtrl::setValue(const LLSD& value )
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
-LLChicletSpeakerCtrl::LLChicletSpeakerCtrl(const Params&p)
- : LLOutputMonitorCtrl(p)
-{
-}
-
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////
-
LLScriptChiclet::Params::Params()
: icon("icon")
, chiclet_button("chiclet_button")
@@ -1725,11 +859,6 @@ void LLScriptChiclet::setSessionId(const LLUUID& session_id)
setToolTip(LLScriptFloaterManager::getObjectName(session_id));
}
-void LLScriptChiclet::setCounter(S32 counter)
-{
- setShowNewMessagesIcon( counter > 0 );
-}
-
void LLScriptChiclet::onMouseDown()
{
LLScriptFloaterManager::getInstance()->toggleScriptFloater(getSessionId());
@@ -1808,11 +937,6 @@ void LLInvOfferChiclet::setSessionId(const LLUUID& session_id)
}
}
-void LLInvOfferChiclet::setCounter(S32 counter)
-{
- setShowNewMessagesIcon( counter > 0 );
-}
-
void LLInvOfferChiclet::onMouseDown()
{
LLScriptFloaterManager::instance().toggleScriptFloater(getSessionId());
diff --git a/indra/newview/llchiclet.h b/indra/newview/llchiclet.h
index 7f72c7f9e2..bd6c1a3e71 100644
--- a/indra/newview/llchiclet.h
+++ b/indra/newview/llchiclet.h
@@ -29,76 +29,11 @@
#include "llavatariconctrl.h"
#include "llbutton.h"
-#include "llflashtimer.h"
-#include "llpanel.h"
-#include "lltextbox.h"
-#include "lloutputmonitorctrl.h"
-#include "llgroupmgr.h"
-#include "llimview.h"
-#include "llnotifications.h"
class LLMenuGL;
class LLFloaterIMSession;
/**
- * Class for displaying amount of messages/notifications(unread).
- */
-class LLChicletNotificationCounterCtrl : public LLTextBox
-{
-public:
-
- struct Params : public LLInitParam::Block<Params, LLTextBox::Params>
- {
- /**
- * Contains maximum displayed count of unread messages. Default value is 9.
- *
- * If count is less than "max_unread_count" will be displayed as is.
- * Otherwise 9+ will be shown (for default value).
- */
- Optional<S32> max_displayed_count;
-
- Params();
- };
-
- /**
- * Sets number of notifications
- */
- virtual void setCounter(S32 counter);
-
- /**
- * Returns number of notifications
- */
- virtual S32 getCounter() const { return mCounter; }
-
- /**
- * Returns width, required to display amount of notifications in text form.
- * Width is the only valid value.
- */
- /*virtual*/ LLRect getRequiredRect();
-
- /**
- * Sets number of notifications using LLSD
- */
- /*virtual*/ void setValue(const LLSD& value);
-
- /**
- * Returns number of notifications wrapped in LLSD
- */
- /*virtual*/ LLSD getValue() const;
-
-protected:
-
- LLChicletNotificationCounterCtrl(const Params& p);
- friend class LLUICtrlFactory;
-
-private:
-
- S32 mCounter;
- S32 mInitialWidth;
- S32 mMaxDisplayedCount;
-};
-
-/**
* Class for displaying avatar's icon in P2P chiclet.
*/
class LLChicletAvatarIconCtrl : public LLAvatarIconCtrl
@@ -122,35 +57,6 @@ protected:
};
/**
- * Class for displaying group's icon in Group chiclet.
- */
-class LLChicletGroupIconCtrl : public LLIconCtrl
-{
-public:
-
- struct Params : public LLInitParam::Block<Params, LLIconCtrl::Params>
- {
- Optional<std::string> default_icon;
-
- Params()
- : default_icon("default_icon", "Generic_Group")
- {}
- };
-
- /**
- * Sets icon, if value is LLUUID::null - default icon will be set.
- */
- virtual void setValue(const LLSD& value );
-
-protected:
-
- LLChicletGroupIconCtrl(const Params& p);
- friend class LLUICtrlFactory;
-
- std::string mDefaultIcon;
-};
-
-/**
* Class for displaying icon in inventory offer chiclet.
*/
class LLChicletInvOfferIconCtrl : public LLChicletAvatarIconCtrl
@@ -184,23 +90,6 @@ private:
};
/**
- * Class for displaying of speaker's voice indicator
- */
-class LLChicletSpeakerCtrl : public LLOutputMonitorCtrl
-{
-public:
-
- struct Params : public LLInitParam::Block<Params, LLOutputMonitorCtrl::Params>
- {
- Params(){};
- };
-protected:
-
- LLChicletSpeakerCtrl(const Params&p);
- friend class LLUICtrlFactory;
-};
-
-/**
* Base class for all chiclets.
*/
class LLChiclet : public LLUICtrl
@@ -228,26 +117,6 @@ public:
virtual const LLUUID& getSessionId() const { return mSessionId; }
/**
- * Sets number of unread notifications.
- */
- virtual void setCounter(S32 counter) = 0;
-
- /**
- * Returns number of unread notifications.
- */
- virtual S32 getCounter() = 0;
-
- /**
- * Sets show counter state.
- */
- virtual void setShowCounter(bool show) { mShowCounter = show; }
-
- /**
- * Returns show counter state.
- */
- virtual bool getShowCounter() {return mShowCounter;};
-
- /**
* Connects chiclet clicked event with callback.
*/
/*virtual*/ boost::signals2::connection setLeftButtonClickCallback(
@@ -324,62 +193,6 @@ public:
* It is used for default setting up of chicklet:click handler, etc.
*/
BOOL postBuild();
- /**
- * Sets IM session name. This name will be displayed in chiclet tooltip.
- */
- virtual void setIMSessionName(const std::string& name) { setToolTip(name); }
-
- /**
- * Sets id of person/group user is chatting with.
- * Session id should be set before calling this
- */
- virtual void setOtherParticipantId(const LLUUID& other_participant_id) { mOtherParticipantId = other_participant_id; }
-
- /**
- * Gets id of person/group user is chatting with.
- */
- virtual LLUUID getOtherParticipantId() { return mOtherParticipantId; }
-
- /**
- * Init Speaker Control with speaker's ID
- */
- virtual void initSpeakerControl();
-
- /**
- * set status (Shows/Hide) for voice control.
- */
- virtual void setShowSpeaker(bool show);
-
- /**
- * Returns voice chat status control visibility.
- */
- virtual bool getShowSpeaker() {return mShowSpeaker;};
-
- /**
- * Shows/Hides for voice control for a chiclet.
- */
- virtual void toggleSpeakerControl();
-
- /**
- * Sets number of unread messages. Will update chiclet's width if number text
- * exceeds size of counter and notify it's parent about size change.
- */
- virtual void setCounter(S32);
-
- /**
- * Enables/disables the counter control for a chiclet.
- */
- virtual void enableCounterControl(bool enable);
-
- /**
- * Sets show counter state.
- */
- virtual void setShowCounter(bool show);
-
- /**
- * Shows/Hides for counter control for a chiclet.
- */
- virtual void toggleCounterControl();
/**
* Sets required width for a chiclet according to visible controls.
@@ -396,21 +209,6 @@ public:
*/
virtual bool getShowNewMessagesIcon();
- virtual void draw();
-
- /**
- * Determine whether given ID refers to a group or an IM chat session.
- *
- * This is used when we need to chose what IM chiclet (P2P/group)
- * class to instantiate.
- *
- * @param session_id session ID.
- * @return TYPE_GROUP in case of group chat session,
- * TYPE_IM in case of P2P session,
- * TYPE_UNKNOWN otherwise.
- */
- static EType getIMSessionType(const LLUUID& session_id);
-
/**
* The action taken on mouse down event.
*
@@ -452,8 +250,6 @@ protected:
S32 mDefaultWidth;
LLIconCtrl* mNewMessagesIcon;
- LLChicletNotificationCounterCtrl* mCounterCtrl;
- LLChicletSpeakerCtrl* mSpeakerCtrl;
LLButton* mChicletButton;
/** the id of another participant, either an avatar id or a group id*/
@@ -481,137 +277,6 @@ public:
sFindChicletsSignal;
};
-/**
- * Implements P2P chiclet.
- */
-class LLIMP2PChiclet : public LLIMChiclet
-{
-public:
- struct Params : public LLInitParam::Block<Params, LLIMChiclet::Params>
- {
- Optional<LLButton::Params> chiclet_button;
-
- Optional<LLChicletAvatarIconCtrl::Params> avatar_icon;
-
- Optional<LLChicletNotificationCounterCtrl::Params> unread_notifications;
-
- Optional<LLChicletSpeakerCtrl::Params> speaker;
-
- Optional<LLIconCtrl::Params> new_message_icon;
-
- Optional<bool> show_speaker;
-
- Params();
- };
-
- /* virtual */ void setOtherParticipantId(const LLUUID& other_participant_id);
-
- /**
- * Init Speaker Control with speaker's ID
- */
- /*virtual*/ void initSpeakerControl();
-
- /**
- * Returns number of unread messages.
- */
- /*virtual*/ S32 getCounter() { return mCounterCtrl->getCounter(); }
-
-protected:
- LLIMP2PChiclet(const Params& p);
- friend class LLUICtrlFactory;
-
- /**
- * Creates chiclet popup menu. Will create P2P or Group IM Chat menu
- * based on other participant's id.
- */
- virtual void createPopupMenu();
-
- /**
- * Processes clicks on chiclet popup menu.
- */
- virtual void onMenuItemClicked(const LLSD& user_data);
-
- /**
- * Enables/disables menus based on relationship with other participant.
- * Enables/disables "show session" menu item depending on visible IM floater existence.
- */
- virtual void updateMenuItems();
-
-private:
-
- LLChicletAvatarIconCtrl* mChicletIconCtrl;
-};
-
-/**
- * Implements AD-HOC chiclet.
- */
-class LLAdHocChiclet : public LLIMChiclet
-{
-public:
- struct Params : public LLInitParam::Block<Params, LLIMChiclet::Params>
- {
- Optional<LLButton::Params> chiclet_button;
-
- Optional<LLChicletAvatarIconCtrl::Params> avatar_icon;
-
- Optional<LLChicletNotificationCounterCtrl::Params> unread_notifications;
-
- Optional<LLChicletSpeakerCtrl::Params> speaker;
-
- Optional<LLIconCtrl::Params> new_message_icon;
-
- Optional<bool> show_speaker;
-
- Optional<LLColor4> avatar_icon_color;
-
- Params();
- };
-
- /**
- * Sets session id.
- * Session ID for group chat is actually Group ID.
- */
- /*virtual*/ void setSessionId(const LLUUID& session_id);
-
- /**
- * Keep Speaker Control with actual speaker's ID
- */
- /*virtual*/ void draw();
-
- /**
- * Init Speaker Control with speaker's ID
- */
- /*virtual*/ void initSpeakerControl();
-
- /**
- * Returns number of unread messages.
- */
- /*virtual*/ S32 getCounter() { return mCounterCtrl->getCounter(); }
-
-protected:
- LLAdHocChiclet(const Params& p);
- friend class LLUICtrlFactory;
-
- /**
- * Creates chiclet popup menu. Will create AdHoc Chat menu
- * based on other participant's id.
- */
- virtual void createPopupMenu();
-
- /**
- * Processes clicks on chiclet popup menu.
- */
- virtual void onMenuItemClicked(const LLSD& user_data);
-
- /**
- * Finds a current speaker and resets the SpeakerControl with speaker's ID
- */
- /*virtual*/ void switchToCurrentSpeaker();
-
-private:
-
- LLChicletAvatarIconCtrl* mChicletIconCtrl;
-};
/**
* Chiclet for script floaters.
@@ -633,10 +298,6 @@ public:
/*virtual*/ void setSessionId(const LLUUID& session_id);
- /*virtual*/ void setCounter(S32 counter);
-
- /*virtual*/ S32 getCounter() { return 0; }
-
/**
* Toggle script floater
*/
@@ -682,10 +343,6 @@ public:
/*virtual*/ void setSessionId(const LLUUID& session_id);
- /*virtual*/ void setCounter(S32 counter);
-
- /*virtual*/ S32 getCounter() { return 0; }
-
/**
* Toggle script floater
*/
@@ -710,214 +367,6 @@ private:
};
/**
- * Implements Group chat chiclet.
- */
-class LLIMGroupChiclet : public LLIMChiclet, public LLGroupMgrObserver
-{
-public:
-
- struct Params : public LLInitParam::Block<Params, LLIMChiclet::Params>
- {
- Optional<LLButton::Params> chiclet_button;
-
- Optional<LLChicletGroupIconCtrl::Params> group_icon;
-
- Optional<LLChicletNotificationCounterCtrl::Params> unread_notifications;
-
- Optional<LLChicletSpeakerCtrl::Params> speaker;
-
- Optional<LLIconCtrl::Params> new_message_icon;
-
- Optional<bool> show_speaker;
-
- Params();
- };
-
- /**
- * Sets session id.
- * Session ID for group chat is actually Group ID.
- */
- /*virtual*/ void setSessionId(const LLUUID& session_id);
-
- /**
- * Keep Speaker Control with actual speaker's ID
- */
- /*virtual*/ void draw();
-
- /**
- * Callback for LLGroupMgrObserver, we get this when group data is available or changed.
- * Sets group icon.
- */
- /*virtual*/ void changed(LLGroupChange gc);
-
- /**
- * Init Speaker Control with speaker's ID
- */
- /*virtual*/ void initSpeakerControl();
-
- /**
- * Returns number of unread messages.
- */
- /*virtual*/ S32 getCounter() { return mCounterCtrl->getCounter(); }
-
- ~LLIMGroupChiclet();
-
-protected:
- LLIMGroupChiclet(const Params& p);
- friend class LLUICtrlFactory;
-
- /**
- * Finds a current speaker and resets the SpeakerControl with speaker's ID
- */
- /*virtual*/ void switchToCurrentSpeaker();
-
- /**
- * Creates chiclet popup menu. Will create P2P or Group IM Chat menu
- * based on other participant's id.
- */
- virtual void createPopupMenu();
-
- /**
- * Processes clicks on chiclet popup menu.
- */
- virtual void onMenuItemClicked(const LLSD& user_data);
-
- /**
- * Enables/disables "show session" menu item depending on visible IM floater existence.
- */
- virtual void updateMenuItems();
-
-private:
-
- LLChicletGroupIconCtrl* mChicletIconCtrl;
-};
-
-/**
- * Implements notification chiclet. Used to display total amount of unread messages
- * across all IM sessions, total amount of system notifications. See EXT-3147 for details
- */
-class LLSysWellChiclet : public LLChiclet
-{
-public:
-
- struct Params : public LLInitParam::Block<Params, LLChiclet::Params>
- {
- Optional<LLButton::Params> button;
-
- Optional<LLChicletNotificationCounterCtrl::Params> unread_notifications;
-
- /**
- * Contains maximum displayed count of unread messages. Default value is 9.
- *
- * If count is less than "max_unread_count" will be displayed as is.
- * Otherwise 9+ will be shown (for default value).
- */
- Optional<S32> max_displayed_count;
-
- Params();
- };
-
- /*virtual*/ void setCounter(S32 counter);
-
- // *TODO: mantipov: seems getCounter is not necessary for LLNotificationChiclet
- // but inherited interface requires it to implement.
- // Probably it can be safe removed.
- /*virtual*/S32 getCounter() { return mCounter; }
-
- boost::signals2::connection setClickCallback(const commit_callback_t& cb);
-
- /*virtual*/ ~LLSysWellChiclet();
-
- void setToggleState(BOOL toggled);
-
- void setNewMessagesState(bool new_messages);
- //this method should change a widget according to state of the SysWellWindow
- virtual void updateWidget(bool is_window_empty);
-
-protected:
-
- LLSysWellChiclet(const Params& p);
- friend class LLUICtrlFactory;
-
- /**
- * Change Well 'Lit' state from 'Lit' to 'Unlit' and vice-versa.
- *
- * There is an assumption that it will be called 2*N times to do not change its start state.
- * @see FlashToLitTimer
- */
- void changeLitState(bool blink);
-
- /**
- * Displays menu.
- */
- virtual BOOL handleRightMouseDown(S32 x, S32 y, MASK mask);
-
- virtual void createMenu() = 0;
-
-protected:
- class FlashToLitTimer;
- LLButton* mButton;
- S32 mCounter;
- S32 mMaxDisplayedCount;
- bool mIsNewMessagesState;
-
- LLFlashTimer* mFlashToLitTimer;
- LLContextMenu* mContextMenu;
-};
-
-class LLNotificationChiclet : public LLSysWellChiclet
-{
- LOG_CLASS(LLNotificationChiclet);
-
- friend class LLUICtrlFactory;
-public:
- struct Params : public LLInitParam::Block<Params, LLSysWellChiclet::Params>{};
-
-protected:
- struct ChicletNotificationChannel : public LLNotificationChannel
- {
- ChicletNotificationChannel(LLNotificationChiclet* chiclet)
- : LLNotificationChannel(LLNotificationChannel::Params().filter(filterNotification).name(chiclet->getSessionId().asString())),
- mChiclet(chiclet)
- {
- // connect counter handlers to the signals
- connectToChannel("Group Notifications");
- connectToChannel("Offer");
- connectToChannel("Notifications");
- }
-
- static bool filterNotification(LLNotificationPtr notify);
- // connect counter updaters to the corresponding signals
- /*virtual*/ void onAdd(LLNotificationPtr p) { mChiclet->setCounter(++mChiclet->mUreadSystemNotifications); }
- /*virtual*/ void onDelete(LLNotificationPtr p) { mChiclet->setCounter(--mChiclet->mUreadSystemNotifications); }
-
- LLNotificationChiclet* const mChiclet;
- };
-
- boost::scoped_ptr<ChicletNotificationChannel> mNotificationChannel;
-
- LLNotificationChiclet(const Params& p);
-
- /**
- * Processes clicks on chiclet menu.
- */
- void onMenuItemClicked(const LLSD& user_data);
-
- /**
- * Enables chiclet menu items.
- */
- bool enableMenuItem(const LLSD& user_data);
-
- /**
- * Creates menu.
- */
- /*virtual*/ void createMenu();
-
- /*virtual*/ void setCounter(S32 counter);
- S32 mUreadSystemNotifications;
-};
-
-/**
* Storage class for all IM chiclets. Provides mechanism to display,
* scroll, create, remove chiclets.
*/
@@ -1018,9 +467,7 @@ public:
S32 getMinWidth() const { return mMinWidth; }
- S32 getTotalUnreadIMCount();
-
- S32 notifyParent(const LLSD& info);
+ /*virtual*/ S32 notifyParent(const LLSD& info);
/**
* Toggle chiclet by session id ON and toggle OFF all other chiclets.
diff --git a/indra/newview/llchicletbar.cpp b/indra/newview/llchicletbar.cpp
index cfcde64e7b..fde7764129 100644
--- a/indra/newview/llchicletbar.cpp
+++ b/indra/newview/llchicletbar.cpp
@@ -25,18 +25,11 @@
*/
#include "llviewerprecompiledheaders.h" // must be first include
-
#include "llchicletbar.h"
-// library includes
-#include "llfloaterreg.h"
-#include "lllayoutstack.h"
-
-// newview includes
#include "llchiclet.h"
-#include "llfloaterimsession.h" // for LLFloaterIMSession
+#include "lllayoutstack.h"
#include "llpaneltopinfobar.h"
-#include "llsyswellwindow.h"
namespace
{
@@ -60,106 +53,11 @@ LLChicletBar::LLChicletBar(const LLSD&)
buildFromFile("panel_chiclet_bar.xml");
}
-LLChicletBar::~LLChicletBar()
-{
-}
-
-LLIMChiclet* LLChicletBar::createIMChiclet(const LLUUID& session_id)
-{
- LLIMChiclet::EType im_chiclet_type = LLIMChiclet::getIMSessionType(session_id);
-
- switch (im_chiclet_type)
- {
- case LLIMChiclet::TYPE_IM:
- return getChicletPanel()->createChiclet<LLIMP2PChiclet>(session_id);
- case LLIMChiclet::TYPE_GROUP:
- return getChicletPanel()->createChiclet<LLIMGroupChiclet>(session_id);
- case LLIMChiclet::TYPE_AD_HOC:
- return getChicletPanel()->createChiclet<LLAdHocChiclet>(session_id);
- case LLIMChiclet::TYPE_UNKNOWN:
- break;
- }
-
- return NULL;
-}
-
-//virtual
-void LLChicletBar::sessionAdded(const LLUUID& session_id, const std::string& name, const LLUUID& other_participant_id, BOOL has_offline_msg)
-{
- if (!getChicletPanel()) return;
-
- LLIMModel::LLIMSession* session = LLIMModel::getInstance()->findIMSession(session_id);
- if (!session) return;
-
- // no need to spawn chiclets for participants in P2P calls called through Avaline
- if (session->isP2P() && session->isOtherParticipantAvaline()) return;
-
- // Do not spawn chiclet when using the new multitab conversation UI
- if (LLFloaterIMSessionTab::isChatMultiTab())
- {
- LLFloaterIMSessionTab::addToHost(session_id);
- return;
- }
-
- if (getChicletPanel()->findChiclet<LLChiclet>(session_id)) return;
-
- LLIMChiclet* chiclet = createIMChiclet(session_id);
- if(chiclet)
- {
- chiclet->setIMSessionName(name);
- chiclet->setOtherParticipantId(other_participant_id);
-
- LLFloaterIMSession::onIMChicletCreated(session_id);
-
- }
- else
- {
- llwarns << "Could not create chiclet" << llendl;
- }
-}
-
-//virtual
-void LLChicletBar::sessionRemoved(const LLUUID& session_id)
-{
- if(getChicletPanel())
- {
- // IM floater should be closed when session removed and associated chiclet closed
- LLFloaterIMSession* im_floater = LLFloaterReg::findTypedInstance<LLFloaterIMSession>("impanel", session_id);
- if (im_floater != NULL && !im_floater->getStartConferenceInSameFloater())
- {
- // Close the IM floater only if we are not planning to close the P2P chat
- // and start a new conference in the same floater.
- im_floater->closeFloater();
- }
-
- getChicletPanel()->removeChiclet(session_id);
- }
-}
-
-void LLChicletBar::sessionIDUpdated(const LLUUID& old_session_id, const LLUUID& new_session_id)
-{
- //this is only needed in case of outgoing ad-hoc/group chat sessions
- LLChicletPanel* chiclet_panel = getChicletPanel();
- if (chiclet_panel)
- {
- //it should be ad-hoc im chiclet or group im chiclet
- LLChiclet* chiclet = chiclet_panel->findChiclet<LLChiclet>(old_session_id);
- if (chiclet) chiclet->setSessionId(new_session_id);
- }
-}
-
-S32 LLChicletBar::getTotalUnreadIMCount()
-{
- return getChicletPanel()->getTotalUnreadIMCount();
-}
-
BOOL LLChicletBar::postBuild()
{
mToolbarStack = getChild<LLLayoutStack>("toolbar_stack");
mChicletPanel = getChild<LLChicletPanel>("chiclet_list");
- showWellButton("notification_well", !LLNotificationWellWindow::getInstance()->isWindowEmpty());
-
LLPanelTopInfoBar::instance().setResizeCallback(boost::bind(&LLChicletBar::fitWithTopInfoBar, this));
LLPanelTopInfoBar::instance().setVisibleCallback(boost::bind(&LLChicletBar::fitWithTopInfoBar, this));
diff --git a/indra/newview/llchicletbar.h b/indra/newview/llchicletbar.h
index dc991ca772..956c82cb77 100644
--- a/indra/newview/llchicletbar.h
+++ b/indra/newview/llchicletbar.h
@@ -28,7 +28,6 @@
#define LL_LLCHICLETBAR_H
#include "llpanel.h"
-#include "llimview.h"
class LLChicletPanel;
class LLIMChiclet;
@@ -38,32 +37,17 @@ class LLLayoutStack;
class LLChicletBar
: public LLSingleton<LLChicletBar>
, public LLPanel
- , public LLIMSessionObserver
{
LOG_CLASS(LLChicletBar);
friend class LLSingleton<LLChicletBar>;
public:
- ~LLChicletBar();
BOOL postBuild();
LLChicletPanel* getChicletPanel() { return mChicletPanel; }
- // LLIMSessionObserver observe triggers
- /*virtual*/ void sessionAdded(const LLUUID& session_id, const std::string& name, const LLUUID& other_participant_id, BOOL has_offline_msg);
- /*virtual*/ void sessionActivated(const LLUUID& session_id, const std::string& name, const LLUUID& other_participant_id) {};
- /*virtual*/ void sessionVoiceOrIMStarted(const LLUUID& session_id) {};
- /*virtual*/ void sessionRemoved(const LLUUID& session_id);
- /*virtual*/ void sessionIDUpdated(const LLUUID& old_session_id, const LLUUID& new_session_id);
-
- S32 getTotalUnreadIMCount();
-
/*virtual*/ void reshape(S32 width, S32 height, BOOL called_from_parent);
- /**
- * Creates IM Chiclet based on session type (IM chat or Group chat)
- */
- LLIMChiclet* createIMChiclet(const LLUUID& session_id);
/**
* Shows/hides panel with specified well button (IM or Notification)
diff --git a/indra/newview/llconversationmodel.cpp b/indra/newview/llconversationmodel.cpp
index 76c422f34d..1f6022decb 100644
--- a/indra/newview/llconversationmodel.cpp
+++ b/indra/newview/llconversationmodel.cpp
@@ -115,6 +115,7 @@ void LLConversationItem::buildParticipantMenuOptions(menuentry_vec_t& items)
items.push_back(std::string("share"));
items.push_back(std::string("pay"));
items.push_back(std::string("block_unblock"));
+ items.push_back(std::string("MuteText"));
if(this->getType() != CONV_SESSION_1_ON_1)
{
@@ -528,12 +529,8 @@ bool LLConversationSort::operator()(const LLConversationItem* const& a, const LL
{
// If both are sessions
U32 sort_order = getSortOrderSessions();
- if ((type_a == LLConversationItem::CONV_SESSION_NEARBY) || (type_b == LLConversationItem::CONV_SESSION_NEARBY))
- {
- // If one is the nearby session, put nearby session *always* first
- return (type_a == LLConversationItem::CONV_SESSION_NEARBY);
- }
- else if (sort_order == LLConversationFilter::SO_DATE)
+
+ if (sort_order == LLConversationFilter::SO_DATE)
{
// Sort by time
F64 time_a = 0.0;
@@ -552,14 +549,22 @@ bool LLConversationSort::operator()(const LLConversationItem* const& a, const LL
}
// If no time available, we'll default to sort by name at the end of this method
}
- else if (sort_order == LLConversationFilter::SO_SESSION_TYPE)
+ else
{
- if (type_a != type_b)
+ if ((type_a == LLConversationItem::CONV_SESSION_NEARBY) || (type_b == LLConversationItem::CONV_SESSION_NEARBY))
{
- // Lowest types come first. See LLConversationItem definition of types
- return (type_a < type_b);
+ // If one is the nearby session, put nearby session *always* last
+ return (type_b == LLConversationItem::CONV_SESSION_NEARBY);
}
+ else if (sort_order == LLConversationFilter::SO_SESSION_TYPE)
+ {
+ if (type_a != type_b)
+ {
+ // Lowest types come first. See LLConversationItem definition of types
+ return (type_a < type_b);
+ }
// If types are identical, we'll default to sort by name at the end of this method
+ }
}
}
else
diff --git a/indra/newview/llconversationview.cpp b/indra/newview/llconversationview.cpp
index 1b1d61e6d6..b964cee09f 100755
--- a/indra/newview/llconversationview.cpp
+++ b/indra/newview/llconversationview.cpp
@@ -95,7 +95,7 @@ LLConversationViewSession::~LLConversationViewSession()
LLVoiceClient::getInstance()->removeObserver(mVoiceClientObserver);
}
- delete mFlashTimer;
+ mFlashTimer->unset();
}
bool LLConversationViewSession::isHighlightAllowed()
@@ -218,9 +218,15 @@ BOOL LLConversationViewSession::handleMouseDown( S32 x, S32 y, MASK mask )
{
LLConversationItem* item = dynamic_cast<LLConversationItem *>(getViewModelItem());
LLUUID session_id = item? item->getUUID() : LLUUID();
+ //Will try to select a child node and then itself (if a child was not selected)
BOOL result = LLFolderViewFolder::handleMouseDown(x, y, mask);
- (LLFloaterReg::getTypedInstance<LLFloaterIMContainer>("im_container"))->
- selectConversationPair(session_id, false);
+
+ //This node (conversation) was selected and a child (participant) was not
+ if(result && getRoot()->getCurSelectedItem() == this)
+ {
+ (LLFloaterReg::getTypedInstance<LLFloaterIMContainer>("im_container"))->
+ selectConversationPair(session_id, false);
+ }
return result;
}
@@ -448,6 +454,7 @@ void LLConversationViewParticipant::draw()
drawHighlight(show_context, mIsSelected, sHighlightBgColor, sFocusOutlineColor, sMouseOverColor);
drawLabel(font, text_left, y, color, right_x);
+ refresh();
LLView::draw();
}
@@ -548,8 +555,12 @@ BOOL LLConversationViewParticipant::handleMouseDown( S32 x, S32 y, MASK mask )
}
LLUUID session_id = item? item->getUUID() : LLUUID();
BOOL result = LLFolderViewItem::handleMouseDown(x, y, mask);
- (LLFloaterReg::getTypedInstance<LLFloaterIMContainer>("im_container"))->
- selectConversationPair(session_id, false);
+
+ if(result)
+ {
+ (LLFloaterReg::getTypedInstance<LLFloaterIMContainer>("im_container"))->
+ selectConversationPair(session_id, false);
+ }
return result;
}
diff --git a/indra/newview/llfloaterimcontainer.cpp b/indra/newview/llfloaterimcontainer.cpp
index a04b8d79d6..23c21d5309 100644
--- a/indra/newview/llfloaterimcontainer.cpp
+++ b/indra/newview/llfloaterimcontainer.cpp
@@ -516,13 +516,32 @@ void LLFloaterIMContainer::tabClose()
}
}
+//Shows/hides the stub panel when a conversation floater is torn off
void LLFloaterIMContainer::showStub(bool stub_is_visible)
{
- if (stub_is_visible)
- {
- mTabContainer->hideAllTabs();
- }
+ S32 tabCount = 0;
+ LLPanel * tabPanel = NULL;
+
+ if(stub_is_visible)
+ {
+ tabCount = mTabContainer->getTabCount();
+
+ //Hide all tabs even stub
+ for(S32 i = 0; i < tabCount; ++i)
+ {
+ tabPanel = mTabContainer->getPanelByIndex(i);
+
+ if(tabPanel)
+ {
+ tabPanel->setVisible(false);
+ }
+ }
+ //Set the index to the stub panel since we will be showing the stub
+ mTabContainer->setCurrentPanelIndex(0);
+ }
+
+ //Now show/hide the stub
mStubPanel->setVisible(stub_is_visible);
}
@@ -546,8 +565,10 @@ void LLFloaterIMContainer::setVisible(BOOL visible)
// *TODO: find a way to move this to XML as a default panel or something like that
LLSD name("nearby_chat");
LLFloaterReg::toggleInstanceOrBringToFront(name);
+ setSelectedSession(LLUUID(NULL));
}
openNearbyChat();
+ selectConversationPair(getSelectedSession(), false);
}
nearby_chat = LLFloaterReg::findTypedInstance<LLFloaterIMNearbyChat>("nearby_chat");
@@ -571,7 +592,6 @@ void LLFloaterIMContainer::setVisible(BOOL visible)
// Now, do the normal multifloater show/hide
LLMultiFloater::setVisible(visible);
-
}
void LLFloaterIMContainer::collapseMessagesPane(bool collapse)
@@ -925,7 +945,11 @@ void LLFloaterIMContainer::doToParticipants(const std::string& command, uuid_vec
}
else if ("block_unblock" == command)
{
- LLAvatarActions::toggleBlock(userID);
+ toggleMute(userID, LLMute::flagVoiceChat);
+ }
+ else if ("mute_unmute" == command)
+ {
+ toggleMute(userID, LLMute::flagTextChat);
}
else if ("selected" == command || "mute_all" == command || "unmute_all" == command)
{
@@ -1143,8 +1167,12 @@ bool LLFloaterIMContainer::checkContextMenuItem(const std::string& item, uuid_ve
{
if ("is_blocked" == item)
{
- return LLAvatarActions::isBlocked(uuids.front());
+ return LLMuteList::getInstance()->isMuted(uuids.front(), LLMute::flagVoiceChat);
}
+ else if (item == "is_muted")
+ {
+ return LLMuteList::getInstance()->isMuted(uuids.front(), LLMute::flagTextChat);
+ }
else if ("is_allowed_text_chat" == item)
{
const LLSpeaker * speakerp = getSpeakerOfSelectedParticipant(getSpeakerMgrForSelectedParticipant());
@@ -1162,24 +1190,19 @@ bool LLFloaterIMContainer::checkContextMenuItem(const std::string& item, uuid_ve
void LLFloaterIMContainer::showConversation(const LLUUID& session_id)
{
setVisibleAndFrontmost(false);
- selectConversation(session_id);
+ selectConversationPair(session_id, true);
}
-// Will select only the conversation item
void LLFloaterIMContainer::selectConversation(const LLUUID& session_id)
{
- LLFolderViewItem* widget = get_ptr_in_map(mConversationsWidgets,session_id);
- if (widget)
- {
- (widget->getRoot())->setSelection(widget, FALSE, FALSE);
+ selectConversationPair(session_id, true);
}
-}
-
// Synchronous select the conversation item and the conversation floater
BOOL LLFloaterIMContainer::selectConversationPair(const LLUUID& session_id, bool select_widget)
{
BOOL handled = TRUE;
+ LLFloaterIMSessionTab* session_floater = LLFloaterIMSessionTab::getConversation(session_id);
/* widget processing */
if (select_widget)
@@ -1198,7 +1221,7 @@ BOOL LLFloaterIMContainer::selectConversationPair(const LLUUID& session_id, bool
// Store the active session
setSelectedSession(session_id);
- LLFloaterIMSessionTab* session_floater = LLFloaterIMSessionTab::getConversation(session_id);
+
if (session_floater->getHost())
{
@@ -1207,13 +1230,13 @@ BOOL LLFloaterIMContainer::selectConversationPair(const LLUUID& session_id, bool
// Switch to the conversation floater that is being selected
selectFloater(session_floater);
}
+ }
// Set the focus on the selected floater
if (!session_floater->hasFocus())
{
session_floater->setFocus(TRUE);
}
- }
return handled;
}
@@ -1595,6 +1618,23 @@ void LLFloaterIMContainer::toggleAllowTextChat(const LLUUID& participant_uuid)
}
}
+void LLFloaterIMContainer::toggleMute(const LLUUID& participant_id, U32 flags)
+{
+ BOOL is_muted = LLMuteList::getInstance()->isMuted(participant_id, flags);
+ std::string name;
+ gCacheName->getFullName(participant_id, name);
+ LLMute mute(participant_id, name, LLMute::AGENT);
+
+ if (!is_muted)
+ {
+ LLMuteList::getInstance()->add(mute, flags);
+ }
+ else
+ {
+ LLMuteList::getInstance()->remove(mute, flags);
+ }
+}
+
void LLFloaterIMContainer::openNearbyChat()
{
// If there's only one conversation in the container and that conversation is the nearby chat
@@ -1604,6 +1644,7 @@ void LLFloaterIMContainer::openNearbyChat()
LLConversationViewSession* nearby_chat = dynamic_cast<LLConversationViewSession*>(get_ptr_in_map(mConversationsWidgets,LLUUID()));
if (nearby_chat)
{
+ selectConversation(LLUUID());
nearby_chat->setOpen(TRUE);
}
}
@@ -1627,13 +1668,17 @@ void LLFloaterIMContainer::reSelectConversation()
void LLFloaterIMContainer::flashConversationItemWidget(const LLUUID& session_id, bool is_flashes)
{
+ //Finds the conversation line item to flash using the session_id
LLConversationViewSession * widget = dynamic_cast<LLConversationViewSession *>(get_ptr_in_map(mConversationsWidgets,session_id));
+
if (widget)
{
+ //Start flash
if (is_flashes)
{
- widget->getFlashTimer()->startFlashing();
+ widget->getFlashTimer()->startFlashing();
}
+ //Stop flash
else
{
widget->getFlashTimer()->stopFlashing();
diff --git a/indra/newview/llfloaterimcontainer.h b/indra/newview/llfloaterimcontainer.h
index 1badce0d2d..c9987bffe8 100644
--- a/indra/newview/llfloaterimcontainer.h
+++ b/indra/newview/llfloaterimcontainer.h
@@ -150,6 +150,7 @@ private:
void moderateVoiceAllParticipants(bool unmute);
void moderateVoiceParticipant(const LLUUID& avatar_id, bool unmute);
void toggleAllowTextChat(const LLUUID& participant_uuid);
+ void toggleMute(const LLUUID& participant_id, U32 flags);
void openNearbyChat();
LLButton* mExpandCollapseBtn;
diff --git a/indra/newview/llfloaterimnearbychat.cpp b/indra/newview/llfloaterimnearbychat.cpp
index 24b0355fca..a9a3611970 100644
--- a/indra/newview/llfloaterimnearbychat.cpp
+++ b/indra/newview/llfloaterimnearbychat.cpp
@@ -228,7 +228,6 @@ void LLFloaterIMNearbyChat::setVisible(BOOL visible)
{
removeScreenChat();
}
- setFocus(visible);
}
// virtual
diff --git a/indra/newview/llfloaterimnearbychathandler.cpp b/indra/newview/llfloaterimnearbychathandler.cpp
index d9c461e836..903c903381 100644
--- a/indra/newview/llfloaterimnearbychathandler.cpp
+++ b/indra/newview/llfloaterimnearbychathandler.cpp
@@ -619,11 +619,6 @@ void LLFloaterIMNearbyChatHandler::processChat(const LLChat& chat_msg,
chat["message"] = toast_msg;
channel->addChat(chat);
}
- //Will show Conversations floater when chat preference is set
- else if(gSavedSettings.getString("NotificationNearbyChatOptions") == "openconversations")
- {
- LLFloaterReg::showInstance("im_container");
- }
}
}
diff --git a/indra/newview/llfloaterimsession.cpp b/indra/newview/llfloaterimsession.cpp
index 212b0df712..3001029968 100644
--- a/indra/newview/llfloaterimsession.cpp
+++ b/indra/newview/llfloaterimsession.cpp
@@ -616,10 +616,14 @@ void LLFloaterIMSession::setVisible(BOOL visible)
if(!visible)
{
- LLIMChiclet* chiclet = LLChicletBar::getInstance()->getChicletPanel()->findChiclet<LLIMChiclet>(mSessionID);
- if(chiclet)
+ LLChicletPanel * chiclet_panelp = LLChicletBar::getInstance()->getChicletPanel();
+ if (NULL != chiclet_panelp)
{
- chiclet->setToggleState(false);
+ LLIMChiclet * chicletp = chiclet_panelp->findChiclet<LLIMChiclet>(mSessionID);
+ if(NULL != chicletp)
+ {
+ chicletp->setToggleState(false);
+ }
}
}
@@ -629,7 +633,6 @@ void LLFloaterIMSession::setVisible(BOOL visible)
}
- setFocus(visible);
}
BOOL LLFloaterIMSession::getVisible()
diff --git a/indra/newview/llfloaterimsessiontab.cpp b/indra/newview/llfloaterimsessiontab.cpp
index d43381041b..da25f95ffe 100644
--- a/indra/newview/llfloaterimsessiontab.cpp
+++ b/indra/newview/llfloaterimsessiontab.cpp
@@ -60,6 +60,7 @@ LLFloaterIMSessionTab::LLFloaterIMSessionTab(const LLSD& session_id)
, mRefreshTimer(new LLTimer())
, mIsHostAttached(false)
{
+ setAutoFocus(FALSE);
mSession = LLIMModel::getInstance()->findIMSession(mSessionID);
mCommitCallbackRegistrar.add("IMSession.Menu.Action",
@@ -124,7 +125,6 @@ void LLFloaterIMSessionTab::setVisible(BOOL visible)
{
LLFloaterIMSessionTab::addToHost(mSessionID);
}
- setFocus(visible);
}
/*virtual*/
@@ -306,7 +306,7 @@ void LLFloaterIMSessionTab::onFocusReceived()
LLFloaterIMContainer* container = LLFloaterReg::getTypedInstance<LLFloaterIMContainer>("im_container");
if (container)
{
- container->selectConversationPair(mSessionID, true);
+ container->selectConversationPair(mSessionID, ! getHost());
container->showStub(! getHost());
}
}
@@ -691,8 +691,13 @@ void LLFloaterIMSessionTab::processChatHistoryStyleUpdate()
void LLFloaterIMSessionTab::updateCallBtnState(bool callIsActive)
{
- getChild<LLButton>("voice_call_btn")->setImageOverlay(
+ LLButton* voiceButton = getChild<LLButton>("voice_call_btn");
+ voiceButton->setImageOverlay(
callIsActive? getString("call_btn_stop") : getString("call_btn_start"));
+
+ voiceButton->setToolTip(
+ callIsActive? getString("end_call_button_tooltip") : getString("start_call_button_tooltip"));
+
enableDisableCallBtn();
}
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp
index 0de8f124ee..0b18a503ab 100644
--- a/indra/newview/llimview.cpp
+++ b/indra/newview/llimview.cpp
@@ -191,7 +191,25 @@ void on_new_message(const LLSD& msg)
}
else if("openconversations" == action)
{
- LLFloaterReg::showInstance("im_container");
+ LLFloaterIMContainer* im_box = LLFloaterReg::getTypedInstance<LLFloaterIMContainer>("im_container");
+ LLFloaterIMSessionTab* session_floater = LLFloaterIMSessionTab::getConversation(session_id);
+
+ //Don't flash and show conversation floater when conversation already active (has focus)
+ if(session_floater
+ && (!session_floater->isInVisibleChain()) //conversation floater not displayed
+ ||
+ (session_floater->isInVisibleChain() && session_floater->hasFocus() == false)) //conversation floater is displayed but doesn't have focus
+
+ {
+ //Flash line item
+ if (im_box)
+ {
+ im_box->flashConversationItemWidget(session_id, true); // flashing of the conversation's item
+ }
+
+ //Surface conversations floater
+ LLFloaterReg::showInstance("im_container");
+ }
}
}
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index bad4e8c231..1e60b10a68 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -255,6 +255,11 @@ BOOL LLInvFVBridge::isLink() const
return mIsLink;
}
+BOOL LLInvFVBridge::isLibraryItem() const
+{
+ return gInventory.isObjectDescendentOf(getUUID(),gInventory.getLibraryRootFolderID());
+}
+
/*virtual*/
/**
* @brief Adds this item into clipboard storage
diff --git a/indra/newview/llinventorybridge.h b/indra/newview/llinventorybridge.h
index 5e96f00920..5c6cf0f0f0 100644
--- a/indra/newview/llinventorybridge.h
+++ b/indra/newview/llinventorybridge.h
@@ -107,6 +107,7 @@ public:
virtual BOOL isItemMovable() const;
virtual BOOL isItemInTrash() const;
virtual BOOL isLink() const;
+ virtual BOOL isLibraryItem() const;
//virtual BOOL removeItem() = 0;
virtual void removeBatch(std::vector<LLFolderViewModelItem*>& batch);
virtual void move(LLFolderViewModelItem* new_parent_bridge) {}
diff --git a/indra/newview/llinventorypanel.cpp b/indra/newview/llinventorypanel.cpp
index 098a44b9d8..81e7f166e1 100644
--- a/indra/newview/llinventorypanel.cpp
+++ b/indra/newview/llinventorypanel.cpp
@@ -57,6 +57,15 @@ const std::string LLInventoryPanel::RECENTITEMS_SORT_ORDER = std::string("Recent
const std::string LLInventoryPanel::INHERIT_SORT_ORDER = std::string("");
static const LLInventoryFolderViewModelBuilder INVENTORY_BRIDGE_BUILDER;
+// statics
+bool LLInventoryPanel::sColorSetInitialized = false;
+LLUIColor LLInventoryPanel::sDefaultColor;
+LLUIColor LLInventoryPanel::sDefaultHighlightColor;
+LLUIColor LLInventoryPanel::sLibraryColor;
+LLUIColor LLInventoryPanel::sLinkColor;
+
+const LLColor4U DEFAULT_WHITE(255, 255, 255);
+
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Class LLInventoryPanelObserver
//
@@ -140,6 +149,15 @@ LLInventoryPanel::LLInventoryPanel(const LLInventoryPanel::Params& p) :
{
mInvFVBridgeBuilder = &INVENTORY_BRIDGE_BUILDER;
+ if (!sColorSetInitialized)
+ {
+ sDefaultColor = LLUIColorTable::instance().getColor("MenuItemEnabledColor", DEFAULT_WHITE);
+ sDefaultHighlightColor = LLUIColorTable::instance().getColor("MenuItemHighlightFgColor", DEFAULT_WHITE);
+ sLibraryColor = LLUIColorTable::instance().getColor("InventoryItemLibraryColor", DEFAULT_WHITE);
+ sLinkColor = LLUIColorTable::instance().getColor("InventoryItemLinkColor", DEFAULT_WHITE);
+ sColorSetInitialized = true;
+ }
+
// context menu callbacks
mCommitCallbackRegistrar.add("Inventory.DoToSelected", boost::bind(&LLInventoryPanel::doToSelected, this, _2));
mCommitCallbackRegistrar.add("Inventory.EmptyTrash", boost::bind(&LLInventoryModel::emptyFolderType, &gInventory, "ConfirmEmptyTrash", LLFolderType::FT_TRASH));
@@ -705,6 +723,9 @@ LLFolderViewFolder * LLInventoryPanel::createFolderViewFolder(LLInvFVBridge * br
params.listener = bridge;
params.tool_tip = params.name;
+ params.font_color = (bridge->isLibraryItem() ? sLibraryColor : (bridge->isLink() ? sLinkColor : sDefaultColor));
+ params.font_highlight_color = (bridge->isLibraryItem() ? sLibraryColor : (bridge->isLink() ? sLinkColor : sDefaultHighlightColor));
+
return LLUICtrlFactory::create<LLFolderViewFolder>(params);
}
@@ -718,6 +739,9 @@ LLFolderViewItem * LLInventoryPanel::createFolderViewItem(LLInvFVBridge * bridge
params.listener = bridge;
params.rect = LLRect (0, 0, 0, 0);
params.tool_tip = params.name;
+
+ params.font_color = (bridge->isLibraryItem() ? sLibraryColor : (bridge->isLink() ? sLinkColor : sDefaultColor));
+ params.font_highlight_color = (bridge->isLibraryItem() ? sLibraryColor : (bridge->isLink() ? sLinkColor : sDefaultHighlightColor));
return LLUICtrlFactory::create<LLFolderViewItem>(params);
}
diff --git a/indra/newview/llinventorypanel.h b/indra/newview/llinventorypanel.h
index c4f3c1b47d..9639086c11 100644
--- a/indra/newview/llinventorypanel.h
+++ b/indra/newview/llinventorypanel.h
@@ -275,6 +275,13 @@ protected:
// Builds the UI. Call this once the inventory is usable.
void initializeViews();
+ // Specific inventory colors
+ static bool sColorSetInitialized;
+ static LLUIColor sDefaultColor;
+ static LLUIColor sDefaultHighlightColor;
+ static LLUIColor sLibraryColor;
+ static LLUIColor sLinkColor;
+
LLFolderViewItem* buildNewViews(const LLUUID& id);
BOOL getIsHiddenFolderType(LLFolderType::EType folder_type) const;
diff --git a/indra/newview/llnotificationofferhandler.cpp b/indra/newview/llnotificationofferhandler.cpp
index 91003c7d53..ff5b5e21f7 100644
--- a/indra/newview/llnotificationofferhandler.cpp
+++ b/indra/newview/llnotificationofferhandler.cpp
@@ -113,6 +113,7 @@ bool LLOfferHandler::processNotification(const LLNotificationPtr& notification)
p.panel = notify_box;
// we not save offer notifications to the syswell floater that should be added to the IM floater
p.can_be_stored = !add_notif_to_im;
+ p.force_show = notification->getOfferFromAgent();
LLScreenChannel* channel = dynamic_cast<LLScreenChannel*>(mChannel.get());
if(channel)
diff --git a/indra/newview/llscriptfloater.cpp b/indra/newview/llscriptfloater.cpp
index dc12192697..0e0da6bdc7 100644
--- a/indra/newview/llscriptfloater.cpp
+++ b/indra/newview/llscriptfloater.cpp
@@ -95,7 +95,12 @@ bool LLScriptFloater::toggle(const LLUUID& notification_id)
show(notification_id);
}
- LLChicletBar::getInstance()->getChicletPanel()->setChicletToggleState(notification_id, true);
+ LLChicletPanel * chiclet_panelp = LLChicletBar::getInstance()->getChicletPanel();
+ if (NULL != chiclet_panelp)
+ {
+ chiclet_panelp->setChicletToggleState(notification_id, true);
+ }
+
return true;
}
@@ -206,10 +211,14 @@ void LLScriptFloater::setVisible(BOOL visible)
if(!visible)
{
- LLIMChiclet* chiclet = LLChicletBar::getInstance()->getChicletPanel()->findChiclet<LLIMChiclet>(getNotificationId());
- if(chiclet)
+ LLChicletPanel * chiclet_panelp = LLChicletBar::getInstance()->getChicletPanel();
+ if (NULL != chiclet_panelp)
{
- chiclet->setToggleState(false);
+ LLIMChiclet * chicletp = chiclet_panelp->findChiclet<LLIMChiclet>(getNotificationId());
+ if(NULL != chicletp)
+ {
+ chicletp->setToggleState(false);
+ }
}
}
}
@@ -218,15 +227,19 @@ void LLScriptFloater::onMouseDown()
{
if(getNotificationId().notNull())
{
- // Remove new message icon
- LLIMChiclet* chiclet = LLChicletBar::getInstance()->getChicletPanel()->findChiclet<LLIMChiclet>(getNotificationId());
- if (chiclet == NULL)
+ LLChicletPanel * chiclet_panelp = LLChicletBar::getInstance()->getChicletPanel();
+ if (NULL != chiclet_panelp)
{
- llerror("Dock chiclet for LLScriptFloater doesn't exist", 0);
- }
- else
- {
- chiclet->setShowNewMessagesIcon(false);
+ LLIMChiclet * chicletp = chiclet_panelp->findChiclet<LLIMChiclet>(getNotificationId());
+ // Remove new message icon
+ if (NULL == chicletp)
+ {
+ llerror("Dock chiclet for LLScriptFloater doesn't exist", 0);
+ }
+ else
+ {
+ chicletp->setShowNewMessagesIcon(false);
+ }
}
}
}
@@ -262,7 +275,11 @@ void LLScriptFloater::onFocusLost()
{
if(getNotificationId().notNull())
{
- LLChicletBar::getInstance()->getChicletPanel()->setChicletToggleState(getNotificationId(), false);
+ LLChicletPanel * chiclet_panelp = LLChicletBar::getInstance()->getChicletPanel();
+ if (NULL != chiclet_panelp)
+ {
+ chiclet_panelp->setChicletToggleState(getNotificationId(), false);
+ }
}
}
@@ -271,7 +288,11 @@ void LLScriptFloater::onFocusReceived()
// first focus will be received before setObjectId() call - don't toggle chiclet
if(getNotificationId().notNull())
{
- LLChicletBar::getInstance()->getChicletPanel()->setChicletToggleState(getNotificationId(), true);
+ LLChicletPanel * chiclet_panelp = LLChicletBar::getInstance()->getChicletPanel();
+ if (NULL != chiclet_panelp)
+ {
+ chiclet_panelp->setChicletToggleState(getNotificationId(), true);
+ }
}
}
@@ -279,28 +300,30 @@ void LLScriptFloater::dockToChiclet(bool dock)
{
if (getDockControl() == NULL)
{
- LLChiclet* chiclet = LLChicletBar::getInstance()->getChicletPanel()->findChiclet<LLChiclet>(getNotificationId());
- if (chiclet == NULL)
- {
- llwarns << "Dock chiclet for LLScriptFloater doesn't exist" << llendl;
- return;
- }
- else
+ LLChicletPanel * chiclet_panelp = LLChicletBar::getInstance()->getChicletPanel();
+ if (NULL != chiclet_panelp)
{
- LLChicletBar::getInstance()->getChicletPanel()->scrollToChiclet(chiclet);
- }
+ LLChiclet * chicletp = chiclet_panelp->findChiclet<LLChiclet>(getNotificationId());
+ if (NULL == chicletp)
+ {
+ llwarns << "Dock chiclet for LLScriptFloater doesn't exist" << llendl;
+ return;
+ }
- // Stop saving position while we dock floater
- bool save = getSavePosition();
- setSavePosition(false);
+ chiclet_panelp->scrollToChiclet(chicletp);
- setDockControl(new LLDockControl(chiclet, this, getDockTongue(),
- LLDockControl::BOTTOM));
+ // Stop saving position while we dock floater
+ bool save = getSavePosition();
+ setSavePosition(false);
- setDocked(dock);
+ setDockControl(new LLDockControl(chicletp, this, getDockTongue(),
+ LLDockControl::BOTTOM));
- // Restore saving
- setSavePosition(save);
+ setDocked(dock);
+
+ // Restore saving
+ setSavePosition(save);
+ }
}
}
@@ -347,11 +370,15 @@ void LLScriptFloaterManager::onAddNotification(const LLUUID& notification_id)
script_notification_map_t::const_iterator it = findUsingObjectId(object_id);
if(it != mNotifications.end())
{
- LLIMChiclet* chiclet = LLChicletBar::getInstance()->getChicletPanel()->findChiclet<LLIMChiclet>(it->first);
- if(chiclet)
+ LLChicletPanel * chiclet_panelp = LLChicletBar::getInstance()->getChicletPanel();
+ if (NULL != chiclet_panelp)
{
- // Pass the new_message icon state further.
- set_new_message = chiclet->getShowNewMessagesIcon();
+ LLIMChiclet * chicletp = chiclet_panelp->findChiclet<LLIMChiclet>(it->first);
+ if(NULL != chicletp)
+ {
+ // Pass the new_message icon state further.
+ set_new_message = chicletp->getShowNewMessagesIcon();
+ }
}
LLScriptFloater* floater = LLFloaterReg::findTypedInstance<LLScriptFloater>("script_floater", it->first);
@@ -367,14 +394,18 @@ void LLScriptFloaterManager::onAddNotification(const LLUUID& notification_id)
mNotifications.insert(std::make_pair(notification_id, object_id));
- // Create inventory offer chiclet for offer type notifications
- if( OBJ_GIVE_INVENTORY == obj_type )
+ LLChicletPanel * chiclet_panelp = LLChicletBar::getInstance()->getChicletPanel();
+ if (NULL != chiclet_panelp)
{
- LLChicletBar::instance().getChicletPanel()->createChiclet<LLInvOfferChiclet>(notification_id);
- }
- else
- {
- LLChicletBar::getInstance()->getChicletPanel()->createChiclet<LLScriptChiclet>(notification_id);
+ // Create inventory offer chiclet for offer type notifications
+ if( OBJ_GIVE_INVENTORY == obj_type )
+ {
+ chiclet_panelp->createChiclet<LLInvOfferChiclet>(notification_id);
+ }
+ else
+ {
+ chiclet_panelp->createChiclet<LLScriptChiclet>(notification_id);
+ }
}
LLIMWellWindow::getInstance()->addObjectRow(notification_id, set_new_message);
@@ -410,7 +441,11 @@ void LLScriptFloaterManager::onRemoveNotification(const LLUUID& notification_id)
// remove related chiclet
if (LLChicletBar::instanceExists())
{
- LLChicletBar::getInstance()->getChicletPanel()->removeChiclet(notification_id);
+ LLChicletPanel * chiclet_panelp = LLChicletBar::getInstance()->getChicletPanel();
+ if (NULL != chiclet_panelp)
+ {
+ chiclet_panelp->removeChiclet(notification_id);
+ }
}
LLIMWellWindow* im_well_window = LLIMWellWindow::findInstance();
diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp
index 1704ad9055..34259658ea 100755
--- a/indra/newview/llstartup.cpp
+++ b/indra/newview/llstartup.cpp
@@ -1520,7 +1520,7 @@ bool idle_startup()
}
//---------------------------------------------------------------------
- // Agent Send
+ // World Wait
//---------------------------------------------------------------------
if(STATE_WORLD_WAIT == LLStartUp::getStartupState())
{
@@ -1846,6 +1846,10 @@ bool idle_startup()
// Set the show start location to true, now that the user has logged
// on with this install.
gSavedSettings.setBOOL("ShowStartLocation", TRUE);
+
+ // Open Conversation floater on first login.
+ LLFloaterReg::toggleInstanceOrBringToFront("im_container");
+
}
display_startup();
@@ -2168,7 +2172,6 @@ bool idle_startup()
display_startup();
// Unmute audio if desired and setup volumes.
- // Unmute audio if desired and setup volumes.
// This is a not-uncommon crash site, so surround it with
// llinfos output to aid diagnosis.
LL_INFOS("AppInit") << "Doing first audio_update_volume..." << LL_ENDL;
diff --git a/indra/newview/llsyswellwindow.cpp b/indra/newview/llsyswellwindow.cpp
index 3605129d48..8a43855a7d 100644
--- a/indra/newview/llsyswellwindow.cpp
+++ b/indra/newview/llsyswellwindow.cpp
@@ -23,35 +23,23 @@
* $/LicenseInfo$
*/
-
#include "llviewerprecompiledheaders.h" // must be first include
-
#include "llsyswellwindow.h"
-#include "llagent.h"
-#include "llavatarnamecache.h"
-
-#include "llflatlistview.h"
-#include "llfloaterreg.h"
-#include "llnotifications.h"
-
-#include "llscriptfloater.h"
-#include "llviewercontrol.h"
-#include "llviewerwindow.h"
-
#include "llchiclet.h"
#include "llchicletbar.h"
-#include "lltoastpanel.h"
+#include "llflatlistview.h"
+#include "llfloaterreg.h"
#include "llnotificationmanager.h"
#include "llnotificationsutil.h"
+#include "llscriptfloater.h"
#include "llspeakers.h"
-#include "lltoolbarview.h"
+#include "lltoastpanel.h"
//---------------------------------------------------------------------------------
LLSysWellWindow::LLSysWellWindow(const LLSD& key) : LLTransientDockableFloater(NULL, true, key),
mChannel(NULL),
mMessageList(NULL),
- mSysWellChiclet(NULL),
NOTIFICATION_WELL_ANCHOR_NAME("notification_well_panel"),
IM_WELL_ANCHOR_NAME("im_well_panel"),
mIsReshapedByUser(false)
@@ -68,10 +56,6 @@ BOOL LLSysWellWindow::postBuild()
// get a corresponding channel
initChannel();
- // click on SysWell Window should clear "new message" state (and 'Lit' status). EXT-3147.
- // mouse up callback is not called in this case.
- setMouseDownCallback(boost::bind(&LLSysWellWindow::releaseNewMessagesState, this));
-
return LLTransientDockableFloater::postBuild();
}
@@ -95,14 +79,6 @@ void LLSysWellWindow::onStartUpToastClick(S32 x, S32 y, MASK mask)
setVisible(TRUE);
}
-void LLSysWellWindow::setSysWellChiclet(LLSysWellChiclet* chiclet)
-{
- mSysWellChiclet = chiclet;
- if(NULL != mSysWellChiclet)
- {
- mSysWellChiclet->updateWidget(isWindowEmpty());
- }
-}
//---------------------------------------------------------------------------------
LLSysWellWindow::~LLSysWellWindow()
{
@@ -113,10 +89,6 @@ void LLSysWellWindow::removeItemByID(const LLUUID& id)
{
if(mMessageList->removeItemByValue(id))
{
- if (NULL != mSysWellChiclet)
- {
- mSysWellChiclet->updateWidget(isWindowEmpty());
- }
reshapeWindow();
}
else
@@ -170,11 +142,6 @@ void LLSysWellWindow::setVisible(BOOL visible)
mChannel->updateShowToastsState();
mChannel->redrawToasts();
}
-
- if (visible)
- {
- releaseNewMessagesState();
- }
}
//---------------------------------------------------------------------------------
@@ -224,14 +191,6 @@ void LLSysWellWindow::reshapeWindow()
}
}
-void LLSysWellWindow::releaseNewMessagesState()
-{
- if (NULL != mSysWellChiclet)
- {
- mSysWellChiclet->setNewMessagesState(false);
- }
-}
-
//---------------------------------------------------------------------------------
bool LLSysWellWindow::isWindowEmpty()
{
@@ -239,121 +198,6 @@ bool LLSysWellWindow::isWindowEmpty()
}
/************************************************************************/
-/* RowPanel implementation */
-/************************************************************************/
-
-//---------------------------------------------------------------------------------
-LLIMWellWindow::RowPanel::RowPanel(const LLSysWellWindow* parent, const LLUUID& sessionId,
- S32 chicletCounter, const std::string& name, const LLUUID& otherParticipantId) :
- LLPanel(LLPanel::Params()), mChiclet(NULL), mParent(parent)
-{
- buildFromFile( "panel_activeim_row.xml");
-
- // Choose which of the pre-created chiclets (IM/group) to use.
- // The other one gets hidden.
-
- LLIMChiclet::EType im_chiclet_type = LLIMChiclet::getIMSessionType(sessionId);
- switch (im_chiclet_type)
- {
- case LLIMChiclet::TYPE_GROUP:
- mChiclet = getChild<LLIMGroupChiclet>("group_chiclet");
- break;
- case LLIMChiclet::TYPE_AD_HOC:
- mChiclet = getChild<LLAdHocChiclet>("adhoc_chiclet");
- break;
- case LLIMChiclet::TYPE_UNKNOWN: // assign mChiclet a non-null value anyway
- case LLIMChiclet::TYPE_IM:
- mChiclet = getChild<LLIMP2PChiclet>("p2p_chiclet");
- break;
- }
-
- // Initialize chiclet.
- mChiclet->setChicletSizeChangedCallback(boost::bind(&LLIMWellWindow::RowPanel::onChicletSizeChanged, this, mChiclet, _2));
- mChiclet->enableCounterControl(true);
- mChiclet->setCounter(chicletCounter);
- mChiclet->setSessionId(sessionId);
- mChiclet->setIMSessionName(name);
- mChiclet->setOtherParticipantId(otherParticipantId);
- mChiclet->setVisible(true);
-
- if (im_chiclet_type == LLIMChiclet::TYPE_IM)
- {
- LLAvatarNameCache::get(otherParticipantId,
- boost::bind(&LLIMWellWindow::RowPanel::onAvatarNameCache,
- this, _1, _2));
- }
- else
- {
- LLTextBox* contactName = getChild<LLTextBox>("contact_name");
- contactName->setValue(name);
- }
-
- mCloseBtn = getChild<LLButton>("hide_btn");
- mCloseBtn->setCommitCallback(boost::bind(&LLIMWellWindow::RowPanel::onClosePanel, this));
-}
-
-//---------------------------------------------------------------------------------
-void LLIMWellWindow::RowPanel::onAvatarNameCache(const LLUUID& agent_id,
- const LLAvatarName& av_name)
-{
- LLTextBox* contactName = getChild<LLTextBox>("contact_name");
- contactName->setValue( av_name.getCompleteName() );
-}
-
-//---------------------------------------------------------------------------------
-void LLIMWellWindow::RowPanel::onChicletSizeChanged(LLChiclet* ctrl, const LLSD& param)
-{
- LLTextBox* text = getChild<LLTextBox>("contact_name");
- S32 new_text_left = mChiclet->getRect().mRight + CHICLET_HPAD;
- LLRect text_rect = text->getRect();
- text_rect.mLeft = new_text_left;
- text->setShape(text_rect);
-}
-
-//---------------------------------------------------------------------------------
-LLIMWellWindow::RowPanel::~RowPanel()
-{
-}
-
-//---------------------------------------------------------------------------------
-void LLIMWellWindow::RowPanel::onClosePanel()
-{
- gIMMgr->leaveSession(mChiclet->getSessionId());
- // This row panel will be removed from the list in LLSysWellWindow::sessionRemoved().
-}
-
-//---------------------------------------------------------------------------------
-void LLIMWellWindow::RowPanel::onMouseEnter(S32 x, S32 y, MASK mask)
-{
- setTransparentColor(LLUIColorTable::instance().getColor("SysWellItemSelected"));
-}
-
-//---------------------------------------------------------------------------------
-void LLIMWellWindow::RowPanel::onMouseLeave(S32 x, S32 y, MASK mask)
-{
- setTransparentColor(LLUIColorTable::instance().getColor("SysWellItemUnselected"));
-}
-
-//---------------------------------------------------------------------------------
-// virtual
-BOOL LLIMWellWindow::RowPanel::handleMouseDown(S32 x, S32 y, MASK mask)
-{
- // Pass the mouse down event to the chiclet (EXT-596).
- if (!mChiclet->pointInView(x, y) && !mCloseBtn->getRect().pointInRect(x, y)) // prevent double call of LLIMChiclet::onMouseDown()
- {
- mChiclet->onMouseDown();
- return TRUE;
- }
-
- return LLPanel::handleMouseDown(x, y, mask);
-}
-
-// virtual
-BOOL LLIMWellWindow::RowPanel::handleRightMouseDown(S32 x, S32 y, MASK mask)
-{
- return mChiclet->handleRightMouseDown(x, y, mask);
-}
-/************************************************************************/
/* ObjectRowPanel implementation */
/************************************************************************/
@@ -490,9 +334,7 @@ void LLNotificationWellWindow::addItem(LLSysWellItem::Params p)
LLSysWellItem* new_item = new LLSysWellItem(p);
if (mMessageList->addItem(new_item, value, ADD_TOP))
{
- mSysWellChiclet->updateWidget(isWindowEmpty());
reshapeWindow();
-
new_item->setOnItemCloseCallback(boost::bind(&LLNotificationWellWindow::onItemClose, this, _1));
new_item->setOnItemClickCallback(boost::bind(&LLNotificationWellWindow::onItemClick, this, _1));
}
@@ -576,9 +418,6 @@ void LLNotificationWellWindow::onAdd( LLNotificationPtr notify )
removeItemByID(notify->getID());
}
-
-
-
/************************************************************************/
/* LLIMWellWindow implementation */
/************************************************************************/
@@ -588,12 +427,10 @@ void LLNotificationWellWindow::onAdd( LLNotificationPtr notify )
LLIMWellWindow::LLIMWellWindow(const LLSD& key)
: LLSysWellWindow(key)
{
- LLIMMgr::getInstance()->addSessionObserver(this);
}
LLIMWellWindow::~LLIMWellWindow()
{
- LLIMMgr::getInstance()->removeSessionObserver(this);
}
// static
@@ -614,47 +451,11 @@ BOOL LLIMWellWindow::postBuild()
BOOL rv = LLSysWellWindow::postBuild();
setTitle(getString("title_im_well_window"));
- LLIMChiclet::sFindChicletsSignal.connect(boost::bind(&LLIMWellWindow::findIMChiclet, this, _1));
LLIMChiclet::sFindChicletsSignal.connect(boost::bind(&LLIMWellWindow::findObjectChiclet, this, _1));
return rv;
}
-//virtual
-void LLIMWellWindow::sessionAdded(const LLUUID& session_id,
- const std::string& name, const LLUUID& other_participant_id, BOOL has_offline_msg)
-{
- LLIMModel::LLIMSession* session = LLIMModel::getInstance()->findIMSession(session_id);
- if (!session) return;
-
- // no need to spawn chiclets for participants in P2P calls called through Avaline
- if (session->isP2P() && session->isOtherParticipantAvaline()) return;
-
- if (mMessageList->getItemByValue(session_id)) return;
-
- addIMRow(session_id, 0, name, other_participant_id);
- reshapeWindow();
-}
-
-//virtual
-void LLIMWellWindow::sessionRemoved(const LLUUID& sessionId)
-{
- delIMRow(sessionId);
- reshapeWindow();
-}
-
-//virtual
-void LLIMWellWindow::sessionIDUpdated(const LLUUID& old_session_id, const LLUUID& new_session_id)
-{
- //for outgoing ad-hoc and group im sessions only
- LLChiclet* chiclet = findIMChiclet(old_session_id);
- if (chiclet)
- {
- chiclet->setSessionId(new_session_id);
- mMessageList->updateValue(old_session_id, new_session_id);
- }
-}
-
LLChiclet* LLIMWellWindow::findObjectChiclet(const LLUUID& notification_id)
{
if (!mMessageList) return NULL;
@@ -671,66 +472,6 @@ LLChiclet* LLIMWellWindow::findObjectChiclet(const LLUUID& notification_id)
//////////////////////////////////////////////////////////////////////////
// PRIVATE METHODS
-LLChiclet* LLIMWellWindow::findIMChiclet(const LLUUID& sessionId)
-{
- if (!mMessageList) return NULL;
-
- LLChiclet* res = NULL;
- RowPanel* panel = mMessageList->getTypedItemByValue<RowPanel>(sessionId);
- if (panel != NULL)
- {
- res = panel->mChiclet;
- }
-
- return res;
-}
-
-//---------------------------------------------------------------------------------
-void LLIMWellWindow::addIMRow(const LLUUID& sessionId, S32 chicletCounter,
- const std::string& name, const LLUUID& otherParticipantId)
-{
- RowPanel* item = new RowPanel(this, sessionId, chicletCounter, name, otherParticipantId);
- if (!mMessageList->addItem(item, sessionId))
- {
- llwarns << "Unable to add IM Row into the list, sessionID: " << sessionId
- << ", name: " << name
- << ", other participant ID: " << otherParticipantId
- << llendl;
-
- item->die();
- }
-}
-
-//---------------------------------------------------------------------------------
-void LLIMWellWindow::delIMRow(const LLUUID& sessionId)
-{
- //fix for EXT-3252
- //without this line LLIMWellWindow receive onFocusLost
- //and hide itself. It was becaue somehow LLIMChicklet was in focus group for
- //LLIMWellWindow...
- //But I didn't find why this happen..
- gFocusMgr.clearLastFocusForGroup(this);
-
- if (!mMessageList->removeItemByValue(sessionId))
- {
- llwarns << "Unable to remove IM Row from the list, sessionID: " << sessionId
- << llendl;
- }
-
- // remove all toasts that belong to this session from a screen
- if(mChannel)
- mChannel->removeToastsBySessionID(sessionId);
-
- // hide chiclet window if there are no items left
- if(isWindowEmpty())
- {
- setVisible(FALSE);
- }
- else
- {
- setFocus(true);
- }
-}
void LLIMWellWindow::addObjectRow(const LLUUID& notification_id, bool new_message/* = false*/)
{
@@ -761,21 +502,6 @@ void LLIMWellWindow::removeObjectRow(const LLUUID& notification_id)
}
}
-
-void LLIMWellWindow::addIMRow(const LLUUID& session_id)
-{
- if (hasIMRow(session_id)) return;
-
- LLIMModel* im_model = LLIMModel::getInstance();
- addIMRow(session_id, 0, im_model->getName(session_id), im_model->getOtherParticipantID(session_id));
- reshapeWindow();
-}
-
-bool LLIMWellWindow::hasIMRow(const LLUUID& session_id)
-{
- return mMessageList->getItemByValue(session_id);
-}
-
void LLIMWellWindow::closeAll()
{
// Generate an ignorable alert dialog if there is an active voice IM sesion
@@ -820,13 +546,6 @@ void LLIMWellWindow::closeAllImpl()
{
LLPanel* panel = mMessageList->getItemByValue(*iter);
- RowPanel* im_panel = dynamic_cast <RowPanel*> (panel);
- if (im_panel)
- {
- gIMMgr->leaveSession(*iter);
- continue;
- }
-
ObjectRowPanel* obj_panel = dynamic_cast <ObjectRowPanel*> (panel);
if (obj_panel)
{
diff --git a/indra/newview/llsyswellwindow.h b/indra/newview/llsyswellwindow.h
index d6480f1fc6..406ab1b59e 100644
--- a/indra/newview/llsyswellwindow.h
+++ b/indra/newview/llsyswellwindow.h
@@ -27,32 +27,26 @@
#ifndef LL_LLSYSWELLWINDOW_H
#define LL_LLSYSWELLWINDOW_H
-#include "llsyswellitem.h"
-
-#include "lltransientdockablefloater.h"
-#include "llbutton.h"
-#include "llscreenchannel.h"
-#include "llscrollcontainer.h"
#include "llimview.h"
#include "llnotifications.h"
-
-#include "boost/shared_ptr.hpp"
+#include "llscreenchannel.h"
+#include "llsyswellitem.h"
+#include "lltransientdockablefloater.h"
class LLAvatarName;
-class LLFlatListView;
class LLChiclet;
+class LLFlatListView;
class LLIMChiclet;
class LLScriptChiclet;
class LLSysWellChiclet;
-
class LLSysWellWindow : public LLTransientDockableFloater
{
public:
LOG_CLASS(LLSysWellWindow);
LLSysWellWindow(const LLSD& key);
- ~LLSysWellWindow();
+ virtual ~LLSysWellWindow();
BOOL postBuild();
// other interface functions
@@ -72,8 +66,6 @@ public:
void onStartUpToastClick(S32 x, S32 y, MASK mask);
- void setSysWellChiclet(LLSysWellChiclet* chiclet);
-
// size constants for the window and for its elements
static const S32 MAX_WINDOW_HEIGHT = 200;
static const S32 MIN_WINDOW_WIDTH = 318;
@@ -87,17 +79,11 @@ protected:
virtual const std::string& getAnchorViewName() = 0;
void reshapeWindow();
- void releaseNewMessagesState();
// pointer to a corresponding channel's instance
LLNotificationsUI::LLScreenChannel* mChannel;
LLFlatListView* mMessageList;
- /**
- * Reference to an appropriate Well chiclet to release "new message" state. EXT-3147
- */
- LLSysWellChiclet* mSysWellChiclet;
-
bool mIsReshapedByUser;
};
@@ -157,7 +143,7 @@ private:
*
* It contains a list list of all active IM sessions.
*/
-class LLIMWellWindow : public LLSysWellWindow, LLIMSessionObserver, LLInitClass<LLIMWellWindow>
+class LLIMWellWindow : public LLSysWellWindow, LLInitClass<LLIMWellWindow>
{
public:
LLIMWellWindow(const LLSD& key);
@@ -169,59 +155,19 @@ public:
/*virtual*/ BOOL postBuild();
- // LLIMSessionObserver observe triggers
- /*virtual*/ void sessionAdded(const LLUUID& session_id, const std::string& name, const LLUUID& other_participant_id, BOOL has_offline_msg);
- /*virtual*/ void sessionActivated(const LLUUID& session_id, const std::string& name, const LLUUID& other_participant_id) {}
- /*virtual*/ void sessionVoiceOrIMStarted(const LLUUID& session_id) {};
- /*virtual*/ void sessionRemoved(const LLUUID& session_id);
- /*virtual*/ void sessionIDUpdated(const LLUUID& old_session_id, const LLUUID& new_session_id);
-
void addObjectRow(const LLUUID& notification_id, bool new_message = false);
void removeObjectRow(const LLUUID& notification_id);
-
- void addIMRow(const LLUUID& session_id);
- bool hasIMRow(const LLUUID& session_id);
-
void closeAll();
protected:
/*virtual*/ const std::string& getAnchorViewName() { return IM_WELL_ANCHOR_NAME; }
private:
- LLChiclet * findIMChiclet(const LLUUID& sessionId);
LLChiclet* findObjectChiclet(const LLUUID& notification_id);
- void addIMRow(const LLUUID& sessionId, S32 chicletCounter, const std::string& name, const LLUUID& otherParticipantId);
- void delIMRow(const LLUUID& sessionId);
bool confirmCloseAll(const LLSD& notification, const LLSD& response);
void closeAllImpl();
- /**
- * Scrolling row panel.
- */
- class RowPanel: public LLPanel
- {
- public:
- RowPanel(const LLSysWellWindow* parent, const LLUUID& sessionId, S32 chicletCounter,
- const std::string& name, const LLUUID& otherParticipantId);
- virtual ~RowPanel();
- void onMouseEnter(S32 x, S32 y, MASK mask);
- void onMouseLeave(S32 x, S32 y, MASK mask);
- BOOL handleMouseDown(S32 x, S32 y, MASK mask);
- BOOL handleRightMouseDown(S32 x, S32 y, MASK mask);
-
- private:
- static const S32 CHICLET_HPAD = 10;
- void onAvatarNameCache(const LLUUID& agent_id, const LLAvatarName& av_name);
- void onChicletSizeChanged(LLChiclet* ctrl, const LLSD& param);
- void onClosePanel();
- public:
- LLIMChiclet* mChiclet;
- private:
- LLButton* mCloseBtn;
- const LLSysWellWindow* mParent;
- };
-
class ObjectRowPanel: public LLPanel
{
public:
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp
index 6397ef7961..5bb7db5c0d 100755
--- a/indra/newview/llviewermessage.cpp
+++ b/indra/newview/llviewermessage.cpp
@@ -1971,6 +1971,7 @@ void inventory_offer_handler(LLOfferInfo* info)
p.substitutions(args).payload(payload).functor.responder(LLNotificationResponderPtr(info));
info->mPersist = true;
p.name = "UserGiveItem";
+ p.offer_from_agent = true;
// Prefetch the item into your local inventory.
LLInventoryFetchItemsObserver* fetch_item = new LLInventoryFetchItemsObserver(info->mObjectID);
@@ -2729,7 +2730,9 @@ void process_improved_im(LLMessageSystem *msg, void **user_data)
// Same as closing window
info->forceResponse(IOR_DECLINE);
}
- else if (is_do_not_disturb && dialog != IM_TASK_INVENTORY_OFFERED) // busy mode must not affect interaction with objects (STORM-565)
+ // old logic: busy mode must not affect interaction with objects (STORM-565)
+ // new logic: inventory offers from in-world objects should be auto-declined (CHUI-519)
+ else if (is_do_not_disturb && dialog == IM_TASK_INVENTORY_OFFERED)
{
// Until throttling is implemented, do not disturb mode should reject inventory instead of silently
// accepting it. SEE SL-39554
diff --git a/indra/newview/skins/default/textures/bottomtray/Notices_Unread.png b/indra/newview/skins/default/textures/bottomtray/Notices_Unread.png
deleted file mode 100644
index 0ac5b72b8f..0000000000
--- a/indra/newview/skins/default/textures/bottomtray/Notices_Unread.png
+++ /dev/null
Binary files differ
diff --git a/indra/newview/skins/default/textures/bottomtray/VoicePTT_Lvl1_Dark.png b/indra/newview/skins/default/textures/bottomtray/VoicePTT_Lvl1_Dark.png
deleted file mode 100644
index 857fa1e047..0000000000
--- a/indra/newview/skins/default/textures/bottomtray/VoicePTT_Lvl1_Dark.png
+++ /dev/null
Binary files differ
diff --git a/indra/newview/skins/default/textures/bottomtray/VoicePTT_Lvl2_Dark.png b/indra/newview/skins/default/textures/bottomtray/VoicePTT_Lvl2_Dark.png
deleted file mode 100644
index 453bb53673..0000000000
--- a/indra/newview/skins/default/textures/bottomtray/VoicePTT_Lvl2_Dark.png
+++ /dev/null
Binary files differ
diff --git a/indra/newview/skins/default/textures/bottomtray/VoicePTT_Lvl3_Dark.png b/indra/newview/skins/default/textures/bottomtray/VoicePTT_Lvl3_Dark.png
deleted file mode 100644
index 135a66ca0d..0000000000
--- a/indra/newview/skins/default/textures/bottomtray/VoicePTT_Lvl3_Dark.png
+++ /dev/null
Binary files differ
diff --git a/indra/newview/skins/default/textures/bottomtray/VoicePTT_Off_Dark.png b/indra/newview/skins/default/textures/bottomtray/VoicePTT_Off_Dark.png
deleted file mode 100644
index a63aec5e6d..0000000000
--- a/indra/newview/skins/default/textures/bottomtray/VoicePTT_Off_Dark.png
+++ /dev/null
Binary files differ
diff --git a/indra/newview/skins/default/textures/bottomtray/VoicePTT_On_Dark.png b/indra/newview/skins/default/textures/bottomtray/VoicePTT_On_Dark.png
deleted file mode 100644
index 1719eb3e84..0000000000
--- a/indra/newview/skins/default/textures/bottomtray/VoicePTT_On_Dark.png
+++ /dev/null
Binary files differ
diff --git a/indra/newview/skins/default/textures/textures.xml b/indra/newview/skins/default/textures/textures.xml
index 8d9fa52309..bf6e933dfd 100644
--- a/indra/newview/skins/default/textures/textures.xml
+++ b/indra/newview/skins/default/textures/textures.xml
@@ -365,8 +365,6 @@ with the same filename but different name
<texture name="Nearby_chat_icon" file_name="icons/nearby_chat_icon.png" preload="false" />
- <texture name="Notices_Unread" file_name="bottomtray/Notices_Unread.png" preload="true" />
-
<texture name="NoEntryLines" file_name="world/NoEntryLines.png" use_mips="true" preload="false" />
<texture name="NoEntryPassLines" file_name="world/NoEntryPassLines.png" use_mips="true" preload="false" />
@@ -654,12 +652,6 @@ with the same filename but different name
<texture name="VoicePTT_Off" file_name="bottomtray/VoicePTT_Off.png" preload="false" />
<texture name="VoicePTT_On" file_name="bottomtray/VoicePTT_On.png" preload="false" />
- <texture name="VoicePTT_Lvl1_Dark" file_name="bottomtray/VoicePTT_Lvl1_Dark.png" preload="false" />
- <texture name="VoicePTT_Lvl2_Dark" file_name="bottomtray/VoicePTT_Lvl2_Dark.png" preload="false" />
- <texture name="VoicePTT_Lvl3_Dark" file_name="bottomtray/VoicePTT_Lvl3_Dark.png" preload="false" />
- <texture name="VoicePTT_Off_Dark" file_name="bottomtray/VoicePTT_Off_Dark.png" preload="false" />
- <texture name="VoicePTT_On_Dark" file_name="bottomtray/VoicePTT_On_Dark.png" preload="false" />
-
<texture name="Wearables_Divider" file_name="windows/Wearables_Divider.png" preload="false" />
<texture name="Web_Profile_Off" file_name="icons/Web_Profile_Off.png" preload="false" />
diff --git a/indra/newview/skins/default/xui/da/menu_im_well_button.xml b/indra/newview/skins/default/xui/da/menu_im_well_button.xml
deleted file mode 100644
index 4889230919..0000000000
--- a/indra/newview/skins/default/xui/da/menu_im_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="IM Well Button Context Menu">
- <menu_item_call label="Luk alle" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/da/menu_notification_well_button.xml b/indra/newview/skins/default/xui/da/menu_notification_well_button.xml
deleted file mode 100644
index 40b35b5fdd..0000000000
--- a/indra/newview/skins/default/xui/da/menu_notification_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="Notification Well Button Context Menu">
- <menu_item_call label="Luk alle" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/de/menu_im_well_button.xml b/indra/newview/skins/default/xui/de/menu_im_well_button.xml
deleted file mode 100644
index f464b71f4a..0000000000
--- a/indra/newview/skins/default/xui/de/menu_im_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="IM Well Button Context Menu">
- <menu_item_call label="Alle schließen" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/de/menu_notification_well_button.xml b/indra/newview/skins/default/xui/de/menu_notification_well_button.xml
deleted file mode 100644
index 0f2784f160..0000000000
--- a/indra/newview/skins/default/xui/de/menu_notification_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="Notification Well Button Context Menu">
- <menu_item_call label="Alle schließen" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/en/floater_camera.xml b/indra/newview/skins/default/xui/en/floater_camera.xml
index 22bc488a92..4b4821a383 100644
--- a/indra/newview/skins/default/xui/en/floater_camera.xml
+++ b/indra/newview/skins/default/xui/en/floater_camera.xml
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater
positioning="specified"
- left="458"
+ left="643"
bottom="-80"
follows="left|bottom"
legacy_header_height="18"
diff --git a/indra/newview/skins/default/xui/en/floater_destinations.xml b/indra/newview/skins/default/xui/en/floater_destinations.xml
index 39aa8e07bb..41b57530fc 100644
--- a/indra/newview/skins/default/xui/en/floater_destinations.xml
+++ b/indra/newview/skins/default/xui/en/floater_destinations.xml
@@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater
- positioning="cascading"
ignore_ui_scale="false"
legacy_header_height="225"
can_minimize="true"
@@ -12,16 +11,18 @@
height="230"
layout="topleft"
name="Destinations"
+ right="-10"
+ bottom="-80"
single_instance="true"
help_topic="destinations"
save_rect="true"
save_visibility="true"
title="DESTINATIONS"
- width="840">
+ width="550">
<web_browser
top="25"
height="200"
- width="840"
+ width="550"
follows="all"
name="destination_guide_contents"
trusted_content="true"/>
diff --git a/indra/newview/skins/default/xui/en/floater_im_container.xml b/indra/newview/skins/default/xui/en/floater_im_container.xml
index 4aa7c88312..152c897120 100644
--- a/indra/newview/skins/default/xui/en/floater_im_container.xml
+++ b/indra/newview/skins/default/xui/en/floater_im_container.xml
@@ -3,7 +3,7 @@
can_close="true"
can_minimize="true"
can_resize="true"
- height="430"
+ height="230"
layout="topleft"
min_height="50"
name="floater_im_box"
@@ -13,7 +13,8 @@
single_instance="true"
reuse_instance="true"
title="CONVERSATIONS"
- width="680">
+ bottom="-80"
+ width="450">
<string
name="collapse_icon"
value="Conv_toolbar_collapse"/>
@@ -23,13 +24,13 @@
<layout_stack
animate="true"
follows="all"
- height="430"
+ height="230"
layout="topleft"
left="0"
name="conversations_stack"
orientation="horizontal"
top="0"
- width="680">
+ width="450">
<layout_panel
auto_resize="true"
user_resize="true"
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 1d74f1bc25..faf54774f6 100644
--- a/indra/newview/skins/default/xui/en/floater_im_session.xml
+++ b/indra/newview/skins/default/xui/en/floater_im_session.xml
@@ -43,6 +43,12 @@
<floater.string
name="tooltip_to_main_window"
value="Move this conversation back to main window"/>
+ <floater.string
+ name="start_call_button_tooltip"
+ value="Open voice connection"/>
+ <floater.string
+ name="end_call_button_tooltip"
+ value="Close voice connection"/>
<view
follows="all"
layout="topleft"
diff --git a/indra/newview/skins/default/xui/en/floater_moveview.xml b/indra/newview/skins/default/xui/en/floater_moveview.xml
index 4e7ee7913f..02d9805ddf 100644
--- a/indra/newview/skins/default/xui/en/floater_moveview.xml
+++ b/indra/newview/skins/default/xui/en/floater_moveview.xml
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater
positioning="specified"
- left="320"
+ left="505"
bottom="-80"
legacy_header_height="18"
can_dock="false"
diff --git a/indra/newview/skins/default/xui/en/menu_conversation.xml b/indra/newview/skins/default/xui/en/menu_conversation.xml
index 908b2c174f..01ef8ebdb5 100644
--- a/indra/newview/skins/default/xui/en/menu_conversation.xml
+++ b/indra/newview/skins/default/xui/en/menu_conversation.xml
@@ -105,14 +105,22 @@
<on_enable function="Avatar.EnableItem" parameter="can_pay" />
</menu_item_call>
<menu_item_check
- label="Block / unblock"
+ label="Block Voice"
layout="topleft"
name="block_unblock">
<on_click function="Avatar.DoToSelected" parameter="block_unblock" />
<on_check function="Avatar.CheckItem" parameter="is_blocked" />
<on_enable function="Avatar.EnableItem" parameter="can_block" />
</menu_item_check>
- <menu_item_call
+ <menu_item_check
+ label="Block Text"
+ layout="topleft"
+ name="MuteText">
+ <on_click function="Avatar.DoToSelected" parameter="mute_unmute" />
+ <on_check function="Avatar.CheckItem" parameter="is_muted" />
+ <on_enable function="Avatar.EnableItem" parameter="can_block" />
+ </menu_item_check>
+ <menu_item_call
label="Group Profile"
layout="topleft"
name="group_profile">
diff --git a/indra/newview/skins/default/xui/en/menu_notification_well_button.xml b/indra/newview/skins/default/xui/en/menu_notification_well_button.xml
deleted file mode 100644
index 263ac40f4e..0000000000
--- a/indra/newview/skins/default/xui/en/menu_notification_well_button.xml
+++ /dev/null
@@ -1,16 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
-<context_menu
- layout="topleft"
- name="Notification Well Button Context Menu">
- <menu_item_call
- label="Close All"
- layout="topleft"
- name="Close All">
- <menu_item_call.on_click
- function="NotificationWellChicletMenu.Action"
- parameter="close all" />
- <menu_item_call.on_enable
- function="NotificationWellChicletMenu.EnableItem"
- parameter="can close all" />
- </menu_item_call>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/en/panel_activeim_row.xml b/indra/newview/skins/default/xui/en/panel_activeim_row.xml
deleted file mode 100644
index 9369d1b5cf..0000000000
--- a/indra/newview/skins/default/xui/en/panel_activeim_row.xml
+++ /dev/null
@@ -1,97 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
-<panel
- name="panel_activeim_row"
- layout="topleft"
- follows="left|right"
- top="0"
- left="0"
- height="35"
- width="318"
- background_opaque="false"
- background_visible="true"
- bg_alpha_color="0.0 0.0 0.0 0.0" >
- <chiclet_im_p2p
- name="p2p_chiclet"
- layout="topleft"
- follows="left"
- top="3"
- left="5"
- height="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">
- </chiclet_im_p2p>
- <chiclet_im_group
- name="group_chiclet"
- layout="topleft"
- follows="left"
- top="3"
- left="5"
- height="25"
- 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">
- </chiclet_im_group>
- <chiclet_im_adhoc
- name="adhoc_chiclet"
- layout="topleft"
- follows="left"
- top="3"
- left="5"
- height="25"
- width="25"
- visible="false"
- speaker.name="speaker_hoc"
- speaker.width="20"
- speaker.height="25"
- speaker.left="25"
- speaker.top="25"
- speaker.auto_update="true"
- speaker.draw_border="false"
- speaker.visible="false">
- </chiclet_im_adhoc>
- <text
- translate="false"
- type="string"
- name="contact_name"
- layout="topleft"
- top="10"
- left_pad="10"
- height="14"
- width="250"
- length="1"
- follows="right|left"
- parse_urls="false"
- use_ellipses="true"
- font="SansSerifBold">
- TestString PleaseIgnore
- </text>
- <button
- top="10"
- right="-5"
- width="17"
- height="17"
- layout="topleft"
- follows="right"
- name="hide_btn"
- mouse_opaque="true"
- label=""
- tab_stop="false"
- image_unselected="Toast_CloseBtn"
- image_selected="Toast_CloseBtn"
- />
-</panel> \ No newline at end of file
diff --git a/indra/newview/skins/default/xui/en/panel_chiclet_bar.xml b/indra/newview/skins/default/xui/en/panel_chiclet_bar.xml
index fc321fdd23..390047d493 100644
--- a/indra/newview/skins/default/xui/en/panel_chiclet_bar.xml
+++ b/indra/newview/skins/default/xui/en/panel_chiclet_bar.xml
@@ -77,49 +77,5 @@
width="12" />
</chiclet_panel>
</layout_panel>
- <layout_panel auto_resize="false"
- width="4"
- min_width="4"/>
- <layout_panel
- auto_resize="false"
- follows="right"
- height="28"
- layout="topleft"
- min_height="28"
- min_width="37"
- name="notification_well_panel"
- top="0"
- width="37">
- <chiclet_notification
- follows="right"
- height="23"
- layout="topleft"
- left="0"
- max_displayed_count="99"
- name="notification_well"
- top="5"
- width="35">
- <button
- auto_resize="false"
- bottom_pad="3"
- follows="right"
- halign="center"
- height="23"
- image_overlay="Notices_Unread"
- image_overlay_alignment="center"
- image_pressed="WellButton_Lit"
- image_pressed_selected="WellButton_Lit_Selected"
- image_selected="PushButton_Press"
- label_color="Black"
- left="0"
- name="Unread"
- tool_tip="Notifications"
- width="34">
- <init_callback
- function="Button.SetDockableFloaterToggle"
- parameter="notification_well_window" />
- </button>
- </chiclet_notification>
- </layout_panel>
</layout_stack>
</panel>
diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml
index a884ac94d6..c75bd98c38 100644
--- a/indra/newview/skins/default/xui/en/strings.xml
+++ b/indra/newview/skins/default/xui/en/strings.xml
@@ -3400,7 +3400,7 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
Connecting...
</string>
<string name="conference-title">
- Ad-hoc Conference
+ Multi-person chat
</string>
<string name="conference-title-incoming">
Conference with [AGENT_NAME]
diff --git a/indra/newview/skins/default/xui/en/widgets/chiclet_im_adhoc.xml b/indra/newview/skins/default/xui/en/widgets/chiclet_im_adhoc.xml
deleted file mode 100644
index 0e29ed0d0b..0000000000
--- a/indra/newview/skins/default/xui/en/widgets/chiclet_im_adhoc.xml
+++ /dev/null
@@ -1,55 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
-<chiclet_im_adhoc
- height="23"
- name="im_adhoc_chiclet"
- show_speaker="false"
- width="25">
- <chiclet_im_adhoc.chiclet_button
- height="25"
- image_selected="PushButton_On"
- image_unselected="PushButton_Off"
- name="chiclet_button"
- tab_stop="false"
- width="25" />
- <chiclet_im_adhoc.speaker
- image_mute="Parcel_VoiceNo_Light"
- image_off="VoicePTT_Off_Dark"
- image_on="VoicePTT_On_Dark"
- image_level_1="VoicePTT_Lvl1_Dark"
- image_level_2="VoicePTT_Lvl2_Dark"
- image_level_3="VoicePTT_Lvl3_Dark"
- auto_update="true"
- draw_border="false"
- height="24"
- left="25"
- bottom="1"
- name="speaker"
- visible="false"
- width="20" />
- <chiclet_im_adhoc.avatar_icon
- bottom="3"
- follows="left|top|bottom"
- height="20"
- left="2"
- mouse_opaque="false"
- name="adhoc_icon"
- width="21" />
- <chiclet_im_adhoc.unread_notifications
- halign="center"
- height="23"
- left="25"
- mouse_opaque="false"
- name="unread"
- text_color="white"
- v_pad="3"
- visible="false"
- width="20" />
- <chiclet_im_adhoc.new_message_icon
- bottom="11"
- height="14"
- image_name="Unread_Chiclet"
- left="12"
- name="new_message_icon"
- visible="false"
- width="14" />
-</chiclet_im_adhoc> \ No newline at end of file
diff --git a/indra/newview/skins/default/xui/en/widgets/chiclet_im_group.xml b/indra/newview/skins/default/xui/en/widgets/chiclet_im_group.xml
deleted file mode 100644
index 77011139bf..0000000000
--- a/indra/newview/skins/default/xui/en/widgets/chiclet_im_group.xml
+++ /dev/null
@@ -1,56 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
-<chiclet_im_group
- height="23"
- name="im_group_chiclet"
- show_speaker="false"
- width="25">
- <chiclet_im_group.chiclet_button
- height="25"
- image_selected="PushButton_On"
- image_unselected="PushButton_Off"
- name="chiclet_button"
- tab_stop="false"
- width="25" />
- <chiclet_im_group.speaker
- image_mute="Parcel_VoiceNo_Light"
- image_off="VoicePTT_Off_Dark"
- image_on="VoicePTT_On_Dark"
- image_level_1="VoicePTT_Lvl1_Dark"
- image_level_2="VoicePTT_Lvl2_Dark"
- image_level_3="VoicePTT_Lvl3_Dark"
- auto_update="true"
- draw_border="false"
- height="24"
- left="25"
- bottom="1"
- name="speaker"
- visible="false"
- width="20" />
- <chiclet_im_group.group_icon
- bottom="3"
- default_icon="Generic_Group"
- follows="left|top|bottom"
- height="20"
- left="2"
- mouse_opaque="false"
- name="group_icon"
- width="21" />
- <chiclet_im_group.unread_notifications
- height="23"
- halign="center"
- left="25"
- mouse_opaque="false"
- name="unread"
- text_color="white"
- v_pad="3"
- visible="false"
- width="20"/>
- <chiclet_im_group.new_message_icon
-bottom="11"
- height="14"
- image_name="Unread_Chiclet"
- left="12"
- name="new_message_icon"
- visible="false"
- width="14" />
-</chiclet_im_group> \ No newline at end of file
diff --git a/indra/newview/skins/default/xui/en/widgets/chiclet_im_p2p.xml b/indra/newview/skins/default/xui/en/widgets/chiclet_im_p2p.xml
deleted file mode 100644
index 8b56a8f0f6..0000000000
--- a/indra/newview/skins/default/xui/en/widgets/chiclet_im_p2p.xml
+++ /dev/null
@@ -1,56 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
-<chiclet_im_p2p
- height="23"
- name="im_p2p_chiclet"
- show_speaker="false"
- width="25">
- <chiclet_im_p2p.chiclet_button
- height="25"
- image_selected="PushButton_On"
- image_unselected="PushButton_Off"
- name="chiclet_button"
- tab_stop="false"
- width="25"/>
- <chiclet_im_p2p.speaker
- image_mute="Parcel_VoiceNo_Light"
- image_off="VoicePTT_Off_Dark"
- image_on="VoicePTT_On_Dark"
- image_level_1="VoicePTT_Lvl1_Dark"
- image_level_2="VoicePTT_Lvl2_Dark"
- image_level_3="VoicePTT_Lvl3_Dark"
- auto_update="true"
- draw_border="false"
- height="24"
- left="25"
- bottom="1"
- name="speaker"
- visible="false"
- width="20" />
- <chiclet_im_p2p.avatar_icon
- bottom="3"
- color="white"
- follows="left|top|bottom"
- height="20"
- left="2"
- mouse_opaque="false"
- name="avatar_icon"
- width="21" />
- <chiclet_im_p2p.unread_notifications
- height="23"
- halign="center"
- left="25"
- mouse_opaque="false"
- name="unread"
- text_color="white"
- v_pad="3"
- visible="false"
- width="20"/>
- <chiclet_im_p2p.new_message_icon
- bottom="11"
- height="14"
- image_name="Unread_Chiclet"
- left="12"
- name="new_message_icon"
- visible="false"
- width="14" />
-</chiclet_im_p2p>
diff --git a/indra/newview/skins/default/xui/es/menu_im_well_button.xml b/indra/newview/skins/default/xui/es/menu_im_well_button.xml
deleted file mode 100644
index c8f6c217cc..0000000000
--- a/indra/newview/skins/default/xui/es/menu_im_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="IM Well Button Context Menu">
- <menu_item_call label="Cerrar todo" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/es/menu_notification_well_button.xml b/indra/newview/skins/default/xui/es/menu_notification_well_button.xml
deleted file mode 100644
index 0562d35be7..0000000000
--- a/indra/newview/skins/default/xui/es/menu_notification_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="Notification Well Button Context Menu">
- <menu_item_call label="Cerrar todo" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/fr/menu_im_well_button.xml b/indra/newview/skins/default/xui/fr/menu_im_well_button.xml
deleted file mode 100644
index 8ef1529e6b..0000000000
--- a/indra/newview/skins/default/xui/fr/menu_im_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="IM Well Button Context Menu">
- <menu_item_call label="Tout fermer" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/fr/menu_notification_well_button.xml b/indra/newview/skins/default/xui/fr/menu_notification_well_button.xml
deleted file mode 100644
index 323bfdbf16..0000000000
--- a/indra/newview/skins/default/xui/fr/menu_notification_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="Notification Well Button Context Menu">
- <menu_item_call label="Tout fermer" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/it/menu_im_well_button.xml b/indra/newview/skins/default/xui/it/menu_im_well_button.xml
deleted file mode 100644
index 9e471b771c..0000000000
--- a/indra/newview/skins/default/xui/it/menu_im_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="IM Well Button Context Menu">
- <menu_item_call label="Chiudi tutto" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/it/menu_notification_well_button.xml b/indra/newview/skins/default/xui/it/menu_notification_well_button.xml
deleted file mode 100644
index 8c82e30f0e..0000000000
--- a/indra/newview/skins/default/xui/it/menu_notification_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="Notification Well Button Context Menu">
- <menu_item_call label="Chiudi tutto" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/ja/menu_im_well_button.xml b/indra/newview/skins/default/xui/ja/menu_im_well_button.xml
deleted file mode 100644
index 3397004bd7..0000000000
--- a/indra/newview/skins/default/xui/ja/menu_im_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="IM Well Button Context Menu">
- <menu_item_call label="すべて閉じる" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/ja/menu_notification_well_button.xml b/indra/newview/skins/default/xui/ja/menu_notification_well_button.xml
deleted file mode 100644
index 913bae8958..0000000000
--- a/indra/newview/skins/default/xui/ja/menu_notification_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="Notification Well Button Context Menu">
- <menu_item_call label="すべて閉じる" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/pl/menu_im_well_button.xml b/indra/newview/skins/default/xui/pl/menu_im_well_button.xml
deleted file mode 100644
index 207bc2211b..0000000000
--- a/indra/newview/skins/default/xui/pl/menu_im_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="IM Well Button Context Menu">
- <menu_item_call label="Zamknij wszystkie" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/pl/menu_notification_well_button.xml b/indra/newview/skins/default/xui/pl/menu_notification_well_button.xml
deleted file mode 100644
index bd3d42f9b1..0000000000
--- a/indra/newview/skins/default/xui/pl/menu_notification_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="Notification Well Button Context Menu">
- <menu_item_call label="Zamknij" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/pt/menu_im_well_button.xml b/indra/newview/skins/default/xui/pt/menu_im_well_button.xml
deleted file mode 100644
index 2d37cefd6f..0000000000
--- a/indra/newview/skins/default/xui/pt/menu_im_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="IM Well Button Context Menu">
- <menu_item_call label="Fechar tudo" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/pt/menu_notification_well_button.xml b/indra/newview/skins/default/xui/pt/menu_notification_well_button.xml
deleted file mode 100644
index 43ad4134ec..0000000000
--- a/indra/newview/skins/default/xui/pt/menu_notification_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="Notification Well Button Context Menu">
- <menu_item_call label="Fechar tudo" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/ru/menu_im_well_button.xml b/indra/newview/skins/default/xui/ru/menu_im_well_button.xml
deleted file mode 100644
index 5a5bde61b9..0000000000
--- a/indra/newview/skins/default/xui/ru/menu_im_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="IM Well Button Context Menu">
- <menu_item_call label="Закрыть все" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/ru/menu_notification_well_button.xml b/indra/newview/skins/default/xui/ru/menu_notification_well_button.xml
deleted file mode 100644
index 4d067e232a..0000000000
--- a/indra/newview/skins/default/xui/ru/menu_notification_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="Notification Well Button Context Menu">
- <menu_item_call label="Закрыть все" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/tr/menu_im_well_button.xml b/indra/newview/skins/default/xui/tr/menu_im_well_button.xml
deleted file mode 100644
index c3e559a723..0000000000
--- a/indra/newview/skins/default/xui/tr/menu_im_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="IM Well Button Context Menu">
- <menu_item_call label="Tümünü Kapat" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/tr/menu_notification_well_button.xml b/indra/newview/skins/default/xui/tr/menu_notification_well_button.xml
deleted file mode 100644
index 39c66268f5..0000000000
--- a/indra/newview/skins/default/xui/tr/menu_notification_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="Notification Well Button Context Menu">
- <menu_item_call label="Tümünü Kapat" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/zh/menu_im_well_button.xml b/indra/newview/skins/default/xui/zh/menu_im_well_button.xml
deleted file mode 100644
index 4b9b4b2758..0000000000
--- a/indra/newview/skins/default/xui/zh/menu_im_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="IM Well Button Context Menu">
- <menu_item_call label="全部關閉" name="Close All"/>
-</context_menu>
diff --git a/indra/newview/skins/default/xui/zh/menu_notification_well_button.xml b/indra/newview/skins/default/xui/zh/menu_notification_well_button.xml
deleted file mode 100644
index b629f73584..0000000000
--- a/indra/newview/skins/default/xui/zh/menu_notification_well_button.xml
+++ /dev/null
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8" standalone="yes"?>
-<context_menu name="Notification Well Button Context Menu">
- <menu_item_call label="全部關閉" name="Close All"/>
-</context_menu>