From ccb1d2b1e43369803cf9ab1ffc7deefbac2db8fc Mon Sep 17 00:00:00 2001 From: Steven Bennetts Date: Thu, 10 Sep 2009 03:12:12 +0000 Subject: merge -r 1609-1612 https://svn.aws.productengine.com/secondlife/pe/stable-2 -> viewer-2.0.0-3 Fixes: EXT-825 EXT-893 EXT-889 EXT-88 --- indra/llui/lldockcontrol.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'indra/llui/lldockcontrol.cpp') diff --git a/indra/llui/lldockcontrol.cpp b/indra/llui/lldockcontrol.cpp index bec7f04cc0..e119d387ce 100644 --- a/indra/llui/lldockcontrol.cpp +++ b/indra/llui/lldockcontrol.cpp @@ -65,11 +65,14 @@ void LLDockControl::repositionDockable() void LLDockControl::calculateDockablePosition() { LLRect dockRect = mDockWidget->calcScreenRect(); - if (mPrevDockRect != dockRect || mRecalculateDocablePosition) + LLRect rootRect = mDockableFloater->getRootView()->getRect(); + + // recalculate dockable position if dock position changed + // or root view rect changed or recalculation is forced + if (mPrevDockRect != dockRect || mRootRect != rootRect + || mRecalculateDocablePosition) { LLRect dockableRect = mDockableFloater->calcScreenRect(); - LLRect rootRect = mDockableFloater->getRootView()->getRect(); - S32 x = 0; S32 y = 0; switch (mDockAt) @@ -100,6 +103,7 @@ void LLDockControl::calculateDockablePosition() mDockableFloater->screenPointToLocal(mDockTongueX, mDockTongueY, &mDockTongueX, &mDockTongueY); mPrevDockRect = dockRect; + mRootRect = rootRect; mRecalculateDocablePosition = false; } } -- cgit v1.2.3 From 7df79382a075646a51f21bed0d7f8de883fc3608 Mon Sep 17 00:00:00 2001 From: Steven Bennetts Date: Fri, 11 Sep 2009 23:50:59 +0000 Subject: merge https://svn.aws.productengine.com/secondlife/export-from-ll/viewer-2-0@1634 https://svn.aws.productengine.com/secondlife/pe/stable-2@1648 -> viewer-2.0.0-3 * Bugs: EXT-888 EXT-866 EXT-861 EXT-858 EXT-864 EXT-875 EXT-884 EXT-718 EXT-786 EXT-885 EXT-910 EXT-845 EXT-312 EXT-823 EXT-868 * New Development: EXT-748 EXT-863 EXT-835 QA: Please test Recent List to verify it has no troubles. --- indra/llui/lldockcontrol.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'indra/llui/lldockcontrol.cpp') diff --git a/indra/llui/lldockcontrol.cpp b/indra/llui/lldockcontrol.cpp index e119d387ce..d666f2be56 100644 --- a/indra/llui/lldockcontrol.cpp +++ b/indra/llui/lldockcontrol.cpp @@ -48,12 +48,25 @@ LLDockControl::LLDockControl(LLView* dockWidget, LLFloater* dockableFloater, { off(); } + + if (dockWidget != NULL) { + repositionDockable(); + } } LLDockControl::~LLDockControl() { } +void LLDockControl::setDock(LLView* dockWidget) +{ + mDockWidget = dockWidget; + if (mDockWidget != NULL) + { + repositionDockable(); + } +} + void LLDockControl::repositionDockable() { if (mEnabled) -- cgit v1.2.3