summaryrefslogtreecommitdiff
path: root/indra/llui
diff options
context:
space:
mode:
authorRichard Linden <none@none>2012-03-23 12:03:06 -0700
committerRichard Linden <none@none>2012-03-23 12:03:06 -0700
commit8ff4c75637ce2b9a55a65ba1fc1db3a23e7b88ec (patch)
tree22d91064de586bdecc6a6f27146361f207b59916 /indra/llui
parenteec1ce27cbff5c26daf22220d7c3dc833cfaa749 (diff)
CHUI-70 FIX Build floater and other floaters opened in default position become centered in viewer when object is built or viewer resized
always initialize mPosition
Diffstat (limited to 'indra/llui')
-rw-r--r--indra/llui/llfloater.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp
index 3f8116d8d6..2cbc12defc 100644
--- a/indra/llui/llfloater.cpp
+++ b/indra/llui/llfloater.cpp
@@ -859,6 +859,9 @@ bool LLFloater::applyRectControl()
{
bool saved_rect = false;
+ LLRect screen_rect = calcScreenRect();
+ mPosition = LLCoordGL(screen_rect.getCenterX(), screen_rect.getCenterY()).convert();
+
LLFloater* last_in_group = LLFloaterReg::getLastFloaterInGroup(mInstanceName);
if (last_in_group && last_in_group != this)
{