summaryrefslogtreecommitdiff
path: root/indra/newview/lltoast.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/lltoast.cpp')
-rw-r--r--indra/newview/lltoast.cpp27
1 files changed, 1 insertions, 26 deletions
diff --git a/indra/newview/lltoast.cpp b/indra/newview/lltoast.cpp
index ecaf4fb150..84931e4d2d 100644
--- a/indra/newview/lltoast.cpp
+++ b/indra/newview/lltoast.cpp
@@ -41,7 +41,7 @@
using namespace LLNotificationsUI;
//--------------------------------------------------------------------------
-LLToast::LLToast(LLToast::Params p) : LLFloater(LLSD()),
+LLToast::LLToast(LLToast::Params p) : LLModalDialog(LLSD(), p.is_modal),
mPanel(p.panel),
mTimerValue(p.timer_period),
mNotificationID(p.notif_id),
@@ -49,7 +49,6 @@ LLToast::LLToast(LLToast::Params p) : LLFloater(LLSD()),
mCanFade(p.can_fade),
mCanBeStored(p.can_be_stored),
mHideBtnEnabled(p.enable_hide_btn),
- mIsModal(p.is_modal),
mHideBtn(NULL),
mNotification(p.notification),
mHideBtnPressed(false)
@@ -67,13 +66,6 @@ LLToast::LLToast(LLToast::Params p) : LLFloater(LLSD()),
mHideBtn->setClickedCallback(boost::bind(&LLToast::hide,this));
}
- if(mIsModal)
- {
- gFocusMgr.setMouseCapture( this );
- gFocusMgr.setTopCtrl( this );
- setFocus(TRUE);
- }
-
// init callbacks if present
if(!p.on_delete_toast.empty())
mOnDeleteToastSignal.connect(p.on_delete_toast);
@@ -104,11 +96,6 @@ void LLToast::setHideButtonEnabled(bool enabled)
LLToast::~LLToast()
{
mOnToastDestroyedSignal(this);
- if(mIsModal)
- {
- gFocusMgr.unlockFocus();
- gFocusMgr.releaseFocusIfNeeded( this );
- }
}
//--------------------------------------------------------------------------
@@ -205,18 +192,6 @@ void LLToast::draw()
}
//--------------------------------------------------------------------------
-void LLToast::setModal(bool modal)
-{
- mIsModal = modal;
- if(mIsModal)
- {
- gFocusMgr.setMouseCapture( this );
- gFocusMgr.setTopCtrl( this );
- setFocus(TRUE);
- }
-}
-
-//--------------------------------------------------------------------------
void LLToast::setVisible(BOOL show)
{
if(show)