diff options
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/app_settings/settings.xml | 2 | ||||
-rw-r--r-- | indra/newview/llimfloater.cpp | 1 | ||||
-rw-r--r-- | indra/newview/llscreenchannel.cpp | 27 | ||||
-rw-r--r-- | indra/newview/llscreenchannel.h | 3 | ||||
-rw-r--r-- | indra/newview/llsyswellwindow.cpp | 1 |
5 files changed, 14 insertions, 20 deletions
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index 20d81362fd..08a65461b6 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -5033,7 +5033,7 @@ <key>NotificationChannelHeightRatio</key> <map> <key>Comment</key> - <string>TODO</string> + <string>Notification channel and World View ratio(0.0 - always show 1 notification, 1.0 - max ratio).</string> <key>Persist</key> <integer>1</integer> <key>Type</key> diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp index 36c40eb49b..40ae112e4b 100644 --- a/indra/newview/llimfloater.cpp +++ b/indra/newview/llimfloater.cpp @@ -415,6 +415,7 @@ void LLIMFloater::setDocked(bool docked, bool pop_on_undock) if(channel) { channel->updateShowToastsState(); + channel->redrawToasts(); } } diff --git a/indra/newview/llscreenchannel.cpp b/indra/newview/llscreenchannel.cpp index 87752e31f5..a1ea7aeb96 100644 --- a/indra/newview/llscreenchannel.cpp +++ b/indra/newview/llscreenchannel.cpp @@ -375,12 +375,6 @@ void LLScreenChannel::modifyToastByNotificationID(LLUUID id, LLPanel* panel) } } -void LLScreenChannel::onVisibleChanged(LLUICtrl* ctrl, const LLSD& param) -{ - updateShowToastsState(); - redrawToasts(); -} - //-------------------------------------------------------------------------- void LLScreenChannel::redrawToasts() { @@ -446,17 +440,11 @@ void LLScreenChannel::showToastsBottom() if( !(*it).toast->getVisible() ) { - if((*it).toast->isFirstLook()) - { - (*it).toast->setVisible(TRUE); - } - else - { - // HACK - // EXT-2653: it is necessary to prevent overlapping for secondary showed toasts - (*it).toast->setVisible(TRUE); - gFloaterView->sendChildToBack((*it).toast); - } + // HACK + // EXT-2653: it is necessary to prevent overlapping for secondary showed toasts + (*it).toast->setVisible(TRUE); + // Show toast behind floaters. (EXT-3089) + gFloaterView->sendChildToBack((*it).toast); } } @@ -774,7 +762,7 @@ void LLScreenChannel::onToastHover(LLToast* toast, bool mouse_enter) //-------------------------------------------------------------------------- void LLScreenChannel::updateShowToastsState() { - LLFloater* floater = LLDockableFloater::getInstanceHandle().get(); + LLDockableFloater* floater = dynamic_cast<LLDockableFloater*>(LLDockableFloater::getInstanceHandle().get()); if(!floater) { @@ -791,7 +779,8 @@ void LLScreenChannel::updateShowToastsState() LLRect this_rect = getRect(); if(floater->getVisible() && floater->isDocked()) { - channel_bottom = floater->getRect().mTop + gSavedSettings.getS32("ToastGap"); + channel_bottom += floater->getRect().getHeight(); + channel_bottom += floater->getDockControl()->getTongueHeight(); } if(channel_bottom != this_rect.mBottom) diff --git a/indra/newview/llscreenchannel.h b/indra/newview/llscreenchannel.h index e384b17a0c..3b0ee2050c 100644 --- a/indra/newview/llscreenchannel.h +++ b/indra/newview/llscreenchannel.h @@ -265,6 +265,9 @@ private: // create the StartUp Toast void createStartUpToast(S32 notif_num, F32 timer); + /** + * Notification channel and World View ratio(0.0 - always show 1 notification, 1.0 - max ratio). + */ static F32 getHeightRatio(); // Channel's flags diff --git a/indra/newview/llsyswellwindow.cpp b/indra/newview/llsyswellwindow.cpp index 26caf0be69..28bdfbf271 100644 --- a/indra/newview/llsyswellwindow.cpp +++ b/indra/newview/llsyswellwindow.cpp @@ -189,6 +189,7 @@ void LLSysWellWindow::setDocked(bool docked, bool pop_on_undock) if(mChannel) { mChannel->updateShowToastsState(); + mChannel->redrawToasts(); } } |