From d20e7471ad9881fd5a9a58d69729ba41c3a5e12c Mon Sep 17 00:00:00 2001 From: Andrew Dyukov Date: Fri, 6 Aug 2010 16:00:03 +0300 Subject: EXT-8539 FIXED Fixed title of alpha mask not save if renaming it from 'Editing' panel. Bug happened because name change was not explicitly listed as sufficient reason to save a wearable. So saving failed for alpha masks with only names changed. Other wearables didn't have this problem because they passed precondition even if only name was changed thanking to checks that included visualparams. - Made name change explicitly a sufficient reason to proceed with saving a wearable. Reviewed by Neal Orman at https://codereview.productengine.com/secondlife/r/840/ --HG-- branch : product-engine --- indra/newview/llagentwearables.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/indra/newview/llagentwearables.cpp b/indra/newview/llagentwearables.cpp index 6ee5a8b279..6e3e54df2c 100644 --- a/indra/newview/llagentwearables.cpp +++ b/indra/newview/llagentwearables.cpp @@ -388,7 +388,9 @@ void LLAgentWearables::saveWearable(const LLWearableType::EType type, const U32 const std::string new_name) { LLWearable* old_wearable = getWearable(type, index); - if (old_wearable && (old_wearable->isDirty() || old_wearable->isOldVersion())) + if(!old_wearable) return; + bool name_changed = !new_name.empty() && (new_name != old_wearable->getName()); + if (name_changed || old_wearable->isDirty() || old_wearable->isOldVersion()) { LLUUID old_item_id = old_wearable->getItemID(); LLWearable* new_wearable = LLWearableList::instance().createCopy(old_wearable); @@ -404,12 +406,10 @@ void LLAgentWearables::saveWearable(const LLWearableType::EType type, const U32 if (item) { std::string item_name = item->getName(); - bool name_changed = false; - if (!new_name.empty() && (new_name != item->getName())) + if (name_changed) { llinfos << "saveWearable changing name from " << item->getName() << " to " << new_name << llendl; item_name = new_name; - name_changed = true; } // Update existing inventory item LLPointer template_item = -- cgit v1.2.3 From 326ad1933b0df66f801577c6da290a6dab54d367 Mon Sep 17 00:00:00 2001 From: Paul Guslisty Date: Fri, 6 Aug 2010 18:50:24 +0300 Subject: EXT-8207 FIXED (Unexpected camera zoom occures if scroll location history drop-down list by mouse wheel) Added parameter for scroll list control that determines opaque of mouse scroll wheel event. Set this parameter to \"true\" in combobox of navigation panel. Reviewed by Vadim Savchuk at https://codereview.productengine.com/secondlife/r/829/ --HG-- branch : product-engine --- indra/llui/llscrolllistctrl.cpp | 8 ++++++++ indra/llui/llscrolllistctrl.h | 4 +++- indra/newview/skins/default/xui/en/panel_navigation_bar.xml | 2 ++ indra/newview/skins/default/xui/en/widgets/scroll_list.xml | 1 + 4 files changed, 14 insertions(+), 1 deletion(-) diff --git a/indra/llui/llscrolllistctrl.cpp b/indra/llui/llscrolllistctrl.cpp index d4d161f2c9..bb43c19c2c 100644 --- a/indra/llui/llscrolllistctrl.cpp +++ b/indra/llui/llscrolllistctrl.cpp @@ -135,6 +135,7 @@ LLScrollListCtrl::Params::Params() search_column("search_column", 0), sort_column("sort_column", -1), sort_ascending("sort_ascending", true), + mouse_wheel_opaque("mouse_wheel_opaque", false), commit_on_keyboard_movement("commit_on_keyboard_movement", true), heading_height("heading_height"), page_lines("page_lines", 0), @@ -163,6 +164,7 @@ LLScrollListCtrl::LLScrollListCtrl(const LLScrollListCtrl::Params& p) : LLUICtrl(p), mLineHeight(0), mScrollLines(0), + mMouseWheelOpaque(p.mouse_wheel_opaque), mPageLines(p.page_lines), mMaxSelectable(0), mAllowKeyboardMovement(TRUE), @@ -1536,6 +1538,12 @@ BOOL LLScrollListCtrl::handleScrollWheel(S32 x, S32 y, S32 clicks) BOOL handled = FALSE; // Pretend the mouse is over the scrollbar handled = mScrollbar->handleScrollWheel( 0, 0, clicks ); + + if (mMouseWheelOpaque) + { + return TRUE; + } + return handled; } diff --git a/indra/llui/llscrolllistctrl.h b/indra/llui/llscrolllistctrl.h index 1f0ef585db..19cb7e2bfe 100644 --- a/indra/llui/llscrolllistctrl.h +++ b/indra/llui/llscrolllistctrl.h @@ -102,7 +102,8 @@ public: { // behavioral flags Optional multi_select, - commit_on_keyboard_movement; + commit_on_keyboard_movement, + mouse_wheel_opaque; // display flags Optional has_border, @@ -449,6 +450,7 @@ private: BOOL mCommitOnSelectionChange; BOOL mSelectionChanged; BOOL mNeedsScroll; + BOOL mMouseWheelOpaque; BOOL mCanSelect; const BOOL mDisplayColumnHeaders; BOOL mColumnsDirty; 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 2c9d7e4b6a..082d51ed3c 100644 --- a/indra/newview/skins/default/xui/en/panel_navigation_bar.xml +++ b/indra/newview/skins/default/xui/en/panel_navigation_bar.xml @@ -97,6 +97,8 @@ name="location_combo" top_delta="0" width="266"> +