Automated merge with file:///Users/oz/Work/viewer-development

meow-7.2.2
Oz Linden 2010-10-15 22:19:57 -04:00
commit 18ade97fa6
6 changed files with 21 additions and 35 deletions

View File

@ -5783,13 +5783,13 @@
<key>ToastGap</key>
<map>
<key>Comment</key>
<string>Gap between toasts on a screen</string>
<string>Gap between toasts on a screen (min. value is 5)</string>
<key>Persist</key>
<integer>1</integer>
<key>Type</key>
<string>S32</string>
<key>Value</key>
<integer>5</integer>
<integer>7</integer>
</map>
<key>ToastButtonWidth</key>
<map>

View File

@ -253,8 +253,8 @@ void LLScreenChannel::addToast(const LLToast::Params& p)
if(mControlHovering)
{
new_toast_elem.toast->setOnToastHoverCallback(boost::bind(&LLScreenChannel::onToastHover, this, _1, _2));
new_toast_elem.toast->setMouseEnterCallback(boost::bind(&LLScreenChannel::stopFadingToasts, this));
new_toast_elem.toast->setMouseLeaveCallback(boost::bind(&LLScreenChannel::startFadingToasts, this));
new_toast_elem.toast->setMouseEnterCallback(boost::bind(&LLScreenChannel::stopFadingToast, this, new_toast_elem.toast));
new_toast_elem.toast->setMouseLeaveCallback(boost::bind(&LLScreenChannel::startFadingToast, this, new_toast_elem.toast));
}
if(show_toast)
@ -339,7 +339,6 @@ void LLScreenChannel::deleteToast(LLToast* toast)
if(mHoveredToast == toast)
{
mHoveredToast = NULL;
startFadingToasts();
}
// close the toast
@ -698,38 +697,23 @@ void LLScreenChannel::closeStartUpToast()
}
}
void LLNotificationsUI::LLScreenChannel::stopFadingToasts()
void LLNotificationsUI::LLScreenChannel::stopFadingToast(LLToast* toast)
{
if (!mToastList.size()) return;
if (!toast || toast != mHoveredToast) return;
if (!mHoveredToast) return;
std::vector<ToastElem>::iterator it = mToastList.begin();
while (it != mToastList.end())
{
ToastElem& elem = *it;
elem.toast->stopFading();
++it;
}
// Pause fade timer of the hovered toast.
toast->stopFading();
}
void LLNotificationsUI::LLScreenChannel::startFadingToasts()
void LLNotificationsUI::LLScreenChannel::startFadingToast(LLToast* toast)
{
if (!mToastList.size()) return;
//because onMouseLeave is processed after onMouseEnter
if (isHovering()) return;
std::vector<ToastElem>::iterator it = mToastList.begin();
while (it != mToastList.end())
if (!toast || toast == mHoveredToast)
{
ToastElem& elem = *it;
if (elem.toast->getVisible())
{
elem.toast->startFading();
}
++it;
return;
}
// Reset its fade timer.
toast->startFading();
}
//--------------------------------------------------------------------------

View File

@ -193,11 +193,11 @@ public:
void closeStartUpToast();
/** Stop fading all toasts */
virtual void stopFadingToasts();
/** Stop fading given toast */
virtual void stopFadingToast(LLToast* toast);
/** Start fading all toasts */
virtual void startFadingToasts();
/** Start fading given toast */
virtual void startFadingToast(LLToast* toast);
// get StartUp Toast's state
static bool getStartUpToastShown() { return mWasStartUpToastShown; }

View File

@ -102,6 +102,7 @@ LLToast::LLToast(const LLToast::Params& p)
if(!p.on_delete_toast().empty())
mOnDeleteToastSignal.connect(p.on_delete_toast());
// *TODO: This signal doesn't seem to be used at all.
if(!p.on_mouse_enter().empty())
mOnMouseEnterSignal.connect(p.on_mouse_enter());
}

View File

@ -155,7 +155,7 @@
visiblity_control="ShowAdvancedGraphicsSettings"
border="false"
follows="top|left"
height="283"
height="300"
label="CustomGraphics"
layout="topleft"
left="5"

View File

@ -19,6 +19,7 @@
font="SansSerif">
<more_chat_text
mouse_opaque="true"
parse_urls="false"
word_wrap="true"
/>
</chat_history>