From 40687a930c2e37a4da15ff15f004611a734583d7 Mon Sep 17 00:00:00 2001 From: Richard Linden Date: Wed, 18 Jan 2012 12:59:44 -0800 Subject: EXP-1812 FIX Cannot resize location bar / favorites in top navigation bar in viewer --- indra/llui/lllayoutstack.cpp | 13 +- indra/llui/lllayoutstack.h | 6 +- indra/newview/app_settings/settings.xml | 11 - .../skins/default/xui/en/panel_navigation_bar.xml | 235 +++++++++++---------- 4 files changed, 130 insertions(+), 135 deletions(-) (limited to 'indra') diff --git a/indra/llui/lllayoutstack.cpp b/indra/llui/lllayoutstack.cpp index a309e3ff97..9909032707 100644 --- a/indra/llui/lllayoutstack.cpp +++ b/indra/llui/lllayoutstack.cpp @@ -201,6 +201,7 @@ LLLayoutStack::Params::Params() clip("clip", true), open_time_constant("open_time_constant", 0.02f), close_time_constant("close_time_constant", 0.03f), + resize_bar_overlap("resize_bar_overlap", 1), border_size("border_size", LLCachedControl(*LLUI::sSettingGroups["config"], "UIResizeBarHeight", 0)) {} @@ -213,7 +214,8 @@ LLLayoutStack::LLLayoutStack(const LLLayoutStack::Params& p) mNeedsLayout(true), mClip(p.clip), mOpenTimeConstant(p.open_time_constant), - mCloseTimeConstant(p.close_time_constant) + mCloseTimeConstant(p.close_time_constant), + mResizeBarOverlap(p.resize_bar_overlap) {} LLLayoutStack::~LLLayoutStack() @@ -409,21 +411,20 @@ void LLLayoutStack::updateLayout() panelp->setShape(panel_rect); panelp->setIgnoreReshape(false); - static LLUICachedControl resize_bar_overlap ("UIResizeBarOverlap", 0); LLRect resize_bar_rect(panel_rect); F32 panel_spacing = (F32)mPanelSpacing * panelp->getVisibleAmount(); if (mOrientation == HORIZONTAL) { - resize_bar_rect.mLeft = panel_rect.mRight - resize_bar_overlap; - resize_bar_rect.mRight = panel_rect.mRight + panel_spacing + resize_bar_overlap; + resize_bar_rect.mLeft = panel_rect.mRight - mResizeBarOverlap; + resize_bar_rect.mRight = panel_rect.mRight + panel_spacing + mResizeBarOverlap; cur_pos += panel_visible_dim + panel_spacing; } else //VERTICAL { - resize_bar_rect.mTop = panel_rect.mBottom + resize_bar_overlap; - resize_bar_rect.mBottom = panel_rect.mBottom - panel_spacing - resize_bar_overlap; + resize_bar_rect.mTop = panel_rect.mBottom + mResizeBarOverlap; + resize_bar_rect.mBottom = panel_rect.mBottom - panel_spacing - mResizeBarOverlap; cur_pos -= panel_visible_dim + panel_spacing; } diff --git a/indra/llui/lllayoutstack.h b/indra/llui/lllayoutstack.h index a343e11cec..f00d5e759b 100644 --- a/indra/llui/lllayoutstack.h +++ b/indra/llui/lllayoutstack.h @@ -60,6 +60,7 @@ public: clip; Optional open_time_constant, close_time_constant; + Optional resize_bar_overlap; Params(); }; @@ -122,9 +123,10 @@ private: bool mAnimatedThisFrame; bool mAnimate; bool mClip; - F32 mOpenTimeConstant; - F32 mCloseTimeConstant; + F32 mOpenTimeConstant; + F32 mCloseTimeConstant; bool mNeedsLayout; + S32 mResizeBarOverlap; }; // end class LLLayoutStack diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index a4806e3b77..28ba9fd704 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -11378,17 +11378,6 @@ Value 3 - UIResizeBarOverlap - - Comment - Size of UI resize bar overlap - Persist - 1 - Type - S32 - Value - 1 - UIScaleFactor Comment diff --git a/indra/newview/skins/default/xui/en/panel_navigation_bar.xml b/indra/newview/skins/default/xui/en/panel_navigation_bar.xml index 9dee68efa7..305ce70fcb 100644 --- a/indra/newview/skins/default/xui/en/panel_navigation_bar.xml +++ b/indra/newview/skins/default/xui/en/panel_navigation_bar.xml @@ -59,6 +59,8 @@ follows="all" height="34" layout="topleft" + border_size="0" + resize_bar_overlap="3" left="0" mouse_opaque="false" name="nvp_stack" @@ -73,129 +75,130 @@ min_width="480" name="navigation_layout_panel" width="480"> - - - -