diff options
author | mberezhnoy <mberezhnoy@productengine.com> | 2013-02-09 00:10:09 +0200 |
---|---|---|
committer | mberezhnoy <mberezhnoy@productengine.com> | 2013-02-09 00:10:09 +0200 |
commit | 64fe330620459be18ee4dd54866386a8f6a76ab8 (patch) | |
tree | 62965b3a6309ce282886ffbed0eb14a806660b9e /indra/newview | |
parent | b356bbb6a5930e8900250c6654688ae2e6d25ecf (diff) |
CHUI-713 "Conversations" floater size doesn't persist between sessions
additional fix
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/llfloaterimcontainer.cpp | 12 | ||||
-rw-r--r-- | indra/newview/llfloaterimcontainer.h | 1 | ||||
-rw-r--r-- | indra/newview/llfloaterimsessiontab.cpp | 5 |
3 files changed, 12 insertions, 6 deletions
diff --git a/indra/newview/llfloaterimcontainer.cpp b/indra/newview/llfloaterimcontainer.cpp index 27e579a68c..312f70fe30 100644 --- a/indra/newview/llfloaterimcontainer.cpp +++ b/indra/newview/llfloaterimcontainer.cpp @@ -62,7 +62,8 @@ LLFloaterIMContainer::LLFloaterIMContainer(const LLSD& seed, const Params& param mExpandCollapseBtn(NULL), mConversationsRoot(NULL), mConversationsEventStream("ConversationsEvents"), - mInitialized(false) + mInitialized(false), + mIsFirstLaunch(false) { mEnableCallbackRegistrar.add("IMFloaterContainer.Check", boost::bind(&LLFloaterIMContainer::isActionChecked, this, _2)); mCommitCallbackRegistrar.add("IMFloaterContainer.Action", boost::bind(&LLFloaterIMContainer::onCustomAction, this, _2)); @@ -243,6 +244,7 @@ BOOL LLFloaterIMContainer::postBuild() mGeneralTitle = getTitle(); mInitialized = true; + mIsFirstLaunch = true; // Add callbacks: // We'll take care of view updates on idle @@ -277,7 +279,7 @@ void LLFloaterIMContainer::addFloater(LLFloater* floaterp, LLUUID session_id = floaterp->getKey(); // Make sure the message panel is open when adding a floater or it stays mysteriously hidden - if (session_id != LLUUID()) + if (!mIsFirstLaunch) { collapseMessagesPane(false); } @@ -635,6 +637,12 @@ void LLFloaterIMContainer::collapseMessagesPane(bool collapse) return; } + if (mIsFirstLaunch) + { + mIsFirstLaunch = false; + return; + } + // Save current width of panels before collapsing/expanding right pane. S32 conv_pane_width = mConversationsPane->getRect().getWidth(); S32 msg_pane_width = mMessagesPane->getRect().getWidth(); diff --git a/indra/newview/llfloaterimcontainer.h b/indra/newview/llfloaterimcontainer.h index 06af6c7b51..a28dba3b98 100644 --- a/indra/newview/llfloaterimcontainer.h +++ b/indra/newview/llfloaterimcontainer.h @@ -167,6 +167,7 @@ private: LLLayoutStack* mConversationsStack; bool mInitialized; + bool mIsFirstLaunch; LLUUID mSelectedSession; std::string mGeneralTitle; diff --git a/indra/newview/llfloaterimsessiontab.cpp b/indra/newview/llfloaterimsessiontab.cpp index 526eeef869..6dbcdb4474 100644 --- a/indra/newview/llfloaterimsessiontab.cpp +++ b/indra/newview/llfloaterimsessiontab.cpp @@ -769,10 +769,7 @@ void LLFloaterIMSessionTab::onOpen(const LLSD& key) { LLFloaterIMContainer* host_floater = dynamic_cast<LLFloaterIMContainer*>(getHost()); // Show the messages pane when opening a floater hosted in the Conversations - if (!isNearbyChat()) - { - host_floater->collapseMessagesPane(false); - } + host_floater->collapseMessagesPane(false); } } |