From 3081f89744ab527af4c843bdf898654d4ba87b57 Mon Sep 17 00:00:00 2001 From: Richard Nelson Date: Mon, 4 Oct 2010 19:07:28 -0700 Subject: EXP-138 FIXED Chat and IM notices not aligned with Bottom bar in Skylight Viewer --- indra/newview/llscreenchannel.cpp | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) (limited to 'indra/newview/llscreenchannel.cpp') diff --git a/indra/newview/llscreenchannel.cpp b/indra/newview/llscreenchannel.cpp index 5c923a0409..b90ff80294 100644 --- a/indra/newview/llscreenchannel.cpp +++ b/indra/newview/llscreenchannel.cpp @@ -136,12 +136,22 @@ void LLScreenChannelBase::init(S32 channel_left, S32 channel_right) side_bar->getCollapseSignal().connect(boost::bind(&LLScreenChannelBase::resetPositionAndSize, this, _2)); } + // top and bottom set by updateBottom() + setRect(LLRect(channel_left, 0, channel_right, 0)); + updateBottom(); + setVisible(TRUE); +} + +void LLScreenChannelBase::updateBottom() +{ S32 channel_top = gViewerWindow->getWorldViewRectScaled().getHeight(); S32 channel_bottom = gViewerWindow->getWorldViewRectScaled().mBottom + gSavedSettings.getS32("ChannelBottomPanelMargin"); + S32 channel_left = getRect().mLeft; + S32 channel_right = getRect().mRight; setRect(LLRect(channel_left, channel_top, channel_right, channel_bottom)); - setVisible(TRUE); } + //-------------------------------------------------------------------------- ////////////////////// // LLScreenChannel @@ -512,6 +522,8 @@ void LLScreenChannel::showToastsBottom() S32 toast_margin = 0; std::vector::reverse_iterator it; + updateBottom(); + LLDockableFloater* floater = dynamic_cast(LLDockableFloater::getInstanceHandle().get()); for(it = mToastList.rbegin(); it != mToastList.rend(); ++it) @@ -866,13 +878,7 @@ void LLScreenChannel::updateShowToastsState() return; } - S32 channel_bottom = gViewerWindow->getWorldViewRectScaled().mBottom + gSavedSettings.getS32("ChannelBottomPanelMargin");; - LLRect this_rect = getRect(); - - if(channel_bottom != this_rect.mBottom) - { - setRect(LLRect(this_rect.mLeft, this_rect.mTop, this_rect.mRight, channel_bottom)); - } + updateBottom(); } //-------------------------------------------------------------------------- -- cgit v1.2.3 From 38a182f62fcdd3c8e684459bf29a434bf36dbce2 Mon Sep 17 00:00:00 2001 From: Richard Linden Date: Mon, 1 Nov 2010 13:45:55 -0700 Subject: EXP-371 Chat/IM bubble notifications not aligned with bottom bar --- indra/newview/llscreenchannel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/llscreenchannel.cpp') diff --git a/indra/newview/llscreenchannel.cpp b/indra/newview/llscreenchannel.cpp index b90ff80294..5a36393f28 100644 --- a/indra/newview/llscreenchannel.cpp +++ b/indra/newview/llscreenchannel.cpp @@ -145,7 +145,7 @@ void LLScreenChannelBase::init(S32 channel_left, S32 channel_right) void LLScreenChannelBase::updateBottom() { S32 channel_top = gViewerWindow->getWorldViewRectScaled().getHeight(); - S32 channel_bottom = gViewerWindow->getWorldViewRectScaled().mBottom + gSavedSettings.getS32("ChannelBottomPanelMargin"); + S32 channel_bottom = gSavedSettings.getS32("ChannelBottomPanelMargin"); S32 channel_left = getRect().mLeft; S32 channel_right = getRect().mRight; setRect(LLRect(channel_left, channel_top, channel_right, channel_bottom)); -- cgit v1.2.3