diff options
author | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2022-05-20 23:19:26 +0300 |
---|---|---|
committer | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2022-05-20 23:19:26 +0300 |
commit | 397f401a5058732a5947e2676815999cf004c5eb (patch) | |
tree | 8880dbb47c03782989d6e662f06504c454526a41 /indra/newview | |
parent | d1265cda36f31d0273b0cd57e1e6c762dfc0b29f (diff) |
SL-17436 Tools floater drops negative Z position for attachments
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/llpanelobject.cpp | 10 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/floater_tools.xml | 1 |
2 files changed, 6 insertions, 5 deletions
diff --git a/indra/newview/llpanelobject.cpp b/indra/newview/llpanelobject.cpp index 831c89b005..a6d704a7c5 100644 --- a/indra/newview/llpanelobject.cpp +++ b/indra/newview/llpanelobject.cpp @@ -1644,13 +1644,13 @@ void LLPanelObject::sendPosition(BOOL btn_down) LLVector3 newpos(mCtrlPosX->get(), mCtrlPosY->get(), mCtrlPosZ->get()); LLViewerRegion* regionp = mObject->getRegion(); - // Clamp the Z height - const F32 height = newpos.mV[VZ]; - const F32 min_height = LLWorld::getInstance()->getMinAllowedZ(mObject, mObject->getPositionGlobal()); - const F32 max_height = LLWorld::getInstance()->getRegionMaxHeight(); - if (!mObject->isAttachment()) { + // Clamp the Z height + const F32 height = newpos.mV[VZ]; + const F32 min_height = LLWorld::getInstance()->getMinAllowedZ(mObject, mObject->getPositionGlobal()); + const F32 max_height = LLWorld::getInstance()->getRegionMaxHeight(); + if ( height < min_height) { newpos.mV[VZ] = min_height; diff --git a/indra/newview/skins/default/xui/en/floater_tools.xml b/indra/newview/skins/default/xui/en/floater_tools.xml index 0abee2ff80..46f05fd7bb 100644 --- a/indra/newview/skins/default/xui/en/floater_tools.xml +++ b/indra/newview/skins/default/xui/en/floater_tools.xml @@ -1481,6 +1481,7 @@ even though the user gets a free copy. layout="topleft" left_delta="0" max_val="4096" + min_val="-32" name="Pos Z" text_enabled_color="0 0.8 1 .65" top_pad="3" |