summaryrefslogtreecommitdiff
path: root/indra/newview/llnearbychat.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llnearbychat.cpp')
-rw-r--r--indra/newview/llnearbychat.cpp41
1 files changed, 31 insertions, 10 deletions
diff --git a/indra/newview/llnearbychat.cpp b/indra/newview/llnearbychat.cpp
index 12638ab855..974291a54e 100644
--- a/indra/newview/llnearbychat.cpp
+++ b/indra/newview/llnearbychat.cpp
@@ -61,7 +61,7 @@
static const S32 RESIZE_BAR_THICKNESS = 3;
LLNearbyChat::LLNearbyChat(const LLSD& key)
- : LLDockableFloater(NULL, key)
+ : LLDockableFloater(NULL, false, key)
,mChatHistory(NULL)
{
@@ -97,14 +97,41 @@ BOOL LLNearbyChat::postBuild()
if (getDockControl() == NULL)
{
setDockControl(new LLDockControl(
- LLBottomTray::getInstance()->getNearbyChatBar(), this,
- getDockTongue(), LLDockControl::LEFT, boost::bind(&LLNearbyChat::getAllowedRect, this, _1)));
+ LLBottomTray::getInstance()->getNearbyChatBar(), this,
+ getDockTongue(), LLDockControl::LEFT, boost::bind(&LLNearbyChat::getAllowedRect, this, _1)));
}
return true;
}
+void LLNearbyChat::applySavedVariables()
+{
+ if (mRectControl.size() > 1)
+ {
+ const LLRect& rect = LLUI::sSettingGroups["floater"]->getRect(mRectControl);
+ if(!rect.isEmpty() && rect.isValid())
+ {
+ reshape(rect.getWidth(), rect.getHeight());
+ setRect(rect);
+ }
+ }
+
+
+ if(!LLUI::sSettingGroups["floater"]->controlExists(mDocStateControl))
+ {
+ setDocked(true);
+ }
+ else
+ {
+ if (mDocStateControl.size() > 1)
+ {
+ bool dockState = LLUI::sSettingGroups["floater"]->getBOOL(mDocStateControl);
+ setDocked(dockState);
+ }
+ }
+}
+
LLColor4 nearbychat_get_text_color(const LLChat& chat)
{
LLColor4 text_color;
@@ -265,11 +292,5 @@ void LLNearbyChat::getAllowedRect(LLRect& rect)
{
rect = gViewerWindow->getWorldViewRect();
}
-void LLNearbyChat::setVisible (BOOL visible)
-{
- LLDockableFloater::setVisible(visible);
-}
-void LLNearbyChat::toggleWindow()
-{
-}
+