summaryrefslogtreecommitdiff
path: root/indra/llui/llui.cpp
diff options
context:
space:
mode:
authorTofu Linden <tofu.linden@lindenlab.com>2010-03-06 11:15:09 +0000
committerTofu Linden <tofu.linden@lindenlab.com>2010-03-06 11:15:09 +0000
commit809a280a51bc8645de7a02c2a3dbe32bc230b93c (patch)
tree2a4d6dbe1fb8d78e77f5f7ce118a5f662788a453 /indra/llui/llui.cpp
parent1889d02569a58d08b6c452e609819a1961bf64e8 (diff)
parent93051dc23cb3252af327a9b113abc45de154ff4e (diff)
viewer2 merge.
Diffstat (limited to 'indra/llui/llui.cpp')
-rw-r--r--indra/llui/llui.cpp38
1 files changed, 38 insertions, 0 deletions
diff --git a/indra/llui/llui.cpp b/indra/llui/llui.cpp
index b348ec2d29..5121ef5351 100644
--- a/indra/llui/llui.cpp
+++ b/indra/llui/llui.cpp
@@ -86,6 +86,9 @@ std::list<std::string> gUntranslated;
/*static*/ LLHelp* LLUI::sHelpImpl = NULL;
/*static*/ std::vector<std::string> LLUI::sXUIPaths;
/*static*/ LLFrameTimer LLUI::sMouseIdleTimer;
+/*static*/ LLUI::add_popup_t LLUI::sAddPopupFunc;
+/*static*/ LLUI::remove_popup_t LLUI::sRemovePopupFunc;
+/*static*/ LLUI::clear_popups_t LLUI::sClearPopupsFunc;
// register filtereditor here
static LLDefaultChildRegistry::Register<LLFilterEditor> register_filter_editor("filter_editor");
@@ -1607,6 +1610,13 @@ void LLUI::cleanupClass()
sImageProvider->cleanUp();
}
+void LLUI::setPopupFuncs(const add_popup_t& add_popup, const remove_popup_t& remove_popup, const clear_popups_t& clear_popups)
+{
+ sAddPopupFunc = add_popup;
+ sRemovePopupFunc = remove_popup;
+ sClearPopupsFunc = clear_popups;
+}
+
//static
void LLUI::dirtyRect(LLRect rect)
{
@@ -1877,6 +1887,34 @@ LLControlGroup& LLUI::getControlControlGroup (const std::string& controlname)
return *sSettingGroups["config"]; // default group
}
+//static
+void LLUI::addPopup(LLView* viewp)
+{
+ if (sAddPopupFunc)
+ {
+ sAddPopupFunc(viewp);
+ }
+}
+
+//static
+void LLUI::removePopup(LLView* viewp)
+{
+ if (sRemovePopupFunc)
+ {
+ sRemovePopupFunc(viewp);
+ }
+}
+
+//static
+void LLUI::clearPopups()
+{
+ if (sClearPopupsFunc)
+ {
+ sClearPopupsFunc();
+ }
+}
+
+
//static
// spawn_x and spawn_y are top left corner of view in screen GL coordinates
void LLUI::positionViewNearMouse(LLView* view, S32 spawn_x, S32 spawn_y)