summaryrefslogtreecommitdiff
path: root/indra/llui/llfloater.h
diff options
context:
space:
mode:
authorKent Quirk <q@lindenlab.com>2009-01-05 18:59:12 +0000
committerKent Quirk <q@lindenlab.com>2009-01-05 18:59:12 +0000
commit667ca55bad0108c4bdf8f007b89e1a52fc766aad (patch)
tree7bd62ac8d9af079c3994565f3f200ccc250bbc28 /indra/llui/llfloater.h
parent95f365789f4cebc7bd97ccefd538f14d481a8373 (diff)
svn merge -r106715:HEAD svn+ssh://svn.lindenlab.com/svn/linden/branches/q/notifications-merge-r106715 . QAR-1149 -- Final merge of notifications to trunk.
Diffstat (limited to 'indra/llui/llfloater.h')
-rw-r--r--indra/llui/llfloater.h24
1 files changed, 22 insertions, 2 deletions
diff --git a/indra/llui/llfloater.h b/indra/llui/llfloater.h
index b66eba8810..ebf2676960 100644
--- a/indra/llui/llfloater.h
+++ b/indra/llui/llfloater.h
@@ -39,6 +39,7 @@
#include "llpanel.h"
#include "lluuid.h"
#include "lltabcontainer.h"
+#include "llnotifications.h"
#include <set>
class LLDragHandle;
@@ -46,6 +47,7 @@ class LLResizeHandle;
class LLResizeBar;
class LLButton;
class LLMultiFloater;
+class LLFloater;
const S32 LLFLOATER_VPAD = 6;
const S32 LLFLOATER_HPAD = 6;
@@ -70,6 +72,20 @@ const BOOL CLOSE_NO = FALSE;
const BOOL ADJUST_VERTICAL_YES = TRUE;
const BOOL ADJUST_VERTICAL_NO = FALSE;
+// associates a given notification instance with a particular floater
+class LLFloaterNotificationContext :
+ public LLNotificationContext
+{
+public:
+ LLFloaterNotificationContext(LLHandle<LLFloater> floater_handle) :
+ mFloaterHandle(floater_handle)
+ {}
+
+ LLFloater* getFloater() { return mFloaterHandle.get(); }
+private:
+ LLHandle<LLFloater> mFloaterHandle;
+};
+
class LLFloater : public LLPanel
{
@@ -213,6 +229,11 @@ public:
// handle refocusing.
static void closeFocusedFloater();
+ LLNotification::Params contextualNotification(const std::string& name)
+ {
+ return LLNotification::Params(name).context(mNotificationContext);
+ }
+
static void onClickClose(void *userdata);
static void onClickMinimize(void *userdata);
static void onClickTearOff(void *userdata);
@@ -299,7 +320,7 @@ private:
S32 mPreviousMinimizedBottom;
S32 mPreviousMinimizedLeft;
-private:
+ LLFloaterNotificationContext* mNotificationContext;
LLRootHandle<LLFloater> mHandle;
};
@@ -467,7 +488,6 @@ template <class T> class LLFloaterSingleton : public LLUISingleton<T, Visibility
{
};
-
extern LLFloaterView* gFloaterView;
#endif // LL_FLOATER_H