From 7dd8dc8be61ec40e33c40b9b37b8f45335df25c4 Mon Sep 17 00:00:00 2001 From: Richard Linden Date: Thu, 14 Jul 2011 20:57:32 -0700 Subject: EXP-880 FIX Enable navigation chrome in search floater fixed regression where profile window wasn't using requested size --- indra/llui/llui.cpp | 54 ++++++++++++++++++++++++++--------------------------- 1 file changed, 27 insertions(+), 27 deletions(-) (limited to 'indra/llui/llui.cpp') diff --git a/indra/llui/llui.cpp b/indra/llui/llui.cpp index 8020ca802b..bc2432f6f7 100644 --- a/indra/llui/llui.cpp +++ b/indra/llui/llui.cpp @@ -2082,7 +2082,7 @@ namespace LLInitParam alpha("alpha"), control("") { - updateBlockFromValue(); + updateBlockFromValue(false); } void ParamValue >::updateValueFromBlock() @@ -2097,14 +2097,14 @@ namespace LLInitParam } } - void ParamValue >::updateBlockFromValue() + void ParamValue >::updateBlockFromValue(bool make_block_authoritative) { LLColor4 color = getValue(); - red.set(color.mV[VRED], false); - green.set(color.mV[VGREEN], false); - blue.set(color.mV[VBLUE], false); - alpha.set(color.mV[VALPHA], false); - control.set("", false); + red.set(color.mV[VRED], make_block_authoritative); + green.set(color.mV[VGREEN], make_block_authoritative); + blue.set(color.mV[VBLUE], make_block_authoritative); + alpha.set(color.mV[VALPHA], make_block_authoritative); + control.set("", make_block_authoritative); } bool ParamCompare::equals(const LLFontGL* a, const LLFontGL* b) @@ -2124,7 +2124,7 @@ namespace LLInitParam updateValue(LLFontGL::getFontDefault()); } addSynonym(name, ""); - updateBlockFromValue(); + updateBlockFromValue(false); } void ParamValue >::updateValueFromBlock() @@ -2150,13 +2150,13 @@ namespace LLInitParam } } - void ParamValue >::updateBlockFromValue() + void ParamValue >::updateBlockFromValue(bool make_block_authoritative) { if (getValue()) { - name.set(LLFontGL::nameFromFont(getValue()), false); - size.set(LLFontGL::sizeFromFont(getValue()), false); - style.set(LLFontGL::getStringFromStyle(getValue()->getFontDesc().getStyle()), false); + name.set(LLFontGL::nameFromFont(getValue()), make_block_authoritative); + size.set(LLFontGL::sizeFromFont(getValue()), make_block_authoritative); + style.set(LLFontGL::getStringFromStyle(getValue()->getFontDesc().getStyle()), make_block_authoritative); } } @@ -2169,7 +2169,7 @@ namespace LLInitParam width("width"), height("height") { - updateBlockFromValue(); + updateBlockFromValue(false); } void ParamValue >::updateValueFromBlock() @@ -2236,19 +2236,19 @@ namespace LLInitParam updateValue(rect); } - void ParamValue >::updateBlockFromValue() + void ParamValue >::updateBlockFromValue(bool make_block_authoritative) { // because of the ambiguity in specifying a rect by position and/or dimensions - // we clear the "provided" flag so that values from xui/etc have priority - // over those calculated from the rect object - + // we use the lowest priority pairing so that any valid pairing in xui + // will override those calculated from the rect object + // in this case, that is left+width and bottom+height LLRect& value = getValue(); - left.set(value.mLeft, false); - right.set(value.mRight, false); - bottom.set(value.mBottom, false); - top.set(value.mTop, false); - width.set(value.getWidth(), false); - height.set(value.getHeight(), false); + + left.set(value.mLeft, make_block_authoritative); + width.set(value.getWidth(), make_block_authoritative); + + bottom.set(value.mBottom, make_block_authoritative); + height.set(value.getHeight(), make_block_authoritative); } ParamValue >::ParamValue(const LLCoordGL& coord) @@ -2256,7 +2256,7 @@ namespace LLInitParam x("x"), y("y") { - updateBlockFromValue(); + updateBlockFromValue(false); } void ParamValue >::updateValueFromBlock() @@ -2264,10 +2264,10 @@ namespace LLInitParam updateValue(LLCoordGL(x, y)); } - void ParamValue >::updateBlockFromValue() + void ParamValue >::updateBlockFromValue(bool make_block_authoritative) { - x.set(getValue().mX, false); - y.set(getValue().mY, false); + x.set(getValue().mX, make_block_authoritative); + y.set(getValue().mY, make_block_authoritative); } -- cgit v1.2.3