diff options
author | Tofu Linden <tofu.linden@lindenlab.com> | 2010-02-18 22:09:08 +0000 |
---|---|---|
committer | Tofu Linden <tofu.linden@lindenlab.com> | 2010-02-18 22:09:08 +0000 |
commit | 4a9b231dcc342bfd9cf570ff70d25909cda251cd (patch) | |
tree | 5d54b90d9fa5d2ba58b92a74f9e4a9cd1d16868f /indra/newview | |
parent | 1c67e8f386d69e06c1ff820eb551b3c69592ff89 (diff) | |
parent | 4ab945c9f0000ead1eca22eefe0829bf3c15d7da (diff) |
viewer2 merge.
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/llpanelnearbymedia.cpp | 29 | ||||
-rw-r--r-- | indra/newview/llpanelnearbymedia.h | 10 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/panel_nearby_media.xml | 12 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/panel_volume_pulldown.xml | 13 |
4 files changed, 35 insertions, 29 deletions
diff --git a/indra/newview/llpanelnearbymedia.cpp b/indra/newview/llpanelnearbymedia.cpp index d38dd0f870..8ad5389566 100644 --- a/indra/newview/llpanelnearbymedia.cpp +++ b/indra/newview/llpanelnearbymedia.cpp @@ -38,6 +38,7 @@ #include "llcheckboxctrl.h" #include "llcombobox.h" #include "llresizebar.h" +#include "llresizehandle.h" #include "llscrolllistctrl.h" #include "llscrolllistitem.h" #include "llscrolllistcell.h" @@ -116,6 +117,20 @@ BOOL LLPanelNearByMedia::postBuild() p.resizing_view = this; addChild( LLUICtrlFactory::create<LLResizeBar>(p) ); + p.rect = LLRect( 0, getRect().getHeight(), RESIZE_BAR_THICKNESS, 0); + p.name = "resizebar_left"; + p.min_size = getRect().getWidth(); + p.side = LLResizeBar::LEFT; + addChild( LLUICtrlFactory::create<LLResizeBar>(p) ); + + LLResizeHandle::Params resize_handle_p; + resize_handle_p.rect = LLRect( 0, RESIZE_HANDLE_HEIGHT, RESIZE_HANDLE_WIDTH, 0 ); + resize_handle_p.mouse_opaque(false); + resize_handle_p.min_width(getRect().getWidth()); + resize_handle_p.min_height(getRect().getHeight()); + resize_handle_p.corner(LLResizeHandle::LEFT_BOTTOM); + addChild(LLUICtrlFactory::create<LLResizeHandle>(resize_handle_p)); + mNearbyMediaPanel = getChild<LLUICtrl>("nearby_media_panel"); mMediaList = getChild<LLScrollListCtrl>("media_list"); mEnableAllCtrl = getChild<LLUICtrl>("all_nearby_media_enable_btn"); @@ -148,8 +163,10 @@ BOOL LLPanelNearByMedia::postBuild() updateColumns(); LLView* minimized_controls = getChildView("minimized_controls"); - mMoreHeight = getRect().getHeight(); - mLessHeight = getRect().getHeight() - minimized_controls->getRect().mBottom; + mMoreRect = getRect(); + mLessRect = getRect(); + mLessRect.mBottom = minimized_controls->getRect().mBottom; + getChild<LLUICtrl>("more_less_btn")->setValue(false); onMoreLess(); @@ -207,7 +224,7 @@ void LLPanelNearByMedia::reshape(S32 width, S32 height, BOOL called_from_parent) LLButton* more_less_btn = getChild<LLButton>("more_less_btn"); if (more_less_btn->getValue().asBoolean()) { - mMoreHeight = getRect().getHeight(); + mMoreRect = getRect(); } } @@ -928,10 +945,8 @@ void LLPanelNearByMedia::onMoreLess() // enable resizing when expanded getChildView("resizebar_bottom")->setEnabled(is_more); - S32 new_height = is_more ? mMoreHeight : mLessHeight; - - LLRect new_rect = getRect(); - new_rect.mBottom = new_rect.mTop - new_height; + LLRect new_rect = is_more ? mMoreRect : mLessRect; + new_rect.translate(getRect().mRight - new_rect.mRight, getRect().mTop - new_rect.mTop); setShape(new_rect); } diff --git a/indra/newview/llpanelnearbymedia.h b/indra/newview/llpanelnearbymedia.h index eedfd447de..6fe724266b 100644 --- a/indra/newview/llpanelnearbymedia.h +++ b/indra/newview/llpanelnearbymedia.h @@ -174,11 +174,11 @@ private: std::string mParcelMediaName; std::string mParcelAudioName; - S32 mMoreHeight; - S32 mLessHeight; - LLFrameTimer mHoverTimer; - LLScrollListItem* mParcelMediaItem; - LLScrollListItem* mParcelAudioItem; + LLRect mMoreRect; + LLRect mLessRect; + LLFrameTimer mHoverTimer; + LLScrollListItem* mParcelMediaItem; + LLScrollListItem* mParcelAudioItem; }; diff --git a/indra/newview/skins/default/xui/en/panel_nearby_media.xml b/indra/newview/skins/default/xui/en/panel_nearby_media.xml index acfd63db37..0f911f789e 100644 --- a/indra/newview/skins/default/xui/en/panel_nearby_media.xml +++ b/indra/newview/skins/default/xui/en/panel_nearby_media.xml @@ -2,7 +2,9 @@ <panel can_resize="true" can_close="false" - background_opaque="true" + bg_opaque_image="Volume_Background" + bg_alpha_image="Volume_Background" + background_opaque="true" background_visible="true" layout="topleft" width="270" @@ -16,9 +18,7 @@ <string name="playing_suffix">(playing)</string> <panel bevel_style="in" - bg_alpha_color="0 0 0 0" - bg_opaque_color="0 0 0 0.3" - bg_opaque_image="Toast_Background" + background_visible="false" follows="left|right|top" top="0" height="30" @@ -188,9 +188,7 @@ </scroll_list> <panel bevel_style="in" - background_visible="true" - bg_alpha_color="0.0 0.0 0.0 1.0" - bg_opaque_color="0 0 0 0.3" + background_visible="false" follows="left|right|bottom" top_pad="5" height="30" diff --git a/indra/newview/skins/default/xui/en/panel_volume_pulldown.xml b/indra/newview/skins/default/xui/en/panel_volume_pulldown.xml index 55ab95bfe9..cd66c56ca1 100644 --- a/indra/newview/skins/default/xui/en/panel_volume_pulldown.xml +++ b/indra/newview/skins/default/xui/en/panel_volume_pulldown.xml @@ -1,7 +1,9 @@ <?xml version="1.0" encoding="utf-8" standalone="yes" ?> <panel background_opaque="true" - background_visible="false" + background_visible="true" + bg_opaque_image="Volume_Background" + bg_alpha_image="Volume_Background" border_visible="false" border="false" chrome="true" @@ -10,15 +12,6 @@ layout="topleft" name="volumepulldown_floater" width="32"> - <!-- floater background image --> - <icon - height="150" - image_name="Volume_Background" - layout="topleft" - left="0" - name="normal_background" - top="0" - width="32" /> <slider control_name="AudioLevelMaster" follows="left|top" |