summaryrefslogtreecommitdiff
path: root/indra/newview/llmanipscale.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llmanipscale.cpp')
-rw-r--r--indra/newview/llmanipscale.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/indra/newview/llmanipscale.cpp b/indra/newview/llmanipscale.cpp
index b1cdfe3886..72596e850a 100644
--- a/indra/newview/llmanipscale.cpp
+++ b/indra/newview/llmanipscale.cpp
@@ -415,7 +415,7 @@ BOOL LLManipScale::handleHover(S32 x, S32 y, MASK mask)
// Patch up textures, if possible.
LLSelectMgr::getInstance()->adjustTexturesByScale(FALSE, getStretchTextures());
- gViewerWindow->getWindow()->setCursor(UI_CURSOR_TOOLSCALE);
+ gViewerWindow->setCursor(UI_CURSOR_TOOLSCALE);
return TRUE;
}
@@ -493,8 +493,8 @@ void LLManipScale::highlightManipulators(S32 x, S32 y)
mProjectedManipulators.insert(projManipulator);
}
- F32 half_width = (F32)gViewerWindow->getWindowWidth() / 2.f;
- F32 half_height = (F32)gViewerWindow->getWindowHeight() / 2.f;
+ F32 half_width = (F32)gViewerWindow->getWorldViewWidth() / 2.f;
+ F32 half_height = (F32)gViewerWindow->getWorldViewHeight() / 2.f;
LLVector2 manip2d;
LLVector2 mousePos((F32)x - half_width, (F32)y - half_height);
LLVector2 delta;
@@ -1368,7 +1368,7 @@ void LLManipScale::updateSnapGuides(const LLBBox& bbox)
else
{
F32 object_distance = dist_vec(mScaleCenter, LLViewerCamera::getInstance()->getOrigin());
- mSnapRegimeOffset = (SNAP_GUIDE_SCREEN_OFFSET * gViewerWindow->getWindowWidth() * object_distance) / LLViewerCamera::getInstance()->getPixelMeterRatio();
+ mSnapRegimeOffset = (SNAP_GUIDE_SCREEN_OFFSET * gViewerWindow->getWorldViewWidth() * object_distance) / LLViewerCamera::getInstance()->getPixelMeterRatio();
}
LLVector3 cam_at_axis;
F32 snap_guide_length;
@@ -1381,7 +1381,7 @@ void LLManipScale::updateSnapGuides(const LLBBox& bbox)
{
cam_at_axis = LLViewerCamera::getInstance()->getAtAxis();
F32 manipulator_distance = dist_vec(box_corner_agent, LLViewerCamera::getInstance()->getOrigin());
- snap_guide_length = (SNAP_GUIDE_SCREEN_LENGTH * gViewerWindow->getWindowWidth() * manipulator_distance) / LLViewerCamera::getInstance()->getPixelMeterRatio();
+ snap_guide_length = (SNAP_GUIDE_SCREEN_LENGTH * gViewerWindow->getWorldViewWidth() * manipulator_distance) / LLViewerCamera::getInstance()->getPixelMeterRatio();
}
mSnapGuideLength = snap_guide_length / llmax(0.1f, (llmin(mSnapGuideDir1 * cam_at_axis, mSnapGuideDir2 * cam_at_axis)));
@@ -1827,10 +1827,10 @@ void LLManipScale::renderSnapGuides(const LLBBox& bbox)
std::string help_text = "Move mouse cursor over ruler";
LLColor4 help_text_color = LLColor4::white;
help_text_color.mV[VALPHA] = clamp_rescale(mHelpTextTimer.getElapsedTimeF32(), sHelpTextVisibleTime, sHelpTextVisibleTime + sHelpTextFadeTime, grid_alpha, 0.f);
- hud_render_utf8text(help_text, help_text_pos, *big_fontp, LLFontGL::NORMAL, -0.5f * big_fontp->getWidthF32(help_text), 3.f, help_text_color, mObjectSelection->getSelectType() == SELECT_TYPE_HUD);
+ hud_render_utf8text(help_text, help_text_pos, *big_fontp, LLFontGL::NORMAL, LLFontGL::NO_SHADOW, -0.5f * big_fontp->getWidthF32(help_text), 3.f, help_text_color, mObjectSelection->getSelectType() == SELECT_TYPE_HUD);
help_text = "to snap to grid";
help_text_pos -= LLViewerCamera::getInstance()->getUpAxis() * mSnapRegimeOffset * 0.4f;
- hud_render_utf8text(help_text, help_text_pos, *big_fontp, LLFontGL::NORMAL, -0.5f * big_fontp->getWidthF32(help_text), 3.f, help_text_color, mObjectSelection->getSelectType() == SELECT_TYPE_HUD);
+ hud_render_utf8text(help_text, help_text_pos, *big_fontp, LLFontGL::NORMAL, LLFontGL::NO_SHADOW, -0.5f * big_fontp->getWidthF32(help_text), 3.f, help_text_color, mObjectSelection->getSelectType() == SELECT_TYPE_HUD);
}
}
}