summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul ProductEngine <pguslisty@productengine.com>2011-12-02 19:10:08 +0200
committerPaul ProductEngine <pguslisty@productengine.com>2011-12-02 19:10:08 +0200
commitd58b5342dc7e8f49ab956523a3dc743b89803b3a (patch)
tree98c4dbd8793e8081141f34fa80d6577e6ca45062
parent7359a5f34b0c51421cdb109854b0f305422ed20a (diff)
EXP-1476 FIXED (Moving speak button to empty toolbar while incoming/outgoing call dialog is open does not move the dialog as well)
Reason: A floater can be docked only to a button which is in visible chain, the visibility of the button itself is not enough. After the button was added to the empty toolbar: mButtonAddSignal is called and the floater tries to dock to the button, but the button's parent(mButtonPanel) is yet invisible at this moment (so the button is not in visible chain). mButtonPanel visibility updates in draw() depending on whether it contains some buttons or not. Solution: Updating mButtonPanel visibility right after the button was added, before mButtonAddSignal
-rw-r--r--indra/llui/lltoolbar.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/indra/llui/lltoolbar.cpp b/indra/llui/lltoolbar.cpp
index e7642ae190..7f96c1373c 100644
--- a/indra/llui/lltoolbar.cpp
+++ b/indra/llui/lltoolbar.cpp
@@ -770,6 +770,12 @@ void LLToolBar::updateLayoutAsNeeded()
// re-center toolbar buttons
mCenteringStack->updateLayout();
+ if (!mButtons.empty())
+ {
+ mButtonPanel->setVisible(TRUE);
+ mButtonPanel->setMouseOpaque(TRUE);
+ }
+
// don't clear flag until after we've resized ourselves, to avoid laying out every frame
mNeedsLayout = false;
}