summaryrefslogtreecommitdiff
path: root/indra/llui/llui.cpp
diff options
context:
space:
mode:
authorRichard Linden <none@none>2012-02-07 12:31:48 -0800
committerRichard Linden <none@none>2012-02-07 12:31:48 -0800
commitd56be1f1751f66bff09f0d223ed4712974e69e09 (patch)
treed751fa370bd2ddb7073b8c2bd960157d22f814ca /indra/llui/llui.cpp
parentba32b72a9eea3ded3ee09675cc56670e618f652e (diff)
EXP-1181 WIP as a designer I would like to specify default floater positions using realtive coordinates
refactored LLCoord code to be templated, ultimately to support arbitrary conversions
Diffstat (limited to 'indra/llui/llui.cpp')
-rw-r--r--indra/llui/llui.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/indra/llui/llui.cpp b/indra/llui/llui.cpp
index 6b74c5a6be..931b696c90 100644
--- a/indra/llui/llui.cpp
+++ b/indra/llui/llui.cpp
@@ -1688,21 +1688,22 @@ void LLUI::translate(F32 x, F32 y, F32 z)
gGL.translateUI(x,y,z);
LLFontGL::sCurOrigin.mX += (S32) x;
LLFontGL::sCurOrigin.mY += (S32) y;
- LLFontGL::sCurOrigin.mZ += z;
+ LLFontGL::sCurDepth += z;
}
//static
void LLUI::pushMatrix()
{
gGL.pushUIMatrix();
- LLFontGL::sOriginStack.push_back(LLFontGL::sCurOrigin);
+ LLFontGL::sOriginStack.push_back(std::make_pair(LLFontGL::sCurOrigin, LLFontGL::sCurDepth));
}
//static
void LLUI::popMatrix()
{
gGL.popUIMatrix();
- LLFontGL::sCurOrigin = *LLFontGL::sOriginStack.rbegin();
+ LLFontGL::sCurOrigin = LLFontGL::sOriginStack.back().first;
+ LLFontGL::sCurDepth = LLFontGL::sOriginStack.back().second;
LLFontGL::sOriginStack.pop_back();
}
@@ -1712,7 +1713,7 @@ void LLUI::loadIdentity()
gGL.loadUIIdentity();
LLFontGL::sCurOrigin.mX = 0;
LLFontGL::sCurOrigin.mY = 0;
- LLFontGL::sCurOrigin.mZ = 0;
+ LLFontGL::sCurDepth = 0.f;
}
//static