diff options
author | Dmitry Oleshko <doleshko@productengine.com> | 2009-12-18 15:58:37 +0200 |
---|---|---|
committer | Dmitry Oleshko <doleshko@productengine.com> | 2009-12-18 15:58:37 +0200 |
commit | f3a92bfc17762c7f0ade6b93f27d7a499031e463 (patch) | |
tree | 6b2af8ad271edc643b629559d0b81ca2f4abede2 /indra/newview/llsyswellwindow.cpp | |
parent | 55ff23cdad73882fdbf0a4959c1ca8fbf6ada315 (diff) |
implemented major task (EXT-3354) Add "unread message" counters for IM sessions in the IM well window
- IM Well Window's chiclets now have counters and count IMs from 1 to "99+"
- IM Well Window's items can resize on appearance of chiclet's counter or speaker indicator
--HG--
branch : product-engine
Diffstat (limited to 'indra/newview/llsyswellwindow.cpp')
-rw-r--r-- | indra/newview/llsyswellwindow.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/indra/newview/llsyswellwindow.cpp b/indra/newview/llsyswellwindow.cpp index 7bff06e9a3..1aeafaea5a 100644 --- a/indra/newview/llsyswellwindow.cpp +++ b/indra/newview/llsyswellwindow.cpp @@ -350,6 +350,8 @@ LLIMWellWindow::RowPanel::RowPanel(const LLSysWellWindow* parent, const LLUUID& } // Initialize chiclet. + mChiclet->setChicletSizeChangedCallback(boost::bind(&LLIMWellWindow::RowPanel::onChicletSizeChanged, this, mChiclet, _2)); + mChiclet->enableCounterControl(true); mChiclet->setCounter(chicletCounter); mChiclet->setSessionId(sessionId); mChiclet->setIMSessionName(name); @@ -364,6 +366,16 @@ LLIMWellWindow::RowPanel::RowPanel(const LLSysWellWindow* parent, const LLUUID& } //--------------------------------------------------------------------------------- +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->setRect(text_rect); +} + +//--------------------------------------------------------------------------------- LLIMWellWindow::RowPanel::~RowPanel() { } |