diff --git a/autobuild.xml b/autobuild.xml index b3de2fc836..3842917280 100644 --- a/autobuild.xml +++ b/autobuild.xml @@ -724,9 +724,9 @@ archive hash - 4699b8389dfb754da0393ddb5d325722 + f283a064c30695bd7bf071f1bd481f32 url - https://automated-builds-secondlife-com.s3.amazonaws.com/ct2/95882/856117/colladadom-2.3.569219-darwin64-569219.tar.bz2 + https://3p.firestormviewer.org/colladadom-2.3.222232011-darwin64-222232011.tar.bz2 name darwin64 @@ -736,9 +736,9 @@ archive hash - e1a8e9eca2894687b3532474ffc9b326 + 30b1a9b7637f7a1546d38430064ca582 url - http://3p.firestormviewer.org/colladadom-2.3.222130404-linux64-222130404.tar.bz2 + https://3p.firestormviewer.org/colladadom-2.3.222261253-linux64-222261253.tar.bz2 name linux64 @@ -748,9 +748,9 @@ archive hash - 343e46ea49a08ad6596d3dc702d5b812 + 1c094d709a35b252bba7b6ef1871085c url - https://automated-builds-secondlife-com.s3.amazonaws.com/ct2/95883/856128/colladadom-2.3.569219-windows-569219.tar.bz2 + https://3p.firestormviewer.org/colladadom-2.3.222231850-windows-222231850.tar.bz2 name windows @@ -760,9 +760,9 @@ archive hash - de5bdfb61b31db56c5fe7d0962ad11e2 + a7596da3696fc423ec1bc7d6764c01ab url - https://automated-builds-secondlife-com.s3.amazonaws.com/ct2/95884/856129/colladadom-2.3.569219-windows64-569219.tar.bz2 + https://3p.firestormviewer.org/colladadom-2.3.222231903-windows64-222231903.tar.bz2 name windows64 @@ -1098,11 +1098,11 @@ archive hash - 9aac95d85fd3f044da3fd9dd44ed5ca2 + 21d50d222f005c033452ee3fad44bff1 hash_algorithm md5 url - file:///opt/firestorm/fmodstudio-2.02.06-linux64_bionic-220911506.tar.bz2 + file:///opt/firestorm/fmodstudio-2.02.07-linux64_bionic-222191132.tar.bz2 name linux64 @@ -2975,7 +2975,7 @@ Copyright (c) 2012, 2014, 2015, 2016 nghttp2 contributors http://3p.firestormviewer.org/threejs-0.132.2-linux64-213500940.tar.bz2 name - darwin64 + linux64 darwin64 diff --git a/indra/CMakeLists.txt b/indra/CMakeLists.txt index 962f9d006c..0ef50363d9 100644 --- a/indra/CMakeLists.txt +++ b/indra/CMakeLists.txt @@ -6,8 +6,10 @@ ## 3.8 added VS_DEBUGGER_WORKING_DIRECTORY support cmake_minimum_required(VERSION 3.12.0 FATAL_ERROR) -set(ROOT_PROJECT_NAME "SecondLife" CACHE STRING - "The root project/makefile/solution name. Defaults to SecondLife.") +set(CMAKE_CXX_STANDARD 17) # Enable c++17 on all platforms + +set(ROOT_PROJECT_NAME "Firestorm" CACHE STRING + "The root project/makefile/solution name. Defaults to Firestorm.") project(${ROOT_PROJECT_NAME}) set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake") @@ -21,8 +23,8 @@ if (WINDOWS) endif (WINDOWS) if (NOT CMAKE_BUILD_TYPE) - set(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING - "Build type. One of: Debug Release RelWithDebInfo" FORCE) + set(CMAKE_BUILD_TYPE Release CACHE STRING + "Build type. One of: Release RelWithDebInfo" FORCE) endif (NOT CMAKE_BUILD_TYPE) # diff --git a/indra/cmake/00-Common.cmake b/indra/cmake/00-Common.cmake index e34283d728..1045a6efae 100644 --- a/indra/cmake/00-Common.cmake +++ b/indra/cmake/00-Common.cmake @@ -109,38 +109,6 @@ if (WINDOWS) /DNOMINMAX # /DDOM_DYNAMIC # For shared library colladadom ) - - # AVX/AVX2 support - if (USE_AVX_OPTIMIZATION) - add_compile_options( - /GS - /TP - /W3 - /c - /Zc:forScope - /nologo - /Oy- - /Oi - /Ot - /arch:AVX - /fp:fast - ) - elseif (USE_AVX2_OPTIMIZATION) - add_compile_options( - /GS - /TP - /W3 - /c - /Zc:forScope - /nologo - /Oy- - /Oi - /Ot - /arch:AVX2 - /fp:fast - ) - else (USE_AVX_OPTIMIZATION) - # AVX/AVX2 support add_compile_options( /GS /TP @@ -154,13 +122,20 @@ if (WINDOWS) # /arch:SSE2 /fp:fast ) - # Nicky: x64 implies SSE2 - if( ADDRESS_SIZE EQUAL 32 ) - add_definitions( /arch:SSE2 ) - endif() + # AVX/AVX2 support + if (USE_AVX_OPTIMIZATION) + add_compile_options(/arch:AVX) + elseif (USE_AVX2_OPTIMIZATION) + add_compile_options(/arch:AVX2) + else (USE_AVX_OPTIMIZATION) + # Nicky: x64 implies SSE2 + if (ADDRESS_SIZE EQUAL 32) + add_compile_options(/arch:SSE2) + endif() endif (USE_AVX_OPTIMIZATION) - + # AVX/AVX2 support + # Are we using the crummy Visual Studio KDU build workaround? if (NOT VS_DISABLE_FATAL_WARNINGS) add_definitions(/WX) @@ -276,9 +251,13 @@ if (LINUX OR DARWIN) set(GCC_CXX_WARNINGS "$[GCC_WARNINGS] -Wno-reorder -Wno-unused-const-variable -Wno-format-extra-args -Wno-unused-private-field -Wno-unused-function -Wno-tautological-compare -Wno-empty-body -Wno-unused-variable -Wno-unused-value") else (${CMAKE_CXX_COMPILER_ID} STREQUAL "Clang" AND DARWIN AND XCODE_VERSION GREATER 4.9) #elseif (${CMAKE_CXX_COMPILER_ID} STREQUAL "GNU") - set(GCC_CXX_WARNINGS "${GCC_WARNINGS} -Wno-reorder -Wno-non-virtual-dtor") + set(GCC_CXX_WARNINGS "${GCC_WARNINGS} -Wno-reorder -Wno-non-virtual-dtor -Wno-unused-variable") endif () + if(LINUX) + set(GCC_CXX_WARNINGS "${GCC_WARNINGS} -Wno-reorder -Wno-non-virtual-dtor -Wno-unused-variable -Wno-unused-but-set-variable -Wno-pragmas -Wno-deprecated") + endif() + set(CMAKE_C_FLAGS "${GCC_WARNINGS} ${CMAKE_C_FLAGS}") set(CMAKE_CXX_FLAGS "${GCC_CXX_WARNINGS} ${CMAKE_CXX_FLAGS}") diff --git a/indra/cmake/LLWindow.cmake b/indra/cmake/LLWindow.cmake index 1b0370cc14..58b842f4b5 100644 --- a/indra/cmake/LLWindow.cmake +++ b/indra/cmake/LLWindow.cmake @@ -18,7 +18,7 @@ if (USESYSTEMLIBS) ) else (USESYSTEMLIBS) if (LINUX) - if( NOT USE_SDL2 ) + if( USE_SDL1 ) use_prebuilt_binary(SDL) set (SDL_FOUND TRUE) diff --git a/indra/llcommon/llsd.h b/indra/llcommon/llsd.h index 24cb9bbce1..1f503938b5 100644 --- a/indra/llcommon/llsd.h +++ b/indra/llcommon/llsd.h @@ -421,49 +421,6 @@ public: static std::string typeString(Type type); // Return human-readable type as a string }; -struct llsd_select_bool : public std::unary_function -{ - LLSD::Boolean operator()(const LLSD& sd) const - { - return sd.asBoolean(); - } -}; -struct llsd_select_integer : public std::unary_function -{ - LLSD::Integer operator()(const LLSD& sd) const - { - return sd.asInteger(); - } -}; -struct llsd_select_real : public std::unary_function -{ - LLSD::Real operator()(const LLSD& sd) const - { - return sd.asReal(); - } -}; -struct llsd_select_float : public std::unary_function -{ - F32 operator()(const LLSD& sd) const - { - return (F32)sd.asReal(); - } -}; -struct llsd_select_uuid : public std::unary_function -{ - LLSD::UUID operator()(const LLSD& sd) const - { - return sd.asUUID(); - } -}; -struct llsd_select_string : public std::unary_function -{ - LLSD::String operator()(const LLSD& sd) const - { - return sd.asString(); - } -}; - LL_COMMON_API std::ostream& operator<<(std::ostream& s, const LLSD& llsd); namespace llsd diff --git a/indra/llcommon/llstl.h b/indra/llcommon/llstl.h index a90c2c7e08..3e81179957 100644 --- a/indra/llcommon/llstl.h +++ b/indra/llcommon/llstl.h @@ -40,31 +40,6 @@ // For strcmp #include #endif -// Use to compare the first element only of a pair -// e.g. typedef std::set, compare_pair > some_pair_set_t; -template -struct compare_pair_first -{ - bool operator()(const std::pair& a, const std::pair& b) const - { - return a.first < b.first; - } -}; - -template -struct compare_pair_greater -{ - bool operator()(const std::pair& a, const std::pair& b) const - { - if (!(a.first < b.first)) - return true; - else if (!(b.first < a.first)) - return false; - else - return !(a.second < b.second); - } -}; - // Use to compare the contents of two pointers (e.g. std::string*) template struct compare_pointer_contents @@ -123,58 +98,6 @@ struct DeletePairedPointerArray }; -// Alternate version of the above so that has a more cumbersome -// syntax, but it can be used with compositional functors. -// NOTE: The functor retuns a bool because msdev bombs during the -// composition if you return void. Once we upgrade to a newer -// compiler, the second unary_function template parameter can be set -// to void. -// -// Here's a snippet showing how you use this object: -// -// typedef std::map map_type; -// map_type widget_map; -// ... // add elements -// // delete them all -// for_each(widget_map.begin(), -// widget_map.end(), -// llcompose1(DeletePointerFunctor(), -// llselect2nd())); - -template -struct DeletePointerFunctor : public std::unary_function -{ - bool operator()(T* ptr) const - { - delete ptr; - return true; - } -}; - -// See notes about DeleteArray for why you should consider avoiding this. -template -struct DeleteArrayFunctor : public std::unary_function -{ - bool operator()(T* ptr) const - { - delete[] ptr; - return true; - } -}; - -// CopyNewPointer is a simple helper which accepts a pointer, and -// returns a new pointer built with the copy constructor. Example: -// -// transform(in.begin(), in.end(), out.end(), CopyNewPointer()); - -struct CopyNewPointer -{ - template T* operator()(const T* ptr) const - { - return new T(*ptr); - } -}; - template void delete_and_clear(std::list& list) { @@ -363,161 +286,6 @@ OutputIter ll_transform_n( } - -/* - * - * Copyright (c) 1994 - * Hewlett-Packard Company - * - * Permission to use, copy, modify, distribute and sell this software - * and its documentation for any purpose is hereby granted without fee, - * provided that the above copyright notice appear in all copies and - * that both that copyright notice and this permission notice appear - * in supporting documentation. Hewlett-Packard Company makes no - * representations about the suitability of this software for any - * purpose. It is provided "as is" without express or implied warranty. - * - * - * Copyright (c) 1996-1998 - * Silicon Graphics Computer Systems, Inc. - * - * Permission to use, copy, modify, distribute and sell this software - * and its documentation for any purpose is hereby granted without fee, - * provided that the above copyright notice appear in all copies and - * that both that copyright notice and this permission notice appear - * in supporting documentation. Silicon Graphics makes no - * representations about the suitability of this software for any - * purpose. It is provided "as is" without express or implied warranty. - */ - - -// helper to deal with the fact that MSDev does not package -// select... with the stl. Look up usage on the sgi website. - -template -struct _LLSelect1st : public std::unary_function<_Pair, typename _Pair::first_type> { - const typename _Pair::first_type& operator()(const _Pair& __x) const { - return __x.first; - } -}; - -template -struct _LLSelect2nd : public std::unary_function<_Pair, typename _Pair::second_type> -{ - const typename _Pair::second_type& operator()(const _Pair& __x) const { - return __x.second; - } -}; - -template struct llselect1st : public _LLSelect1st<_Pair> {}; -template struct llselect2nd : public _LLSelect2nd<_Pair> {}; - -// helper to deal with the fact that MSDev does not package -// compose... with the stl. Look up usage on the sgi website. - -template -class ll_unary_compose : - public std::unary_function -{ -protected: - _Operation1 __op1; - _Operation2 __op2; -public: - ll_unary_compose(const _Operation1& __x, const _Operation2& __y) - : __op1(__x), __op2(__y) {} - typename _Operation1::result_type - operator()(const typename _Operation2::argument_type& __x) const { - return __op1(__op2(__x)); - } -}; - -template -inline ll_unary_compose<_Operation1,_Operation2> -llcompose1(const _Operation1& __op1, const _Operation2& __op2) -{ - return ll_unary_compose<_Operation1,_Operation2>(__op1, __op2); -} - -template -class ll_binary_compose - : public std::unary_function { -protected: - _Operation1 _M_op1; - _Operation2 _M_op2; - _Operation3 _M_op3; -public: - ll_binary_compose(const _Operation1& __x, const _Operation2& __y, - const _Operation3& __z) - : _M_op1(__x), _M_op2(__y), _M_op3(__z) { } - typename _Operation1::result_type - operator()(const typename _Operation2::argument_type& __x) const { - return _M_op1(_M_op2(__x), _M_op3(__x)); - } -}; - -template -inline ll_binary_compose<_Operation1, _Operation2, _Operation3> -llcompose2(const _Operation1& __op1, const _Operation2& __op2, - const _Operation3& __op3) -{ - return ll_binary_compose<_Operation1,_Operation2,_Operation3> - (__op1, __op2, __op3); -} - -// helpers to deal with the fact that MSDev does not package -// bind... with the stl. Again, this is from sgi. -template -class llbinder1st : - public std::unary_function { -protected: - _Operation op; - typename _Operation::first_argument_type value; -public: - llbinder1st(const _Operation& __x, - const typename _Operation::first_argument_type& __y) - : op(__x), value(__y) {} - typename _Operation::result_type - operator()(const typename _Operation::second_argument_type& __x) const { - return op(value, __x); - } -}; - -template -inline llbinder1st<_Operation> -llbind1st(const _Operation& __oper, const _Tp& __x) -{ - typedef typename _Operation::first_argument_type _Arg1_type; - return llbinder1st<_Operation>(__oper, _Arg1_type(__x)); -} - -template -class llbinder2nd - : public std::unary_function { -protected: - _Operation op; - typename _Operation::second_argument_type value; -public: - llbinder2nd(const _Operation& __x, - const typename _Operation::second_argument_type& __y) - : op(__x), value(__y) {} - typename _Operation::result_type - operator()(const typename _Operation::first_argument_type& __x) const { - return op(__x, value); - } -}; - -template -inline llbinder2nd<_Operation> -llbind2nd(const _Operation& __oper, const _Tp& __x) -{ - typedef typename _Operation::second_argument_type _Arg2_type; - return llbinder2nd<_Operation>(__oper, _Arg2_type(__x)); -} - /** * Compare std::type_info* pointers a la std::less. We break this out as a * separate function for use in two different std::less specializations. @@ -548,8 +316,7 @@ bool before(const std::type_info* lhs, const std::type_info* rhs) namespace std { template <> - struct less: - public std::binary_function + struct less { bool operator()(const std::type_info* lhs, const std::type_info* rhs) const { @@ -558,8 +325,7 @@ namespace std }; template <> - struct less: - public std::binary_function + struct less { bool operator()(std::type_info* lhs, std::type_info* rhs) const { diff --git a/indra/llcommon/llstring.h b/indra/llcommon/llstring.h index b5f1564c45..baa50b47bf 100644 --- a/indra/llcommon/llstring.h +++ b/indra/llcommon/llstring.h @@ -42,6 +42,7 @@ // [RLVa:KB] - Checked: RLVa-2.1.0 #include // [/RLVa:KB] +#include #if LL_LINUX #include diff --git a/indra/llcommon/tests/llleap_test.cpp b/indra/llcommon/tests/llleap_test.cpp index 9754353ab0..d12f2935e8 100644 --- a/indra/llcommon/tests/llleap_test.cpp +++ b/indra/llcommon/tests/llleap_test.cpp @@ -531,7 +531,7 @@ namespace tut result.ensure(); } - struct TestLargeMessage: public std::binary_function + struct TestLargeMessage { TestLargeMessage(const std::string& PYTHON_, const std::string& reader_module_, const std::string& test_name_): diff --git a/indra/llcorehttp/CMakeLists.txt b/indra/llcorehttp/CMakeLists.txt index 1074f111d3..b7dfb5ba71 100644 --- a/indra/llcorehttp/CMakeLists.txt +++ b/indra/llcorehttp/CMakeLists.txt @@ -24,9 +24,11 @@ include_directories (${CMAKE_CURRENT_SOURCE_DIR}) include_directories( ${LLMESSAGE_INCLUDE_DIRS} ${LLCOMMON_INCLUDE_DIRS} - ${LLCOREHTTP_INCLUDE_DIRS} +# ${LLCOREHTTP_INCLUDE_DIRS} Make this system include directories. ) +include_directories( SYSTEM ${LLCOREHTTP_INCLUDE_DIRS} ) + set(llcorehttp_SOURCE_FILES bufferarray.cpp bufferstream.cpp diff --git a/indra/llinventory/llparcel.cpp b/indra/llinventory/llparcel.cpp index b39407f54f..e195d33f18 100644 --- a/indra/llinventory/llparcel.cpp +++ b/indra/llinventory/llparcel.cpp @@ -1269,5 +1269,5 @@ U32 LLParcel::countExperienceKeyType( U32 type ) return std::count_if( boost::begin(mExperienceKeys | boost::adaptors::map_values), boost::end(mExperienceKeys | boost::adaptors::map_values), - std::bind2nd(std::equal_to(), type)); + [type](U32 key) { return key == type; }); } diff --git a/indra/llmath/llcalcparser.h b/indra/llmath/llcalcparser.h index 387f93b98e..7054abd5bc 100644 --- a/indra/llmath/llcalcparser.h +++ b/indra/llmath/llcalcparser.h @@ -141,14 +141,14 @@ struct LLCalcParser : grammar power = unary_expr[power.value = arg1] >> - *('^' >> assert_syntax(unary_expr[power.value = /* Replace bind with phoenix::bind to make GCC happy*/ phoenix::bind(&powf)(power.value, arg1)])) + *('^' >> assert_syntax(unary_expr[power.value = /* Replace bind with phoenix::bind to make GCC happy*/ phoenix::bind(&LLCalcParser::_pow)(self, power.value, arg1)])) ; term = power[term.value = arg1] >> *(('*' >> assert_syntax(power[term.value *= arg1])) | ('/' >> assert_syntax(power[term.value /= arg1])) | - ('%' >> assert_syntax(power[term.value = /* Replace bind with phoenix::bind to make GCC happy*/ phoenix::bind(&fmodf)(term.value, arg1)])) + ('%' >> assert_syntax(power[term.value = /* Replace bind with phoenix::bind to make GCC happy*/ phoenix::bind(&LLCalcParser::_fmod)(self, term.value, arg1)])) ) ; @@ -195,6 +195,8 @@ private: F32 _floor(const F32& a) const { return (F32)llfloor(a); } F32 _ceil(const F32& a) const { return llceil(a); } F32 _atan2(const F32& a,const F32& b) const { return atan2(a,b); } + F32 _pow(const F32& a, const F32& b) const { return powf(a, b); } + F32 _fmod(const F32&a, const F32& b) const { return fmodf(a, b); } LLCalc::calc_map_t* mConstants; LLCalc::calc_map_t* mVariables; diff --git a/indra/llmath/lloctree.h b/indra/llmath/lloctree.h index 55d6cc9348..9d12929323 100644 --- a/indra/llmath/lloctree.h +++ b/indra/llmath/lloctree.h @@ -852,8 +852,6 @@ public: llassert(size[0] >= gOctreeMinSize); - llassert(size[0] >= gOctreeMinSize); - //copy our children to a new branch LLOctreeNode* newnode = new LLOctreeNode(center, size, this); diff --git a/indra/llmessage/llcircuit.cpp b/indra/llmessage/llcircuit.cpp index 5e5639da19..bb04590758 100644 --- a/indra/llmessage/llcircuit.cpp +++ b/indra/llmessage/llcircuit.cpp @@ -443,12 +443,11 @@ LLCircuit::LLCircuit(const F32Seconds circuit_heartbeat_interval, const F32Secon LLCircuit::~LLCircuit() { - // delete pointers in the map. - std::for_each(mCircuitData.begin(), - mCircuitData.end(), - llcompose1( - DeletePointerFunctor(), - llselect2nd())); + // delete pointers in the map. + for (auto circ_pair : mCircuitData) + { + delete circ_pair.second; + } } LLCircuitData *LLCircuit::addCircuitData(const LLHost &host, TPACKETID in_id) diff --git a/indra/llmessage/lldispatcher.cpp b/indra/llmessage/lldispatcher.cpp index 717ef10f70..278b3023f8 100644 --- a/indra/llmessage/lldispatcher.cpp +++ b/indra/llmessage/lldispatcher.cpp @@ -62,7 +62,7 @@ void LLDispatcher::copyAllHandlerNames(keys_t& names) const mHandlers.begin(), mHandlers.end(), std::back_insert_iterator(names), - llselect1st()); + [](const dispatch_map_t::value_type& pair) { return pair.first; }); } bool LLDispatcher::dispatch( diff --git a/indra/llmessage/llmessagethrottle.cpp b/indra/llmessage/llmessagethrottle.cpp index 579d6d7187..c5ae8b4547 100644 --- a/indra/llmessage/llmessagethrottle.cpp +++ b/indra/llmessage/llmessagethrottle.cpp @@ -32,18 +32,8 @@ #include "llframetimer.h" // This is used for the stl search_n function. -#if _MSC_VER >= 1500 // VC9 has a bug in search_n -struct eq_message_throttle_entry : public std::binary_function< LLMessageThrottleEntry, LLMessageThrottleEntry, bool > -{ - bool operator()(const LLMessageThrottleEntry& a, const LLMessageThrottleEntry& b) const - { - return a.getHash() == b.getHash(); - } -}; -#else bool eq_message_throttle_entry(LLMessageThrottleEntry a, LLMessageThrottleEntry b) { return a.getHash() == b.getHash(); } -#endif const U64 SEC_TO_USEC = 1000000; @@ -118,14 +108,8 @@ BOOL LLMessageThrottle::addViewerAlert(const LLUUID& to, const std::string& mesg LLMessageThrottleEntry entry(hash, LLFrameTimer::getTotalTime()); // Check if this message is already in the list. -#if _MSC_VER >= 1500 // VC9 has a bug in search_n - // SJB: This *should* work but has not been tested yet *TODO: Test! - message_list_iterator_t found = std::find_if(message_list->begin(), message_list->end(), - std::bind2nd(eq_message_throttle_entry(), entry)); -#else message_list_iterator_t found = std::search_n(message_list->begin(), message_list->end(), 1, entry, eq_message_throttle_entry); -#endif if (found == message_list->end()) { // This message was not found. Add it to the list. @@ -152,14 +136,8 @@ BOOL LLMessageThrottle::addAgentAlert(const LLUUID& agent, const LLUUID& task, c LLMessageThrottleEntry entry(hash, LLFrameTimer::getTotalTime()); // Check if this message is already in the list. -#if _MSC_VER >= 1500 // VC9 has a bug in search_n - // SJB: This *should* work but has not been tested yet *TODO: Test! - message_list_iterator_t found = std::find_if(message_list->begin(), message_list->end(), - std::bind2nd(eq_message_throttle_entry(), entry)); -#else message_list_iterator_t found = std::search_n(message_list->begin(), message_list->end(), 1, entry, eq_message_throttle_entry); -#endif if (found == message_list->end()) { diff --git a/indra/llprimitive/CMakeLists.txt b/indra/llprimitive/CMakeLists.txt index fa1e01d22c..c2069ce3f8 100644 --- a/indra/llprimitive/CMakeLists.txt +++ b/indra/llprimitive/CMakeLists.txt @@ -19,17 +19,13 @@ include_directories( ${LLXML_INCLUDE_DIRS} # ${LIBS_PREBUILT_DIR}/include/collada # ${LIBS_PREBUILT_DIR}/include/collada/1.4 - ${COLLADA_INCLUDE_DIRS} ${LLCHARACTER_INCLUDE_DIRS} ) -include_directories(SYSTEM - ${LLCOMMON_SYSTEM_INCLUDE_DIRS} - ${LLXML_SYSTEM_INCLUDE_DIRS} - ) include_directories(SYSTEM ${LLCOMMON_SYSTEM_INCLUDE_DIRS} ${LLXML_SYSTEM_INCLUDE_DIRS} ${LLPHYSICSEXTENSIONS_INCLUDE_DIRS} + ${COLLADA_INCLUDE_DIRS} ) set(llprimitive_SOURCE_FILES diff --git a/indra/llui/lldockablefloater.cpp b/indra/llui/lldockablefloater.cpp index b822379049..c937d190c6 100644 --- a/indra/llui/lldockablefloater.cpp +++ b/indra/llui/lldockablefloater.cpp @@ -166,7 +166,6 @@ void LLDockableFloater::setMinimized(BOOL minimize) { // minimizing a docked floater just hides it setVisible(FALSE); - gFocusMgr.releaseFocusIfNeeded(this); // FIRE-31882: Release focus or main menu bar would receive it in LLViewerWindow::updateKeyboardFocus() } else { diff --git a/indra/llui/lldockablefloater.h b/indra/llui/lldockablefloater.h index 0e7c201bdf..326cc57b89 100644 --- a/indra/llui/lldockablefloater.h +++ b/indra/llui/lldockablefloater.h @@ -108,7 +108,7 @@ public: * * By default returns false. */ - virtual bool overlapsScreenChannel() { return mOverlapsScreenChannel && getVisible() && isDocked(); } + virtual bool overlapsScreenChannel() const { return mOverlapsScreenChannel && getVisible() && isDocked(); } virtual void setOverlapsScreenChannel(bool overlaps) { mOverlapsScreenChannel = overlaps; } bool getUniqueDocking() { return mUniqueDocking; } @@ -131,7 +131,7 @@ protected: boost::function mIsDockedStateForcedCallback; //private: // Make mDockControl accessible from children because of FIRE-16803 - std::auto_ptr mDockControl; + std::unique_ptr mDockControl; private: // Make mDockControl accessible from children because of FIRE-16803 LLUIImagePtr mDockTongue; static LLHandle sInstanceHandle; diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp index 0616ed179c..b042beb13c 100644 --- a/indra/llui/llmenugl.cpp +++ b/indra/llui/llmenugl.cpp @@ -1545,16 +1545,18 @@ void LLMenuItemBranchDownGL::onFocusLost() { // needed for tab-based selection LLMenuItemBranchGL::onFocusLost(); - LLMenuGL::setKeyboardMode(FALSE); - setHighlight(FALSE); + // FIRE-31882 / FIRE-31896 / FIRE-31913 / FIRE-31920: Fix all kind of weird menu focus issues + //LLMenuGL::setKeyboardMode(FALSE); + //setHighlight(FALSE); } void LLMenuItemBranchDownGL::setFocus(BOOL b) { // needed for tab-based selection LLMenuItemBranchGL::setFocus(b); - LLMenuGL::setKeyboardMode(b); - setHighlight(b); + // FIRE-31882 / FIRE-31896 / FIRE-31913 / FIRE-31920: Fix all kind of weird menu focus issues + //LLMenuGL::setKeyboardMode(b); + //setHighlight(b); } BOOL LLMenuItemBranchDownGL::handleKeyHere(KEY key, MASK mask) diff --git a/indra/llui/lltextbase.cpp b/indra/llui/lltextbase.cpp index 4babd5028d..b74f2bf00a 100644 --- a/indra/llui/lltextbase.cpp +++ b/indra/llui/lltextbase.cpp @@ -2454,6 +2454,18 @@ void LLTextBase::setFont(const LLFontGL* font) { mFont = font; mStyleDirty = true; + + // FIRE-29425: User-selectable font and size for notecards + for (auto segment : mSegments) + { + LLStyleConstSP style = segment->getStyle(); + LLStyleSP new_style(new LLStyle(*style)); + new_style->setFont(mFont); + LLStyleConstSP sp(new_style); + segment->setStyle(sp); + } + needsReflow(); + // } void LLTextBase::needsReflow(S32 index) diff --git a/indra/llwindow/CMakeLists.txt b/indra/llwindow/CMakeLists.txt index d60add4d63..abda4c7900 100644 --- a/indra/llwindow/CMakeLists.txt +++ b/indra/llwindow/CMakeLists.txt @@ -81,7 +81,7 @@ if (LINUX) libfreetype.a ) - if( NOT USE_SDL2 ) + if( USE_SDL1 ) list(APPEND viewer_SOURCE_FILES llkeyboardsdl.cpp llwindowsdl.cpp diff --git a/indra/llwindow/llopenglview-objc.mm b/indra/llwindow/llopenglview-objc.mm index 648fff58f8..f0b15b46d5 100644 --- a/indra/llwindow/llopenglview-objc.mm +++ b/indra/llwindow/llopenglview-objc.mm @@ -510,14 +510,14 @@ attributedStringInfo getSegments(NSAttributedString *str) // e.g. OS Window for upload something or Input Window... // mModifiers instance variable is for insertText: or insertText:replacementRange: (by Pell Smit) mModifiers = [theEvent modifierFlags]; + unichar ch = [[theEvent charactersIgnoringModifiers] characterAtIndex:0]; + bool acceptsText = mHasMarkedText ? false : callKeyDown(&eventData, keycode, mModifiers, ch); - bool acceptsText = mHasMarkedText ? false : callKeyDown(&eventData, keycode, mModifiers, [[theEvent characters] characterAtIndex:0]); - unichar ch; if (acceptsText && !mMarkedTextAllowed && !(mModifiers & (NSControlKeyMask | NSCommandKeyMask)) && // commands don't invoke InputWindow ![(LLAppDelegate*)[NSApp delegate] romanScript] && - (ch = [[theEvent charactersIgnoringModifiers] characterAtIndex:0]) > ' ' && + ch > ' ' && ch != NSDeleteCharacter && (ch < 0xF700 || ch > 0xF8FF)) // 0xF700-0xF8FF: reserved for function keys on the keyboard(from NSEvent.h) { @@ -554,7 +554,9 @@ attributedStringInfo getSegments(NSAttributedString *str) if (mModifiers & mask) { eventData.mKeyEvent = NativeKeyEventData::KEYDOWN; - callKeyDown(&eventData, [theEvent keyCode], 0, [[theEvent characters] characterAtIndex:0]); + // Speculative fix for FIRE-31473 + //callKeyDown(&eventData, [theEvent keyCode], 0, [[theEvent characters] characterAtIndex:0]); + callKeyDown(&eventData, [theEvent keyCode], 0, L'\0'); } else { diff --git a/indra/llwindow/llwindowmacosx-objc.mm b/indra/llwindow/llwindowmacosx-objc.mm index 41db6ae98e..2a88049c5c 100644 --- a/indra/llwindow/llwindowmacosx-objc.mm +++ b/indra/llwindow/llwindowmacosx-objc.mm @@ -476,14 +476,6 @@ long showAlert(std::string text, std::string title, int type) unsigned int getModifiers() { - // Try current event of app first, otherwise we might get wrong results - NSEvent *pEvent = [NSApp currentEvent]; - if( pEvent != nil ) - { - return [pEvent modifierFlags]; - } - // - return [NSEvent modifierFlags]; } diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt index f7669c8b13..b147aef369 100644 --- a/indra/newview/CMakeLists.txt +++ b/indra/newview/CMakeLists.txt @@ -104,12 +104,8 @@ include_directories( ${LLWINDOW_INCLUDE_DIRS} ${LLXML_INCLUDE_DIRS} ${LLLOGIN_INCLUDE_DIRS} - ${LIBS_PREBUILT_DIR}/include/collada - ${LIBS_PREBUILD_DIR}/include/hunspell ${OPENAL_LIB_INCLUDE_DIRS} - ${LIBS_PREBUILT_DIR}/include/collada/1.4 ${GROWL_INCLUDE_DIRS} - ${COLLADA_INCLUDE_DIRS} ${LLAPPEARANCE_INCLUDE_DIRS} ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR} @@ -120,6 +116,10 @@ include_directories(SYSTEM ${LLCOMMON_SYSTEM_INCLUDE_DIRS} ${LLXML_SYSTEM_INCLUDE_DIRS} ${LLPHYSICSEXTENSIONS_INCLUDE_DIRS} + ${LIBS_PREBUILT_DIR}/include/collada + ${LIBS_PREBUILT_DIR}/include/collada/1.4 + ${LIBS_PREBUILD_DIR}/include/hunspell + ${COLLADA_INCLUDE_DIRS} ) if (USE_BUGSPLAT) @@ -170,6 +170,7 @@ set(viewer_SOURCE_FILES fsfloaterim.cpp fsfloaterimcontainer.cpp fsfloaternearbychat.cpp + fsfloaterpartialinventory.cpp fsfloaterplacedetails.cpp fsfloaterposestand.cpp fsfloaterprofile.cpp @@ -943,6 +944,7 @@ set(viewer_HEADER_FILES fsfloaterim.h fsfloaterimcontainer.h fsfloaternearbychat.h + fsfloaterpartialinventory.h fsfloaterplacedetails.h fsfloaterposestand.h fsfloaterprofile.h @@ -2776,31 +2778,32 @@ if (PACKAGE AND (RELEASE_CRASH_REPORTING OR NON_RELEASE_CRASH_REPORTING) AND VIE if (USE_BUGSPLAT) # BugSplat symbol-file generation if (WINDOWS) + # Comment this out, we do our own symbol package which also includes the exe and build_data.json # Just pack up a tarball containing only the .pdb file for the # executable. Because we intend to use cygwin tar, we must render # VIEWER_SYMBOL_FILE in cygwin path syntax. - execute_process(COMMAND "cygpath" "-u" "${VIEWER_SYMBOL_FILE}" - OUTPUT_VARIABLE VIEWER_SYMBOL_FILE_CYGWIN - OUTPUT_STRIP_TRAILING_WHITESPACE) - execute_process(COMMAND "cygpath" "-u" "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}" - OUTPUT_VARIABLE PARENT_DIRECTORY_CYGWIN - OUTPUT_STRIP_TRAILING_WHITESPACE) - add_custom_command(OUTPUT "${VIEWER_SYMBOL_FILE}" - # Use of 'tar ...j' here assumes VIEWER_SYMBOL_FILE endswith .tar.bz2; - # testing a string suffix is painful enough in CMake language that - # we'll continue assuming it until forced to generalize. - COMMAND "tar" - ARGS - "cjf" - "${VIEWER_SYMBOL_FILE_CYGWIN}" - "-C" - "${PARENT_DIRECTORY_CYGWIN}" - "firestorm-bin.pdb" - DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/firestorm-bin.pdb" - COMMENT "Packing viewer PDB into ${VIEWER_SYMBOL_FILE_CYGWIN}" - ) - add_custom_target(generate_symbols DEPENDS "${VIEWER_SYMBOL_FILE}" ${VIEWER_BINARY_NAME}) - add_dependencies(generate_symbols ${VIEWER_BINARY_NAME}) + # execute_process(COMMAND "cygpath" "-u" "${VIEWER_SYMBOL_FILE}" + # OUTPUT_VARIABLE VIEWER_SYMBOL_FILE_CYGWIN + # OUTPUT_STRIP_TRAILING_WHITESPACE) + # execute_process(COMMAND "cygpath" "-u" "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}" + # OUTPUT_VARIABLE PARENT_DIRECTORY_CYGWIN + # OUTPUT_STRIP_TRAILING_WHITESPACE) + # add_custom_command(OUTPUT "${VIEWER_SYMBOL_FILE}" + # # Use of 'tar ...j' here assumes VIEWER_SYMBOL_FILE endswith .tar.bz2; + # # testing a string suffix is painful enough in CMake language that + # # we'll continue assuming it until forced to generalize. + # COMMAND "tar" + # ARGS + # "cjf" + # "${VIEWER_SYMBOL_FILE_CYGWIN}" + # "-C" + # "${PARENT_DIRECTORY_CYGWIN}" + # "firestorm-bin.pdb" + # DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR}/firestorm-bin.pdb" + # COMMENT "Packing viewer PDB into ${VIEWER_SYMBOL_FILE_CYGWIN}" + # ) + # add_custom_target(generate_symbols DEPENDS "${VIEWER_SYMBOL_FILE}" ${VIEWER_BINARY_NAME}) + # add_dependencies(generate_symbols ${VIEWER_BINARY_NAME}) endif (WINDOWS) if (DARWIN) # Have to run dsymutil first, then pack up the resulting .dSYM directory @@ -2859,7 +2862,7 @@ if (PACKAGE AND (RELEASE_CRASH_REPORTING OR NON_RELEASE_CRASH_REPORTING) AND VIE endif (LINUX) endif (USE_BUGSPLAT) - if (NOT LINUX) #Linux generates symbols via viewer_manifest.py/fs_viewer_manifest.py + if (DARWIN) #Linux/Windows generates symbols via viewer_manifest.py/fs_viewer_manifest.py # for both Bugsplat and Breakpad add_dependencies(llpackage generate_symbols) endif() diff --git a/indra/newview/VIEWER_VERSION.txt b/indra/newview/VIEWER_VERSION.txt index e411592c25..b22e754ac6 100644 --- a/indra/newview/VIEWER_VERSION.txt +++ b/indra/newview/VIEWER_VERSION.txt @@ -1 +1 @@ -6.6.3 +6.6.4 diff --git a/indra/newview/aoengine.cpp b/indra/newview/aoengine.cpp index d9f39434fc..e649c2a879 100644 --- a/indra/newview/aoengine.cpp +++ b/indra/newview/aoengine.cpp @@ -223,19 +223,18 @@ bool AOEngine::foreignAnimations() LL_DEBUGS("AOEngine") << "Checking for foreign animation on seat " << seat << LL_ENDL; - for (LLVOAvatar::AnimSourceIterator sourceIterator = gAgentAvatarp->mAnimationSources.begin(); - sourceIterator != gAgentAvatarp->mAnimationSources.end(); ++sourceIterator) + for (const auto&[source_id, animation_id] : gAgentAvatarp->mAnimationSources) { // skip animations run by the avatar itself - if (sourceIterator->first != gAgentID) + if (source_id != gAgentID) { // find the source object where the animation came from - LLViewerObject* source = gObjectList.findObject(sourceIterator->first); + LLViewerObject* source = gObjectList.findObject(source_id); // proceed if it's not an attachment if (source && !source->isAttachment()) { - LL_DEBUGS("AOEngine") << "Source " << sourceIterator->first << " is running animation " << sourceIterator->second << LL_ENDL; + LL_DEBUGS("AOEngine") << "Source " << source_id << " is running animation " << animation_id << LL_ENDL; // get the source's root prim LLViewerObject* sourceRoot = dynamic_cast(source->getRoot()); @@ -243,7 +242,7 @@ bool AOEngine::foreignAnimations() // if the root prim is the same as the animation source, report back as TRUE if (sourceRoot && sourceRoot->getID() == seat) { - LL_DEBUGS("AOEngine") << "foreign animation " << sourceIterator->second << " found on seat." << LL_ENDL; + LL_DEBUGS("AOEngine") << "foreign animation " << animation_id << " found on seat." << LL_ENDL; return true; } } @@ -1018,12 +1017,12 @@ bool AOEngine::createAnimationLink(const AOSet* set, AOSet::AOState* state, cons if (cats) { - for (S32 index = 0; index < cats->size(); ++index) + for (auto cat : *cats) { - if (cats->at(index)->getName().compare(state->mName) == 0) + if (cat->getName().compare(state->mName) == 0) { LL_DEBUGS("AOEngine") << "UUID found!" << LL_ENDL; - newStateFolderUUID = cats->at(index)->getUUID(); + newStateFolderUUID = cat->getUUID(); state->mInventoryUUID = newStateFolderUUID; break; } @@ -1195,8 +1194,7 @@ bool AOEngine::removeAnimation(const AOSet* set, AOSet::AOState* state, S32 inde // this item was not an animation link, move it to lost and found if (move) { - LLInventoryModel* model = &gInventory; - model->changeItemParent(item, gInventory.findCategoryUUIDForType(LLFolderType::FT_LOST_AND_FOUND), false); + gInventory.changeItemParent(item, gInventory.findCategoryUUIDForType(LLFolderType::FT_LOST_AND_FOUND), false); LLNotificationsUtil::add("AOForeignItemsFound", LLSD()); update(); return false; @@ -1209,7 +1207,7 @@ bool AOEngine::removeAnimation(const AOSet* set, AOSet::AOState* state, S32 inde state->mAnimations.erase(state->mAnimations.begin() + index); - if (state->mAnimations.size() == 0) + if (state->mAnimations.empty()) { LL_DEBUGS("AOEngine") << "purging folder " << state->mName << " from inventory because it's empty." << LL_ENDL; @@ -1219,12 +1217,18 @@ bool AOEngine::removeAnimation(const AOSet* set, AOSet::AOState* state, S32 inde if (cats) { - for (LLInventoryModel::cat_array_t::iterator it = cats->begin(); it != cats->end(); ++it) + for (auto cat : *cats) { - LLPointer cat = (*it); std::vector params; LLStringUtil::getTokens(cat->getName(), params, ":"); - std::string stateName = params[0]; + + if (params.empty()) + { + LL_WARNS("AOEngine") << "Unexpected folder found in ao set folder: " << cat->getName() << LL_ENDL; + return false; + } + + const std::string& stateName = params[0]; if (state->mName.compare(stateName) == 0) { @@ -1290,25 +1294,25 @@ void AOEngine::reloadStateAnimations(AOSet::AOState* state) if (items) { - for (S32 num = 0; num < items->size(); ++num) + for (auto item : *items) { - LL_DEBUGS("AOEngine") << "Found animation link " << items->at(num)->LLInventoryItem::getName() - << " desc " << items->at(num)->LLInventoryItem::getDescription() - << " asset " << items->at(num)->getAssetUUID() << LL_ENDL; + LL_DEBUGS("AOEngine") << "Found animation link " << item->LLInventoryItem::getName() + << " desc " << item->LLInventoryItem::getDescription() + << " asset " << item->getAssetUUID() << LL_ENDL; AOSet::AOAnimation anim; - anim.mAssetUUID = items->at(num)->getAssetUUID(); - LLViewerInventoryItem* linkedItem = items->at(num)->getLinkedItem(); + anim.mAssetUUID = item->getAssetUUID(); + LLViewerInventoryItem* linkedItem = item->getLinkedItem(); if (!linkedItem) { - LL_WARNS("AOEngine") << "linked item for link " << items->at(num)->LLInventoryItem::getName() << " not found (broken link). Skipping." << LL_ENDL; + LL_WARNS("AOEngine") << "linked item for link " << item->LLInventoryItem::getName() << " not found (broken link). Skipping." << LL_ENDL; continue; } anim.mName = linkedItem->LLInventoryItem::getName(); - anim.mInventoryUUID = items->at(num)->getUUID(); + anim.mInventoryUUID = item->getUUID(); S32 sortOrder; - if (!LLStringUtil::convertToS32(items->at(num)->LLInventoryItem::getDescription(), sortOrder)) + if (!LLStringUtil::convertToS32(item->LLInventoryItem::getDescription(), sortOrder)) { sortOrder = -1; } @@ -1370,9 +1374,8 @@ void AOEngine::update() if (categories) { - for (S32 index = 0; index < categories->size(); ++index) + for (auto currentCategory : *categories) { - LLViewerInventoryCategory* currentCategory = categories->at(index); const std::string& setFolderName = currentCategory->getName(); if (setFolderName.empty()) @@ -1383,6 +1386,11 @@ void AOEngine::update() std::vector params; LLStringUtil::getTokens(setFolderName, params, ":"); + if (params.empty()) + { + LL_WARNS("AOEngine") << "Unexpected folder found in ao set folder: " << currentCategory->getName() << LL_ENDL; + continue; + } AOSet* newSet = getSetByName(params[0]); if (!newSet) @@ -1440,11 +1448,16 @@ void AOEngine::update() gInventory.getDirectDescendentsOf(currentCategory->getUUID(), stateCategories, items); newSet->setComplete(true); - for (S32 state_index = 0; state_index < stateCategories->size(); ++state_index) + for (auto stateCategory : *stateCategories) { std::vector state_params; - LLStringUtil::getTokens(stateCategories->at(state_index)->getName(), state_params, ":"); - std::string stateName = state_params[0]; + LLStringUtil::getTokens(stateCategory->getName(), state_params, ":"); + if (params.empty()) + { + LL_WARNS("AOEngine") << "Unexpected state folder found in ao set: " << stateCategory->getName() << LL_ENDL; + continue; + } + const std::string& stateName = state_params[0]; AOSet::AOState* state = newSet->getStateByName(stateName); if (!state) @@ -1454,7 +1467,7 @@ void AOEngine::update() } LL_DEBUGS("AOEngine") << "Reading state " << stateName << LL_ENDL; - state->mInventoryUUID = stateCategories->at(state_index)->getUUID(); + state->mInventoryUUID = stateCategory->getUUID(); for (U32 num = 1; num < state_params.size(); ++num) { if (state_params[num] == "CY") @@ -1544,11 +1557,11 @@ void AOEngine::reload(bool aFromTimer) AOSet* AOEngine::getSetByName(const std::string& name) const { AOSet* found = nullptr; - for (U32 index = 0; index < mSets.size(); ++index) + for (auto set : mSets) { - if (mSets[index]->getName().compare(name) == 0) + if (set->getName().compare(name) == 0) { - found = mSets[index]; + found = set; break; } } @@ -1692,9 +1705,8 @@ void AOEngine::saveState(const AOSet::AOState* state) void AOEngine::saveSettings() { - for (U32 index = 0; index < mSets.size(); ++index) + for (auto set : mSets) { - AOSet* set = mSets[index]; if (set->getDirty()) { saveSet(set); @@ -1772,9 +1784,9 @@ void AOEngine::inMouselook(bool mouselook) void AOEngine::setDefaultSet(AOSet* set) { mDefaultSet = set; - for (U32 index = 0; index < mSets.size(); ++index) + for (auto set : mSets) { - mSets[index]->setDirty(true); + set->setDirty(true); } } @@ -1910,12 +1922,12 @@ void AOEngine::tick() gInventory.getDirectDescendentsOf(categoryID, categories, items); LL_DEBUGS("AOEngine") << "cat " << categories->size() << " items " << items->size() << LL_ENDL; - for (S32 index = 0; index < categories->size(); ++index) + for (auto cat : *categories) { - const std::string& catName = categories->at(index)->getName(); + const std::string& catName = cat->getName(); if (catName.compare(ROOT_AO_FOLDER) == 0) { - mAOFolder = categories->at(index)->getUUID(); + mAOFolder = cat->getUUID(); break; } } diff --git a/indra/newview/app_settings/key_bindings.xml b/indra/newview/app_settings/key_bindings.xml index 1d6ec5a01a..9a1e8e753b 100644 --- a/indra/newview/app_settings/key_bindings.xml +++ b/indra/newview/app_settings/key_bindings.xml @@ -85,7 +85,6 @@ - diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index ae8085b225..893429fe08 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -13986,7 +13986,7 @@ Change of this parameter will affect the layout of buttons in notification toast Type String Value - https://jira.firestormviewer.org/secure/CreateIssueDetails!init.jspa?pid=10005&issuetype=1&priority=3&environment=[ENVIRONMENT] + https://jira.firestormviewer.org/secure/CreateIssueDetails!init.jspa?pid=10003&issuetype=8&priority=3&environment=[ENVIRONMENT] RevokePermsOnStopAnimation @@ -14631,17 +14631,6 @@ Change of this parameter will affect the layout of buttons in notification toast Value 1 - BasicUITooltips - - Comment - Show tooltips for various 2D UI elements like buttons or checkboxes, won't supress tooltips like drag'n'drop, inworld, links or media - Persist - 1 - Type - Boolean - Value - 1 - ShowHoverTips Comment @@ -21998,6 +21987,17 @@ Change of this parameter will affect the layout of buttons in notification toast Value 3 + 360QualitySelection + + Comment + Quality level for the 360 snapshot + Persist + 1 + Type + U32 + Value + 128 + MFAHash Comment @@ -25541,6 +25541,28 @@ Change of this parameter will affect the layout of buttons in notification toast Value Scripting + FSNotecardFontName + + Comment + The name of the font used for the notecard editor + Persist + 1 + Type + String + Value + SansSerif + + FSNotecardFontSize + + Comment + The size of the font used for the notecard editor + Persist + 1 + Type + String + Value + Medium + FSEnableRightclickOnTransparentObjects Comment @@ -26014,5 +26036,16 @@ Change of this parameter will affect the layout of buttons in notification toast Value 473405 + FSUseCoRoFor360Capture + + Comment + Use co-routine to extract 360 photos. + Persist + 1 + Type + Boolean + Value + 0 + diff --git a/indra/newview/chatbar_as_cmdline.cpp b/indra/newview/chatbar_as_cmdline.cpp index 7181c9dddd..c2c57bc14d 100644 --- a/indra/newview/chatbar_as_cmdline.cpp +++ b/indra/newview/chatbar_as_cmdline.cpp @@ -72,9 +72,9 @@ std::string cmd_line_mPackagerTargetFolderName; LLUUID cmd_line_mPackagerTargetFolder; LLUUID cmd_line_mPackagerDest; -LLViewerInventoryItem::item_array_t findInventoryInFolder(const std::string& ifolder) +LLViewerInventoryItem::item_array_t findInventoryInFolder(std::string_view ifolder) { - LLUUID folder = gInventory.findCategoryByName(ifolder); + LLUUID folder = gInventory.findCategoryByName(static_cast(ifolder)); LLViewerInventoryCategory::cat_array_t cats; LLViewerInventoryItem::item_array_t items; gInventory.collectDescendents(folder, cats, items, FALSE); @@ -88,14 +88,15 @@ class JCZdrop : public LLEventTimer public: BOOL mRunning; - JCZdrop(std::stack stack, LLUUID dest, std::string sFolder, std::string sUUID, bool package = false) : LLEventTimer(1.f), mRunning(FALSE) - { - mPackage = package; - mStack = stack; - mDestination = dest; - mFolderName = sFolder; - mDropUUID = sUUID; - } + JCZdrop(std::stack stack, LLUUID dest, std::string_view sFolder, std::string_view sUUID, bool package = false) + : LLEventTimer(1.f), + mRunning(FALSE), + mPackage(package), + mStack(stack), + mDestination(dest), + mFolderName(sFolder), + mDropUUID(sUUID) + { } ~JCZdrop() { @@ -129,7 +130,7 @@ public: LLViewerObject* objectp = gObjectList.findObject(mDestination); if (objectp) { - report_to_nearby_chat(std::string("transferring ") + subj->getName()); + report_to_nearby_chat(std::string("Transferring ") + subj->getName()); LLToolDragAndDrop::dropInventory(objectp, subj, LLToolDragAndDrop::SOURCE_AGENT, gAgentID); if (mStack.size() > 0) { @@ -137,7 +138,7 @@ public: } else { - return (mStack.size() == 0); + return (mStack.empty()); } } else @@ -156,7 +157,7 @@ private: bool mPackage; }; -JCZdrop* zdrop; +JCZdrop* gZDrop{ nullptr }; class ZdCleanup: public LLEventTimer { @@ -168,7 +169,7 @@ public: BOOL tick() { - zdrop = NULL; + gZDrop = nullptr; return TRUE; } }; @@ -193,7 +194,7 @@ class JCZtake : public LLEventTimer public: BOOL mRunning; - JCZtake(const LLUUID& target, bool package = false, LLUUID destination = LLUUID::null, std::string dtarget = "", EDeRezDestination dest = DRD_TAKE_INTO_AGENT_INVENTORY, bool use_selection = true, std::vector to_take = std::vector()) : + JCZtake(const LLUUID& target, bool package = false, const LLUUID& destination = LLUUID::null, std::string_view dtarget = "", EDeRezDestination dest = DRD_TAKE_INTO_AGENT_INVENTORY, bool use_selection = true, std::vector to_take = std::vector()) : LLEventTimer(0.66f), mTarget(target), mRunning(FALSE), @@ -255,11 +256,14 @@ public: mToTake.push_back(localid); } } - if (mToTake.size() > 0) mState = ZTS_TAKE; + if (!mToTake.empty()) + { + mState = ZTS_TAKE; + } break; case ZTS_TAKE: - if (mToTake.size() > 0) + if (!mToTake.empty()) { std::vector > inventory = findInventoryInFolder(mFolderName); mPackSize = mToTake.size() + inventory.size(); @@ -285,7 +289,7 @@ public: if (mToTake.size() % 10 == 0) { - if (mToTake.size() == 0) + if (mToTake.empty()) { if (mPackage) { @@ -348,7 +352,8 @@ public: if (itemstack.size() >= mPackSize || mCountdown == 0) { - if (itemstack.size() < mPackSize) { + if (itemstack.size() < mPackSize) + { report_to_nearby_chat("Phase 1 of the packager finished, but some items mave have been missed."); } else @@ -358,8 +363,8 @@ public: report_to_nearby_chat("Do not have the destination prim selected while transfer is running to reduce the chances of \"Inventory creation on in-world object failed.\""); - LLUUID sdest = LLUUID(mPackageDest); - new JCZdrop(itemstack, sdest, mFolderName.c_str(), mPackageDest.asString().c_str(), true); + LLUUID sdest{ mPackageDest }; + gZDrop = new JCZdrop(itemstack, sdest, mFolderName.c_str(), mPackageDest.asString().c_str(), true); doZtCleanup(); mState = ZTS_DONE; @@ -388,7 +393,7 @@ private: EZtakeState mState; }; -JCZtake* ztake; +JCZtake* gZTake{ nullptr }; class LOZtCleanup: public LLEventTimer { @@ -400,9 +405,9 @@ public: BOOL tick() { - ztake->mRunning = TRUE; - delete ztake; - ztake = NULL; + gZTake->mRunning = TRUE; + delete gZTake; + gZTake = nullptr; return TRUE; } }; @@ -470,7 +475,7 @@ public: { report_to_nearby_chat(llformat("%i...", mCountdown--)); } - else if (mToTake.size() > 0) + else if (!mToTake.empty()) { msg->newMessageFast(_PREHASH_DeRezObject); msg->nextBlockFast(_PREHASH_AgentData); @@ -492,7 +497,7 @@ public: if (mToTake.size() % 10 == 0) { - if (mToTake.size() == 0) + if (mToTake.empty()) { report_to_nearby_chat("Mtake has taken all selected objects. Say \"mtake off\" to deactivate Mtake or select more objects to continue."); } @@ -515,7 +520,7 @@ private: S32 zeroClearY; S32 zeroClearZ; }; -TMZtake* mtake; +TMZtake* gMTake; void invrepair() { @@ -534,7 +539,7 @@ void key_to_name_callback(const LLUUID& id, const LLAvatarName& av_name) report_to_nearby_chat(llformat("%s: (%s)", id.asString().c_str(), name.c_str())); } -bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_gesture) +bool cmd_line_chat(std::string_view revised_text, EChatType type, bool from_gesture) { static LLCachedControl sFSCmdLine(gSavedSettings, "FSCmdLine"); static LLCachedControl sFSCmdLinePos(gSavedSettings, "FSCmdLinePos"); @@ -556,12 +561,11 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge static LLCachedControl sFSCmdLineMusic(gSavedSettings, "FSCmdLineMusic"); static LLCachedControl sFSCmdLineCopyCam(gSavedSettings, "FSCmdLineCopyCam"); static LLCachedControl sFSCmdLineRollDice(gSavedSettings, "FSCmdLineRollDice"); - // FIRE-6340, FIRE-6567 - Setting Bandwidth issues static LLCachedControl sFSCmdLineBandwidth(gSavedSettings, "FSCmdLineBandWidth"); if (sFSCmdLine) { - std::istringstream i(revised_text); + std::istringstream i(static_cast(revised_text)); std::string command; i >> command; if (!command.empty()) @@ -651,7 +655,6 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge return false; } } - // FIRE-6340, FIRE-6567 - Setting Bandwidth issues else if (command == sFSCmdLineBandwidth()) { S32 band_width; @@ -667,7 +670,6 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge return false; } } - // FIRE-6340, FIRE-6567 - Setting Bandwidth issues else if (command == sFSCmdLineAO()) { std::string status; @@ -936,7 +938,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge } else { - region_name = LLWeb::escapeURL(revised_text.substr(command.length() + 1)); + region_name = LLWeb::escapeURL(static_cast(revised_text.substr(command.length() + 1))); LLVector3d agentPos = gAgent.getPositionGlobal(); agent_x = ll_round((F32)agentPos.mdV[VX]); agent_y = ll_round((F32)agentPos.mdV[VY]); @@ -961,7 +963,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge F32 result = 0.f; if (revised_text.length() > command.length() + 1) { - std::string expr = revised_text.substr(command.length()+1); + std::string expr = static_cast(revised_text.substr(command.length() + 1)); LLStringUtil::toUpper(expr); std::string original_expr = expr; @@ -1024,7 +1026,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge { if (revised_text.length() > command.length() + 1) //Typing this command with no argument was causing a crash. -Madgeek { - std::string name = revised_text.substr(command.length() + 1); + std::string_view name = revised_text.substr(command.length() + 1); cmdline_tp2name(name); } return false; @@ -1047,7 +1049,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge { if (setting == "on") { - if (zdrop) + if (gZDrop) { report_to_nearby_chat("Zdrop is already active."); } @@ -1083,12 +1085,11 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge report_to_nearby_chat("Verifying folder location..."); std::stack inventorystack; std::vector > inventory = findInventoryInFolder(folder); - for (std::vector >::iterator it = inventory.begin(); it != inventory.end(); ++it) + for (const auto& item : inventory) { - LLViewerInventoryItem* item = *it; - inventorystack.push(item); + inventorystack.emplace(item); } - if (inventorystack.size()) + if (!inventorystack.empty()) { report_to_nearby_chat(llformat("Found folder \"%s\".", folder.c_str())); report_to_nearby_chat(llformat("Found prim \"%s\".", destination.c_str())); @@ -1097,7 +1098,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge report_to_nearby_chat("Do not have the prim selected while transfer is running to reduce the chances of \"Inventory creation on in-world object failed.\""); report_to_nearby_chat("Use \"zdrop off\" to stop the transfer"); LLUUID sdest = LLUUID(destination); - zdrop = new JCZdrop(inventorystack, sdest, folder.c_str(), destination.c_str()); + gZDrop = new JCZdrop(inventorystack, sdest, folder.c_str(), destination.c_str()); } } else @@ -1121,15 +1122,15 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge } else if (setting == "off") { - if (!zdrop) + if (!gZDrop) { report_to_nearby_chat("Zdrop is already deactivated."); } else { - zdrop ->mRunning = TRUE; - delete zdrop; - zdrop = NULL; + gZDrop->mRunning = TRUE; + delete gZDrop; + gZDrop = nullptr; } } else @@ -1151,7 +1152,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge { if (setting == "on") { - if (ztake) + if (gZTake) { report_to_nearby_chat("Ztake is already active."); } @@ -1172,7 +1173,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge if (folder.notNull()) { report_to_nearby_chat(llformat("Found destination folder \"%s\".", folder_name.c_str())); - ztake = new JCZtake(folder); + gZTake = new JCZtake(folder); } else { @@ -1188,15 +1189,15 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge } else if (setting == "off") { - if (!ztake) + if (!gZTake) { report_to_nearby_chat("Ztake is already deactivated."); } else { - ztake->mRunning = TRUE; - delete ztake; - ztake = NULL; + gZTake->mRunning = TRUE; + delete gZTake; + gZTake = nullptr; } } else @@ -1241,7 +1242,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge if (folder.notNull()) { report_to_nearby_chat(llformat("Found destination folder \"%s\".", folder_name.c_str())); - ztake = new JCZtake(folder, true, LLUUID(destination), folder_name, (command == "cpackage") ? DRD_ACQUIRE_TO_AGENT_INVENTORY : DRD_TAKE_INTO_AGENT_INVENTORY); + gZTake = new JCZtake(folder, true, LLUUID(destination), folder_name, (command == "cpackage") ? DRD_ACQUIRE_TO_AGENT_INVENTORY : DRD_TAKE_INTO_AGENT_INVENTORY); } else { @@ -1307,7 +1308,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge U32 localid = objectp->getLocalID(); if (std::find(to_take.begin(), to_take.end(), localid) == to_take.end()) { - to_take.push_back(localid); + to_take.emplace_back(localid); } } } @@ -1320,7 +1321,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge else { report_to_nearby_chat(llformat("Found destination folder \"%s\".", folder_name.c_str())); - ztake = new JCZtake(folder, true, LLUUID(destination), folder_name, DRD_ACQUIRE_TO_AGENT_INVENTORY, false, to_take); + gZTake = new JCZtake(folder, true, LLUUID(destination), folder_name, DRD_ACQUIRE_TO_AGENT_INVENTORY, false, to_take); } } else @@ -1438,7 +1439,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge U32 localid = objectp->getLocalID(); if (std::find(to_take.begin(), to_take.end(), localid) == to_take.end()) { - to_take.push_back(localid); + to_take.emplace_back(localid); } } } @@ -1451,7 +1452,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge else { report_to_nearby_chat(llformat("Found destination folder \"%s\".", folder_name.c_str())); - ztake = new JCZtake(folder, true, LLUUID::null, folder_name, (command == "kcopy") ? DRD_ACQUIRE_TO_AGENT_INVENTORY : DRD_TAKE_INTO_AGENT_INVENTORY, false, to_take); + gZTake = new JCZtake(folder, true, LLUUID::null, folder_name, (command == "kcopy") ? DRD_ACQUIRE_TO_AGENT_INVENTORY : DRD_TAKE_INTO_AGENT_INVENTORY, false, to_take); } } else @@ -1474,7 +1475,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge { if (setting == "on") { - if (mtake) + if (gMTake) { report_to_nearby_chat("Mtake is already active."); } @@ -1495,7 +1496,7 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge if (folder.notNull()) { report_to_nearby_chat(llformat("Found destination folder \"%s\".", folder_name.c_str())); - mtake = new TMZtake(folder); + gMTake = new TMZtake(folder); } else { @@ -1511,15 +1512,15 @@ bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_ge } else if (setting == "off") { - if (!mtake) + if (!gMTake) { report_to_nearby_chat("Mtake is already deactivated."); } else { - mtake->mRunning = TRUE; - delete mtake; - mtake = NULL; + gMTake->mRunning = TRUE; + delete gMTake; + gMTake = nullptr; } } else @@ -1729,29 +1730,25 @@ LLUUID cmdline_partial_name2key(std::string partial_name) LLStringUtil::toLower(partial_name); LLStringUtil::replaceString(partial_name, ".", " "); - FSRadar* radar = FSRadar::getInstance(); - if (radar) + FSRadar::entry_map_t radar_list = FSRadar::getInstance()->getRadarList(); + FSRadar::entry_map_t::iterator it_end = radar_list.end(); + for (const auto& [avid, entry] : radar_list) { - FSRadar::entry_map_t radar_list = radar->getRadarList(); - FSRadar::entry_map_t::iterator it_end = radar_list.end(); - for (FSRadar::entry_map_t::iterator it = radar_list.begin(); it != it_end; ++it) - { - FSRadarEntry* entry = it->second; - av_name = entry->getUserName(); + av_name = entry->getUserName(); - LLStringUtil::toLower(av_name); - if (strstr(av_name.c_str(), partial_name.c_str())) - { - return entry->getId(); - } + LLStringUtil::toLower(av_name); + if (strstr(av_name.c_str(), partial_name.c_str())) + { + return entry->getId(); } } + return LLUUID::null; } -void cmdline_tp2name(const std::string& target) +void cmdline_tp2name(std::string_view target) { - LLUUID avkey = cmdline_partial_name2key(target); + LLUUID avkey = cmdline_partial_name2key(static_cast(target)); if (avkey.notNull() && avkey != gAgentID) { LLAvatarActions::teleportTo(avkey); @@ -1822,17 +1819,17 @@ void cmdline_rezplat(bool use_saved_value, F32 visual_radius) //cmdline_rezplat( msg->sendReliable(gAgent.getRegionHost()); } -bool cmdline_packager(const std::string& message, const LLUUID& fromID, const LLUUID& ownerID) +bool cmdline_packager(std::string_view message, const LLUUID& fromID, const LLUUID& ownerID) { if (message.empty() || cmd_line_mPackagerDest.isNull() || fromID != cmd_line_mPackagerDest) { return false; } - std::string cmd = message.substr(0, 12); + std::string_view cmd = message.substr(0, 12); if (cmd == "kpackageradd") { - std::string csv = message.substr(13, -1); + std::string_view csv = message.substr(13, -1); std::string::size_type start = 0; std::string::size_type comma = 0; do @@ -1863,13 +1860,13 @@ bool cmdline_packager(const std::string& message, const LLUUID& fromID, const LL } while(comma < csv.length()); - report_to_nearby_chat(llformat("Packager: adding objects: \"%s\"", csv.c_str())); + report_to_nearby_chat(llformat("Packager: adding objects: \"%s\"", static_cast(csv).c_str())); return true; } else if (cmd == "kpackagerend") { report_to_nearby_chat("Packager: finalizing."); - ztake = new JCZtake(cmd_line_mPackagerTargetFolder, true, cmd_line_mPackagerDest, cmd_line_mPackagerTargetFolderName, DRD_ACQUIRE_TO_AGENT_INVENTORY, false, cmd_line_mPackagerToTake); + gZTake = new JCZtake(cmd_line_mPackagerTargetFolder, true, cmd_line_mPackagerDest, cmd_line_mPackagerTargetFolderName, DRD_ACQUIRE_TO_AGENT_INVENTORY, false, cmd_line_mPackagerToTake); cmd_line_mPackagerToTake.clear(); cmd_line_mPackagerTargetFolderName = ""; cmd_line_mPackagerTargetFolder.setNull(); diff --git a/indra/newview/chatbar_as_cmdline.h b/indra/newview/chatbar_as_cmdline.h index e233d77db9..b6ae8e4707 100644 --- a/indra/newview/chatbar_as_cmdline.h +++ b/indra/newview/chatbar_as_cmdline.h @@ -36,11 +36,11 @@ #include "llchat.h" -bool cmd_line_chat(const std::string& revised_text, EChatType type, bool from_gesture = false); +bool cmd_line_chat(std::string_view revised_text, EChatType type, bool from_gesture = false); void cmdline_rezplat(bool use_saved_value = true, F32 visual_radius = 30.f); -void cmdline_tp2name(const std::string& target); +void cmdline_tp2name(std::string_view target); LLUUID cmdline_partial_name2key(std::string name); -bool cmdline_packager(const std::string& message, const LLUUID& fromID, const LLUUID& ownerID); +bool cmdline_packager(std::string_view message, const LLUUID& fromID, const LLUUID& ownerID); #endif // CHATBAR_AS_CMDLINE_H diff --git a/indra/newview/fs_viewer_manifest.py b/indra/newview/fs_viewer_manifest.py index 316ebb2a5f..d6666d0fef 100644 --- a/indra/newview/fs_viewer_manifest.py +++ b/indra/newview/fs_viewer_manifest.py @@ -3,6 +3,17 @@ import subprocess import tarfile class FSViewerManifest: + def fs_installer_basename(self): + substitution_strings = { + 'version' : '.'.join(self.args['version']), + 'version_short' : '.'.join(self.args['version'][:-1]), + 'version_dashes' : '-'.join(self.args['version']), + 'app_name':self.app_name(), + 'app_name_oneword':self.app_name_oneword() + } + + return "Phoenix-%(app_name)s-%(version_dashes)s" % substitution_strings + def fs_is_opensim(self): return self.args['viewer_flavor'] == 'oss' #Havok would be hvk @@ -99,15 +110,13 @@ class FSViewerManifest: except: print("Cannot run pdbcopy, packaging private symbols") - # Store windows symbols we want to keep for debugging in a tar file, this will be later compressed with xz (lzma) - # Using tat+xz gives far superior compression than zip (~half the size of the zip archive). - # Python3 natively supports tar+xz via mode 'w:xz'. But we're stuck with Python2 for now. - symbolTar = tarfile.TarFile("%s/Phoenix_%s_%s_%s_pdbsymbols-windows-%d.tar" % (self.args['configuration'].lower(), - self.fs_channel_legacy_oneword(), - '-'.join(self.args['version']), - self.args['viewer_flavor'], - self.address_size), - 'w') + tarName = "%s/Phoenix_%s_%s_%s_pdbsymbols-windows-%d.tar.xz" % (self.args['configuration'].lower(), + self.fs_channel_legacy_oneword(), + '-'.join(self.args['version']), + self.args['viewer_flavor'], + self.address_size) + # Store windows symbols we want to keep for debugging in a tar file. + symbolTar = tarfile.open( name=tarName, mode="w:xz") symbolTar.add( "%s/Firestorm-bin.exe" % self.args['configuration'].lower(), "firestorm-bin.exe" ) symbolTar.add( "%s/build_data.json" % self.args['configuration'].lower(), "build_data.json" ) symbolTar.add( "%s/%s" % (self.args['configuration'].lower(),pdbName), pdbName ) diff --git a/indra/newview/fscommon.cpp b/indra/newview/fscommon.cpp index f000dd3040..d5bb19e095 100644 --- a/indra/newview/fscommon.cpp +++ b/indra/newview/fscommon.cpp @@ -67,7 +67,7 @@ extern S32 gMaxAgentGroups; S32 FSCommon::sObjectAddMsg = 0; -void report_to_nearby_chat(const std::string& message) +void report_to_nearby_chat(std::string_view message) { LLChat chat; chat.mText = message; @@ -81,16 +81,16 @@ std::string format_string(std::string text, const LLStringUtil::format_map_t& ar return text; } -bool is_irc_me_prefix(const std::string& text) +bool is_irc_me_prefix(std::string_view text) { - const std::string prefix = text.substr(0, 4); + const std::string_view prefix = text.substr(0, 4); return (prefix == "/me " || prefix == "/me'"); } -std::string unescape_name(const std::string& name) +std::string unescape_name(std::string_view name) { // bugfix for SL-46920: preventing filenames that break stuff. - char * curl_str = curl_unescape(name.c_str(), name.size()); + char * curl_str = curl_unescape(name.data(), name.size()); // Calling data() should be ok here because we also pass the length std::string unescaped_name(curl_str); curl_free(curl_str); curl_str = NULL; diff --git a/indra/newview/fscommon.h b/indra/newview/fscommon.h index a7d8d350d6..4653b1a402 100644 --- a/indra/newview/fscommon.h +++ b/indra/newview/fscommon.h @@ -37,10 +37,10 @@ class LLViewerParcelMgr; const F64 AVATAR_UNKNOWN_Z_OFFSET = -1.0; // Const value for avatars at unknown height const F32 AVATAR_UNKNOWN_RANGE = -1.f; -void report_to_nearby_chat(const std::string& message); +void report_to_nearby_chat(std::string_view message); std::string format_string(std::string text, const LLStringUtil::format_map_t& args); -bool is_irc_me_prefix(const std::string& text); -std::string unescape_name(const std::string& name); +bool is_irc_me_prefix(std::string_view text); +std::string unescape_name(std::string_view name); namespace FSCommon { diff --git a/indra/newview/fsfloaterpartialinventory.cpp b/indra/newview/fsfloaterpartialinventory.cpp new file mode 100644 index 0000000000..c88bcca5d4 --- /dev/null +++ b/indra/newview/fsfloaterpartialinventory.cpp @@ -0,0 +1,70 @@ +/** + * @file fsfloaterpartialinventory.cpp + * @brief Displays the inventory underneath a particular starting folder + * + * $LicenseInfo:firstyear=2022&license=viewerlgpl$ + * Phoenix Firestorm Viewer Source Code + * Copyright (c) 2022 Ansariel Hiller @ Second Life + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; + * version 2.1 of the License only. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + * + * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA + * $/LicenseInfo$ + */ + +#include "llviewerprecompiledheaders.h" + +#include "fsfloaterpartialinventory.h" +#include "llfiltereditor.h" +#include "llinventorypanel.h" + +//========================================================================= + +//========================================================================= +FSFloaterPartialInventory::FSFloaterPartialInventory(const LLSD& key) : LLFloater(key) +{ + mRootFolderId = key["start_folder_id"].asUUID(); +} + +FSFloaterPartialInventory::~FSFloaterPartialInventory() +{ +} + +BOOL FSFloaterPartialInventory::postBuild() +{ + LLInventoryPanel::Params params; + params.start_folder.id(mRootFolderId); + params.follows.flags(FOLLOWS_ALL); + params.layout("topleft"); + params.name("inv_panel"); + mInventoryList = LLUICtrlFactory::create(params); + + auto wrapper_panel = getChild("pnl_inv_wrap"); + wrapper_panel->addChild(mInventoryList); + mInventoryList->reshape(wrapper_panel->getRect().getWidth(), wrapper_panel->getRect().getHeight()); + mInventoryList->setOrigin(0, 0); + + mFilterEdit = getChild("flt_search"); + mFilterEdit->setCommitCallback([this](LLUICtrl*, const LLSD& param){ mInventoryList->setFilterSubString(param.asString()); }); + + return TRUE; +} + +void FSFloaterPartialInventory::onOpen(const LLSD& key) +{ + LLStringUtil::format_map_t args; + args["FOLDERNAME"] = key["start_folder_name"].asString(); + setTitle(getString("title", args)); +} diff --git a/indra/newview/fsfloaterpartialinventory.h b/indra/newview/fsfloaterpartialinventory.h new file mode 100644 index 0000000000..bc7c3255df --- /dev/null +++ b/indra/newview/fsfloaterpartialinventory.h @@ -0,0 +1,50 @@ +/** + * @file fsfloaterpartialinventory.h + * @brief Displays the inventory underneath a particular starting folder + * + * $LicenseInfo:firstyear=2022&license=viewerlgpl$ + * Phoenix Firestorm Viewer Source Code + * Copyright (c) 2022 Ansariel Hiller @ Second Life + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; + * version 2.1 of the License only. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + * + * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA + * $/LicenseInfo$ + */ + +#ifndef FS_FLOATERPARTIALINVENTORY_H +#define FS_FLOATERPARTIALINVENTORY_H + +#include "llfloater.h" + +class LLFilterEditor; +class LLInventoryPanel; + +class FSFloaterPartialInventory : public LLFloater +{ +public: + FSFloaterPartialInventory(const LLSD& key); + virtual ~FSFloaterPartialInventory(); + + BOOL postBuild() override; + void onOpen(const LLSD& key) override; + +private: + LLUUID mRootFolderId; + LLInventoryPanel* mInventoryList{ nullptr }; + LLFilterEditor* mFilterEdit{ nullptr }; +}; + +#endif diff --git a/indra/newview/fspanelblocklist.cpp b/indra/newview/fspanelblocklist.cpp index adc1c8cc73..cb45a75384 100644 --- a/indra/newview/fspanelblocklist.cpp +++ b/indra/newview/fspanelblocklist.cpp @@ -440,7 +440,7 @@ void FSPanelBlockList::showProfile() void FSPanelBlockList::callbackBlockPicked(const uuid_vec_t& ids, const std::vector names) { if (names.empty() || ids.empty()) return; - LLMute mute(ids[0], names[0].getLegacyName(), LLMute::AGENT); + LLMute mute(ids[0], names[0].getUserName(), LLMute::AGENT); LLMuteList::getInstance()->add(mute); showPanelAndSelect(mute.mID); } diff --git a/indra/newview/fsparticipantlist.cpp b/indra/newview/fsparticipantlist.cpp index e292d67a11..b14275e446 100644 --- a/indra/newview/fsparticipantlist.cpp +++ b/indra/newview/fsparticipantlist.cpp @@ -803,10 +803,12 @@ void FSParticipantList::FSParticipantListMenu::toggleMute(const LLSD& userdata, LL_WARNS("Speakers") << "Speaker " << speaker_id << " not found" << LL_ENDL; return; } - LLAvatarListItem* item = dynamic_cast(mParent.mAvatarList->getItemByValue(speaker_id)); - if (NULL == item) return; - name = item->getAvatarName(); + // We should have the name in the cache from the LLAvatarList this is used in combination with + LLAvatarName avname; + if (!LLAvatarNameCache::get(speaker_id, &avname)) return; + + name = avname.getUserName(); LLMute::EType mute_type; switch (speakerp->mType) diff --git a/indra/newview/fsperfstats.cpp b/indra/newview/fsperfstats.cpp index e53bdc19f2..9b283feb00 100644 --- a/indra/newview/fsperfstats.cpp +++ b/indra/newview/fsperfstats.cpp @@ -53,6 +53,8 @@ namespace FSPerfStats U32 lastGlobalPrefChange{0}; std::mutex bufferToggleLock{}; + F64 cpu_hertz{0.0}; + Tunables tunables; std::atomic StatsRecorder::writeBuffer{0}; @@ -136,6 +138,8 @@ namespace FSPerfStats // create a queue // create a thread to consume from the queue tunables.initialiseFromSettings(); + FSPerfStats::cpu_hertz = (F64)LLTrace::BlockTimer::countsPerSecond(); + t.detach(); } @@ -342,7 +346,7 @@ namespace FSPerfStats } // The frametime budget we have based on the target FPS selected - auto target_frame_time_raw = (U64)llround((F64)LLTrace::BlockTimer::countsPerSecond()/(tunables.userTargetFPS==0?1:tunables.userTargetFPS)); + auto target_frame_time_raw = (U64)llround(FSPerfStats::cpu_hertz/(tunables.userTargetFPS==0?1:tunables.userTargetFPS)); // LL_INFOS() << "Effective FPS(raw):" << tot_frame_time_raw << " Target:" << target_frame_time_raw << LL_ENDL; auto inferredFPS{1000/(U32)std::max(raw_to_ms(tot_frame_time_raw),1.0)}; U32 settingsChangeFrequency{inferredFPS > 25?inferredFPS:25}; diff --git a/indra/newview/fsperfstats.h b/indra/newview/fsperfstats.h index d690e0bcf2..2e610d08c0 100644 --- a/indra/newview/fsperfstats.h +++ b/indra/newview/fsperfstats.h @@ -76,6 +76,8 @@ namespace FSPerfStats static constexpr U32 TUNE_AVATARS_ONLY{0}; static constexpr U32 TUNE_SCENE_AND_AVATARS{1}; + extern F64 cpu_hertz; + extern std::atomic tunedAvatars; extern std::atomic renderAvatarMaxART_ns; extern bool belowTargetFPS; @@ -491,9 +493,9 @@ namespace FSPerfStats }; - inline double raw_to_ns(U64 raw) { return (static_cast(raw) * 1000000000.0) / (F64)LLTrace::BlockTimer::countsPerSecond(); }; - inline double raw_to_us(U64 raw) { return (static_cast(raw) * 1000000.0) / (F64)LLTrace::BlockTimer::countsPerSecond(); }; - inline double raw_to_ms(U64 raw) { return (static_cast(raw) * 1000.0) / (F64)LLTrace::BlockTimer::countsPerSecond(); }; + inline double raw_to_ns(U64 raw) { return (static_cast(raw) * 1000000000.0) / FSPerfStats::cpu_hertz; }; + inline double raw_to_us(U64 raw) { return (static_cast(raw) * 1000000.0) / FSPerfStats::cpu_hertz; }; + inline double raw_to_ms(U64 raw) { return (static_cast(raw) * 1000.0) / FSPerfStats::cpu_hertz; }; using RecordSceneTime = RecordTime; using RecordAvatarTime = RecordTime; diff --git a/indra/newview/lggcontactsets.cpp b/indra/newview/lggcontactsets.cpp index 4a1c76113f..f06f1b45a2 100644 --- a/indra/newview/lggcontactsets.cpp +++ b/indra/newview/lggcontactsets.cpp @@ -103,7 +103,7 @@ std::string LGGContactSets::getDefaultFilename() return path; } -LLSD LGGContactSets::exportContactSet(const std::string& set_name) +LLSD LGGContactSets::exportContactSet(std::string_view set_name) { LLSD ret; @@ -113,9 +113,9 @@ LLSD LGGContactSets::exportContactSet(const std::string& set_name) ret["groupname"] = set->mName; ret["color"] = set->mColor.getValue(); ret["notices"] = set->mNotify; - for (uuid_set_t::iterator friend_itr = set->mFriends.begin(); friend_itr != set->mFriends.end(); ++friend_itr) + for (const auto& friend_id : set->mFriends) { - ret["friends"][(*friend_itr).asString()] = ""; + ret["friends"][friend_id.asString()] = ""; } } @@ -176,12 +176,12 @@ void LGGContactSets::saveToDisk() file.close(); } -bool LGGContactSets::saveContactSetToDisk(const std::string& set_name, const std::string& filename) +bool LGGContactSets::saveContactSetToDisk(std::string_view set_name, std::string_view filename) { if (isValidSet(set_name)) { llofstream file; - file.open(filename.c_str()); + file.open(filename.data()); LLSDSerialize::toPrettyXML(exportContactSet(set_name), file); file.close(); return true; @@ -300,7 +300,7 @@ void LGGContactSets::importFromLLSD(const LLSD& data) } } -LLColor4 LGGContactSets::getSetColor(const std::string& set_name) +LLColor4 LGGContactSets::getSetColor(std::string_view set_name) { ContactSet* set = getContactSet(set_name); if (set) @@ -318,7 +318,7 @@ LLColor4 LGGContactSets::colorize(const LLUUID& uuid, const LLColor4& cur_color, bool rlv_shownames = !RlvActions::canShowName(RlvActions::SNC_DEFAULT, uuid); LLColor4 color = cur_color; - if (uuid == gAgent.getID()) + if (uuid == gAgentID) { switch (type) { @@ -338,7 +338,7 @@ LLColor4 LGGContactSets::colorize(const LLUUID& uuid, const LLColor4& cur_color, break; } } - else if (LLAvatarTracker::instance().getBuddyInfo(uuid) != NULL) + else if (LLAvatarTracker::instance().getBuddyInfo(uuid)) { switch (type) { @@ -452,7 +452,7 @@ LLColor4 LGGContactSets::colorize(const LLUUID& uuid, const LLColor4& cur_color, return color; } -LLColor4 LGGContactSets::getFriendColor(const LLUUID& friend_id, const std::string& ignored_set_name) +LLColor4 LGGContactSets::getFriendColor(const LLUUID& friend_id, std::string_view ignored_set_name) { LLColor4 color = getDefaultColor(); if (ignored_set_name == CS_SET_NO_SETS) @@ -462,9 +462,8 @@ LLColor4 LGGContactSets::getFriendColor(const LLUUID& friend_id, const std::stri U32 lowest = U32_MAX; string_vec_t contact_sets = getFriendSets(friend_id); - for (string_vec_t::iterator it = contact_sets.begin(); it != contact_sets.end(); ++it) + for (const auto& set_name : contact_sets) { - std::string set_name = *it; if (set_name != ignored_set_name) { U32 set_size = (U32)getFriendsInSet(set_name).size(); @@ -489,7 +488,7 @@ LLColor4 LGGContactSets::getFriendColor(const LLUUID& friend_id, const std::stri { if (isFriendInSet(friend_id, ignored_set_name) && !isInternalSetName(ignored_set_name)) { - return mContactSets[ignored_set_name]->mColor; + return mContactSets[ignored_set_name.data()]->mColor; } } return color; @@ -555,21 +554,20 @@ bool LGGContactSets::hasFriendColorThatShouldShow(const LLUUID& friend_id, ELGGC string_vec_t LGGContactSets::getFriendSets(const LLUUID& friend_id) { - string_vec_t sets; + string_vec_t sets{}; contact_set_map_t::iterator set_itr_end = mContactSets.end(); - for (contact_set_map_t::iterator itr = mContactSets.begin(); itr != set_itr_end; ++itr) + for (const auto& [set_name, set] : mContactSets) { - ContactSet* set = itr->second; if (set->hasFriend(friend_id)) { - sets.push_back(set->mName); + sets.emplace_back(set->mName); } } return sets; } -uuid_vec_t LGGContactSets::getFriendsInSet(const std::string& set_name) +uuid_vec_t LGGContactSets::getFriendsInSet(std::string_view set_name) { uuid_vec_t friends; @@ -593,9 +591,9 @@ uuid_vec_t LGGContactSets::getFriendsInSet(const std::string& set_name) ContactSet* set = getContactSet(set_name); if (set) { - for (uuid_set_t::iterator itr = set->mFriends.begin(); itr != set->mFriends.end(); ++itr) + for (const auto& id : set->mFriends) { - friends.push_back(*itr); + friends.emplace_back(id); } } @@ -604,11 +602,11 @@ uuid_vec_t LGGContactSets::getFriendsInSet(const std::string& set_name) string_vec_t LGGContactSets::getAllContactSets() { - string_vec_t sets; + string_vec_t sets{}; - for (contact_set_map_t::iterator itr = mContactSets.begin(); itr != mContactSets.end(); ++itr) + for (const auto& [set_name, set] : mContactSets) { - sets.push_back(itr->second->mName); + sets.push_back(set->mName); } return sets; @@ -616,11 +614,10 @@ string_vec_t LGGContactSets::getAllContactSets() uuid_vec_t LGGContactSets::getFriendsInAnySet() { - std::set friendsInAnySet; + uuid_set_t friendsInAnySet{}; - for (contact_set_map_t::iterator set_itr = mContactSets.begin(); set_itr != mContactSets.end(); ++set_itr) + for (const auto& [set_name, set] : mContactSets) { - ContactSet* set = set_itr->second; for (uuid_set_t::iterator itr = set->mFriends.begin(); itr != set->mFriends.end(); ++itr) { friendsInAnySet.insert(*itr); @@ -632,9 +629,8 @@ uuid_vec_t LGGContactSets::getFriendsInAnySet() bool LGGContactSets::isFriendInSet(const LLUUID& friend_id) { - for (contact_set_map_t::iterator itr = mContactSets.begin(); itr != mContactSets.end(); ++itr) + for (const auto& [set_name, set] : mContactSets) { - ContactSet* set = itr->second; if (set->hasFriend(friend_id)) { return true; @@ -644,7 +640,7 @@ bool LGGContactSets::isFriendInSet(const LLUUID& friend_id) return false; } -bool LGGContactSets::isFriendInSet(const LLUUID& friend_id, const std::string& set_name) +bool LGGContactSets::isFriendInSet(const LLUUID& friend_id, std::string_view set_name) { if (set_name == CS_SET_ALL_SETS) { @@ -678,9 +674,9 @@ bool LGGContactSets::isFriendInSet(const LLUUID& friend_id, const std::string& s bool LGGContactSets::notifyForFriend(const LLUUID& friend_id) { string_vec_t sets = getFriendSets(friend_id); - for (string_vec_t::const_iterator itr = sets.begin(); itr != sets.end(); ++itr) + for (const auto& set_name : sets) { - if (mContactSets[*itr]->mNotify) + if (mContactSets[set_name]->mNotify) { return true; } @@ -688,7 +684,7 @@ bool LGGContactSets::notifyForFriend(const LLUUID& friend_id) return false; } -void LGGContactSets::addToSet(const uuid_vec_t& avatar_ids, const std::string& set_name) +void LGGContactSets::addToSet(const uuid_vec_t& avatar_ids, std::string_view set_name) { LLAvatarTracker& tracker = LLAvatarTracker::instance(); @@ -701,7 +697,7 @@ void LGGContactSets::addToSet(const uuid_vec_t& avatar_ids, const std::string& s if (isValidSet(set_name)) { - mContactSets[set_name]->mFriends.insert(avatar_id); + mContactSets[set_name.data()]->mFriends.insert(avatar_id); } } @@ -734,9 +730,9 @@ void LGGContactSets::removeNonFriendFromList(const LLUUID& non_friend_id, bool s void LGGContactSets::removeFriendFromAllSets(const LLUUID& friend_id, bool save_changes /*= true*/) { string_vec_t sets = getFriendSets(friend_id); - for (string_vec_t::const_iterator itr = sets.begin(); itr != sets.end(); ++itr) + for (const auto& set_name : sets) { - removeFriendFromSet(friend_id, (*itr), save_changes); + removeFriendFromSet(friend_id, set_name, save_changes); } } @@ -753,13 +749,13 @@ bool LGGContactSets::isNonFriend(const LLUUID& non_friend_id) uuid_vec_t LGGContactSets::getListOfNonFriends() { LLAvatarTracker& tracker = LLAvatarTracker::instance(); - uuid_vec_t nonfriends; + uuid_vec_t nonfriends{}; for (const auto& friend_id : mExtraAvatars) { if (!tracker.isBuddy(friend_id)) { - nonfriends.push_back(friend_id); + nonfriends.emplace_back(friend_id); } } @@ -768,17 +764,17 @@ uuid_vec_t LGGContactSets::getListOfNonFriends() uuid_vec_t LGGContactSets::getListOfPseudonymAvs() { - uuid_vec_t pseudonyms; + uuid_vec_t pseudonyms{}; - for (uuid_map_t::iterator itr = mPseudonyms.begin(); itr != mPseudonyms.end(); ++itr) + for (const auto& [id, pseudonym] : mPseudonyms) { - pseudonyms.push_back(itr->first); + pseudonyms.emplace_back(pseudonym); } return pseudonyms; } -void LGGContactSets::setPseudonym(const LLUUID& friend_id, const std::string& pseudonym) +void LGGContactSets::setPseudonym(const LLUUID& friend_id, std::string_view pseudonym) { LLAvatarNameCache* inst = LLAvatarNameCache::getInstance(); mPseudonyms[friend_id] = pseudonym; @@ -863,9 +859,9 @@ bool LGGContactSets::hasPseudonym(const LLUUID& friend_id) bool LGGContactSets::hasPseudonym(uuid_vec_t ids) { bool has_pseudonym = false; - for (uuid_vec_t::const_iterator id = ids.begin(); id != ids.end(); ++id) + for (const auto& id : ids) { - if (hasPseudonym(*id)) + if (hasPseudonym(id)) { has_pseudonym = true; break; @@ -882,9 +878,9 @@ bool LGGContactSets::hasDisplayNameRemoved(const LLUUID& friend_id) bool LGGContactSets::hasDisplayNameRemoved(uuid_vec_t ids) { bool has_pseudonym = false; - for (uuid_vec_t::const_iterator id = ids.begin(); id != ids.end(); ++id) + for (const auto& id : ids) { - if (hasDisplayNameRemoved(*id)) + if (hasDisplayNameRemoved(id)) { has_pseudonym = true; break; @@ -903,7 +899,7 @@ void LGGContactSets::removeDisplayName(const LLUUID& friend_id) setPseudonym(friend_id, CS_PSEUDONYM); } -void LGGContactSets::removeFriendFromSet(const LLUUID& friend_id, const std::string& set_name, bool save_changes /*= true*/) +void LGGContactSets::removeFriendFromSet(const LLUUID& friend_id, std::string_view set_name, bool save_changes /*= true*/) { if (set_name == CS_SET_EXTRA_AVS) { @@ -926,12 +922,12 @@ void LGGContactSets::removeFriendFromSet(const LLUUID& friend_id, const std::str } } -bool LGGContactSets::isValidSet(const std::string& set_name) +bool LGGContactSets::isValidSet(std::string_view set_name) { - return (mContactSets.find(set_name) != mContactSets.end()); + return (mContactSets.find(set_name.data()) != mContactSets.end()); } -void LGGContactSets::addSet(const std::string& set_name) +void LGGContactSets::addSet(std::string_view set_name) { if (!isInternalSetName(set_name) && !isValidSet(set_name)) { @@ -939,21 +935,21 @@ void LGGContactSets::addSet(const std::string& set_name) set->mName = set_name; set->mColor = LLColor4::red; set->mNotify = false; - mContactSets[set_name] = set; + mContactSets[set_name.data()] = set; saveToDisk(); mChangedSignal(UPDATED_LISTS); } } -bool LGGContactSets::renameSet(const std::string& set_name, const std::string& new_set_name) +bool LGGContactSets::renameSet(std::string_view set_name, std::string_view new_set_name) { if (!isInternalSetName(set_name) && isValidSet(set_name) && !isInternalSetName(new_set_name) && !isValidSet(new_set_name)) { ContactSet* set = getContactSet(set_name); set->mName = new_set_name; - mContactSets.erase(set_name); - mContactSets[new_set_name] = set; + mContactSets.erase(set_name.data()); + mContactSets[new_set_name.data()] = set; saveToDisk(); mChangedSignal(UPDATED_LISTS); return true; @@ -961,27 +957,27 @@ bool LGGContactSets::renameSet(const std::string& set_name, const std::string& n return false; } -void LGGContactSets::removeSet(const std::string& set_name) +void LGGContactSets::removeSet(std::string_view set_name) { - contact_set_map_t::iterator found = mContactSets.find(set_name); + contact_set_map_t::iterator found = mContactSets.find(set_name.data()); if (found != mContactSets.end()) { LLAvatarTracker& tracker = LLAvatarTracker::instance(); uuid_vec_t non_friends_for_removal; ContactSet* cset = found->second; - for (uuid_set_t::iterator member_it = cset->mFriends.begin(); member_it != cset->mFriends.end(); ++member_it) + for (const auto& friend_id : cset->mFriends) { - if (!tracker.isBuddy(*member_it) && - getFriendSets(*member_it).size() == 1 && // Current set is only set! - !hasPseudonym(*member_it)) + if (!tracker.isBuddy(friend_id) && + getFriendSets(friend_id).size() == 1 && // Current set is only set! + !hasPseudonym(friend_id)) { - non_friends_for_removal.push_back(*member_it); + non_friends_for_removal.emplace_back(friend_id); } } - for (uuid_vec_t::iterator nf_it = non_friends_for_removal.begin(); nf_it != non_friends_for_removal.end(); ++nf_it) + for (const auto& non_friend_id : non_friends_for_removal) { - removeNonFriendFromList(*nf_it, false); + removeNonFriendFromList(non_friend_id, false); } delete found->second; @@ -991,7 +987,7 @@ void LGGContactSets::removeSet(const std::string& set_name) } } -void LGGContactSets::setNotifyForSet(const std::string& set_name, bool notify) +void LGGContactSets::setNotifyForSet(std::string_view set_name, bool notify) { ContactSet* set = getContactSet(set_name); if (set) @@ -1001,7 +997,7 @@ void LGGContactSets::setNotifyForSet(const std::string& set_name, bool notify) } } -bool LGGContactSets::getNotifyForSet(const std::string& set_name) +bool LGGContactSets::getNotifyForSet(std::string_view set_name) { ContactSet* set = getContactSet(set_name); if (set) @@ -1011,7 +1007,7 @@ bool LGGContactSets::getNotifyForSet(const std::string& set_name) return false; } -void LGGContactSets::setSetColor(const std::string& set_name, const LLColor4& color) +void LGGContactSets::setSetColor(std::string_view set_name, const LLColor4& color) { ContactSet* set = getContactSet(set_name); if (set) @@ -1021,7 +1017,7 @@ void LGGContactSets::setSetColor(const std::string& set_name, const LLColor4& co } } -bool LGGContactSets::isInternalSetName(const std::string& set_name) +bool LGGContactSets::isInternalSetName(std::string_view set_name) { return (set_name.empty() || set_name == CS_SET_EXTRA_AVS || @@ -1031,21 +1027,21 @@ bool LGGContactSets::isInternalSetName(const std::string& set_name) set_name == CS_GLOBAL_SETTINGS); } -LGGContactSets::ContactSet* LGGContactSets::getContactSet(const std::string& set_name) +LGGContactSets::ContactSet* LGGContactSets::getContactSet(std::string_view set_name) { if (set_name.empty()) { LL_WARNS("ContactSets") << "No contact set specified" << LL_ENDL; - return NULL; + return nullptr; } - contact_set_map_t::iterator found = mContactSets.find(set_name); + contact_set_map_t::iterator found = mContactSets.find(set_name.data()); if (found != mContactSets.end()) { return found->second; } LL_WARNS("ContactSets") << "No contact set named " << set_name << LL_ENDL; - return NULL; + return nullptr; } bool LGGContactSets::checkCustomName(const LLUUID& id, bool& dn_removed, std::string& pseudonym) @@ -1097,7 +1093,7 @@ bool LGGContactSets::handleRemoveAvatarFromSetCallback(const LLSD& notification, instance.removeFriendFromSet(id, set_name, false); if (!tracker.isBuddy(id) && - instance.getFriendSets(id).size() == 0 && + instance.getFriendSets(id).empty() && !instance.hasPseudonym(id)) { instance.removeNonFriendFromList(id, false); diff --git a/indra/newview/lggcontactsets.h b/indra/newview/lggcontactsets.h index 76d87cdc7a..c7607c4b57 100644 --- a/indra/newview/lggcontactsets.h +++ b/indra/newview/lggcontactsets.h @@ -55,9 +55,9 @@ public: void loadFromDisk(); - void setSetColor(const std::string& set_name, const LLColor4& color); - LLColor4 getSetColor(const std::string& set_name); - LLColor4 getFriendColor(const LLUUID& friend_id, const std::string& ignored_set_name = ""); + void setSetColor(std::string_view set_name, const LLColor4& color); + LLColor4 getSetColor(std::string_view set_name); + LLColor4 getFriendColor(const LLUUID& friend_id, std::string_view ignored_set_name = ""); LLColor4 colorize(const LLUUID& uuid, const LLColor4& cur_color, ELGGCSType type); void setDefaultColor(const LLColor4& default_color) { mDefaultColor = default_color; }; @@ -77,17 +77,17 @@ public: string_vec_t getFriendSets(const LLUUID& friend_id); string_vec_t getAllContactSets(); - void addToSet(const uuid_vec_t&, const std::string& set_name); - void removeFriendFromSet(const LLUUID& friend_id, const std::string& set_name, bool save_changes = true); + void addToSet(const uuid_vec_t&, std::string_view set_name); + void removeFriendFromSet(const LLUUID& friend_id, std::string_view set_name, bool save_changes = true); void removeFriendFromAllSets(const LLUUID& friend_id, bool save_changes = true); - bool isFriendInSet(const LLUUID& friend_id, const std::string& set_name); + bool isFriendInSet(const LLUUID& friend_id, std::string_view set_name); bool hasFriendColorThatShouldShow(const LLUUID& friend_id, ELGGCSType type); bool hasFriendColorThatShouldShow(const LLUUID& friend_id, ELGGCSType type, LLColor4& color); - void addSet(const std::string& set_name); - bool renameSet(const std::string& set_name, const std::string& new_set_name); - void removeSet(const std::string& set_name); - bool isValidSet(const std::string& set_name); + void addSet(std::string_view set_name); + bool renameSet(std::string_view set_name, std::string_view new_set_name); + void removeSet(std::string_view set_name); + bool isValidSet(std::string_view set_name); void removeNonFriendFromList(const LLUUID& non_friend_id, bool save_changes = true); bool isNonFriend(const LLUUID& non_friend_id); @@ -96,12 +96,12 @@ public: uuid_vec_t getListOfPseudonymAvs(); bool notifyForFriend(const LLUUID& friend_id); - void setNotifyForSet(const std::string& set_name, bool notify); - bool getNotifyForSet(const std::string& set_name); + void setNotifyForSet(std::string_view set_name, bool notify); + bool getNotifyForSet(std::string_view set_name); bool callbackAliasReset(const LLSD& notification, const LLSD& response); - bool isInternalSetName(const std::string& set_name); + bool isInternalSetName(std::string_view set_name); bool hasSets() { return !mContactSets.empty(); } class ContactSet @@ -117,7 +117,7 @@ public: bool mNotify; LLColor4 mColor; }; - ContactSet* getContactSet(const std::string& set_name); + ContactSet* getContactSet(std::string_view set_name); // [FS:CR] Signals for updating the various UI typedef enum e_contact_set_update { @@ -140,14 +140,14 @@ public: private: void toneDownColor(LLColor4& color) const; - uuid_vec_t getFriendsInSet(const std::string& set_name); + uuid_vec_t getFriendsInSet(std::string_view set_name); uuid_vec_t getFriendsInAnySet(); - void setPseudonym(const LLUUID& friend_id, const std::string& pseudonym); + void setPseudonym(const LLUUID& friend_id, std::string_view pseudonym); bool hasVisuallyDifferentPseudonym(const LLUUID& friend_id); - LLSD exportContactSet(const std::string& set_name); - bool saveContactSetToDisk(const std::string& set_name, const std::string& filename); + LLSD exportContactSet(std::string_view set_name); + bool saveContactSetToDisk(std::string_view set_name, std::string_view filename); std::string getFilename(); std::string getDefaultFilename(); diff --git a/indra/newview/linux_tools/launch_url.sh b/indra/newview/linux_tools/launch_url.sh index 404ea36f26..3e90a942ed 100755 --- a/indra/newview/linux_tools/launch_url.sh +++ b/indra/newview/linux_tools/launch_url.sh @@ -45,7 +45,7 @@ if [ ! -z "$XBROWSER" ]; then echo "$0: Trying some others..." fi -# Launcher the default GNOME browser. +# Launch the default GNOME browser. if [ ! -z "$GNOME_DESKTOP_SESSION_ID" ] && which gnome-open >/dev/null; then gnome-open "$URL" & exit @@ -60,6 +60,7 @@ fi # List of browser commands that will be tried in the order listed. x-www-browser # will be tried first, which is a debian alternative. BROWSER_COMMANDS=" \ + xdg-open \ x-www-browser \ firefox \ mozilla-firefox \ diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp index b95e9f0f1a..757af5540b 100644 --- a/indra/newview/llagent.cpp +++ b/indra/newview/llagent.cpp @@ -832,6 +832,9 @@ void LLAgent::moveYaw(F32 mag, bool reset_view) U32 mask = AGENT_CONTROL_YAW_POS | AGENT_CONTROL_YAW_NEG; if ((getControlFlags() & mask) == mask) { + // Rotation into both directions should cancel out + // But keep sending controls to simulator, + // it's needed for script based controls gAgentCamera.setYawKey(0); } diff --git a/indra/newview/llappearancemgr.h b/indra/newview/llappearancemgr.h index 75e3275a91..c445b6f06d 100644 --- a/indra/newview/llappearancemgr.h +++ b/indra/newview/llappearancemgr.h @@ -305,7 +305,7 @@ private: LLUUID mCOFImageID; - std::auto_ptr mUnlockOutfitTimer; + std::unique_ptr mUnlockOutfitTimer; // Set of temp attachment UUIDs that should be removed typedef std::set doomed_temp_attachments_t; diff --git a/indra/newview/llface.cpp b/indra/newview/llface.cpp index 7b37ec09b8..fc5bd7f180 100644 --- a/indra/newview/llface.cpp +++ b/indra/newview/llface.cpp @@ -1232,11 +1232,6 @@ bool LLFace::canRenderAsMask() { return false; } - - // shortcircuit fully alpha faces - if (getViewerObject()->isHUDAttachment()) { return false; } - if (te->getAlpha() == 0.0f && (te->getGlow() == 0.f)) { return true; } - // LLMaterial* mat = te->getMaterialParams(); if (mat && mat->getDiffuseAlphaMode() == LLMaterial::DIFFUSE_ALPHA_MODE_BLEND) diff --git a/indra/newview/llfavoritesbar.cpp b/indra/newview/llfavoritesbar.cpp index c843fd0f7c..028689fb00 100644 --- a/indra/newview/llfavoritesbar.cpp +++ b/indra/newview/llfavoritesbar.cpp @@ -1002,7 +1002,7 @@ void LLFavoritesBarCtrl::updateButtons(bool force_update) { //find last visible child to get the rightest button offset child_list_const_reverse_iter_t last_visible_it = std::find_if(childs->rbegin(), childs->rend(), - std::mem_fun(&LLView::getVisible)); + [](child_list_t::value_type child){ return child->getVisible(); }); if(last_visible_it != childs->rend()) { last_right_edge = (*last_visible_it)->getRect().mRight; diff --git a/indra/newview/llfloater360capture.cpp b/indra/newview/llfloater360capture.cpp index 6eec980da8..610746ca80 100644 --- a/indra/newview/llfloater360capture.cpp +++ b/indra/newview/llfloater360capture.cpp @@ -112,7 +112,8 @@ BOOL LLFloater360Capture::postBuild() // UX/UI called for preview mode (always the first index/option) // by default each time vs restoring the last value - mQualityRadioGroup->setSelectedIndex(0); + // UX/UI has no clue what the users actually want! + //mQualityRadioGroup->setSelectedIndex(0); // Construct a URL pointing to the first page to load. Although // we do not use this page for anything (after some significant @@ -319,6 +320,11 @@ const std::string LLFloater360Capture::getHTMLBaseFolder() // triggered when the 'capture' button in the UI is pressed void LLFloater360Capture::onCapture360ImagesBtn() { + // FIRE-31942 Avoid CoRo that appears to never usefully yield + // Allow option to re-enable on the off chance a low power machine can benefit + if(gSavedSettings.getBOOL("FSUseCoRoFor360Capture")) + { + // // launch the main capture code in a coroutine so we can // yield/suspend at some points to give the main UI // thread a look-in occasionally. @@ -326,6 +332,13 @@ void LLFloater360Capture::onCapture360ImagesBtn() { capture360Images(); }); + // FIRE-31942 Avoid CoRo that appears to never usefully yield + } + else + { + capture360Images(); + } + // } // Gets the full path name for a given JavaScript file in the HTML folder. We @@ -682,6 +695,7 @@ void LLFloater360Capture::capture360Images() // allow the UI to update by suspending and waiting for the // main render loop to update the UI + if(gSavedSettings.getBOOL("FSUseCoRoFor360Capture")) // FIRE-31942 - make apparently pointless CoRo optional (just in case) suspendForAFrame(); } @@ -892,7 +906,7 @@ const std::string LLFloater360Capture::generate_proposed_filename() // this looks complex but it's straightforward - removes all non-alpha chars from a string // which in this case is the SL region name - we use it as a proposed filename but the user is free to change std::string region_name = region->getName(); - std::replace_if(region_name.begin(), region_name.end(), std::not1(std::ptr_fun(isalnum)), '_'); + std::replace_if(region_name.begin(), region_name.end(), [](const auto& c) { return isalnum(c) == 0; }, '_'); if (region_name.length() > 0) { filename << region_name; diff --git a/indra/newview/llfloaterregioninfo.cpp b/indra/newview/llfloaterregioninfo.cpp index 1061bdb6ec..5405662e84 100644 --- a/indra/newview/llfloaterregioninfo.cpp +++ b/indra/newview/llfloaterregioninfo.cpp @@ -571,9 +571,9 @@ void LLFloaterRegionInfo::processRegionInfo(LLMessageSystem* msg) } msg->getU32Fast(_PREHASH_RegionInfo, _PREHASH_EstateID, estate_id); - panel->getChild("estate_id")->setValue(LLSD((F32) estate_id)); - panel->getChild("grid_position_x")->setValue(LLSD((F32) grid_pos_x)); - panel->getChild("grid_position_y")->setValue(LLSD((F32) grid_pos_y)); + panel->getChild("estate_id")->setValue(LLSD::Integer(estate_id)); + panel->getChild("grid_position_x")->setValue(LLSD::Integer(grid_pos_x)); + panel->getChild("grid_position_y")->setValue(LLSD::Integer(grid_pos_y)); // // DEBUG PANEL @@ -719,9 +719,7 @@ void LLFloaterRegionInfo::refreshFromRegion(LLViewerRegion* region) std::for_each( mInfoPanels.begin(), mInfoPanels.end(), - llbind2nd( - std::mem_fun(&LLPanelRegionInfo::refreshFromRegion), - region)); + [region](info_panels_t::value_type panel) { panel->refreshFromRegion(region); }); mEnvironmentPanel->refreshFromRegion(region); } diff --git a/indra/newview/llfloatertools.cpp b/indra/newview/llfloatertools.cpp index 701cfc4f16..6b7dab5931 100644 --- a/indra/newview/llfloatertools.cpp +++ b/indra/newview/llfloatertools.cpp @@ -659,14 +659,33 @@ void LLFloaterTools::refresh() LLViewerObject* selected_object = mObjectSelection->getFirstObject(); if (selected_object) { - // Select a parcel at the currently selected object's position. - LLViewerParcelMgr::getInstance()->selectParcelAt(selected_object->getPositionGlobal()); + // FIRE-20387: Editing HUD attachment shows [CAPACITY_STRING] in tools floater + //LLViewerParcelMgr::getInstance()->selectParcelAt(selected_object->getPositionGlobal()); + if (!selected_object->isAttachment()) + { + LLViewerParcelMgr::getInstance()->selectParcelAt(selected_object->getPositionGlobal()); + } + else + { + const LLStringExplicit empty_str(""); + childSetTextArg("more info label", "[CAPACITY_STRING]", empty_str); + } + // } else { LL_WARNS() << "Failed to get selected object" << LL_ENDL; } } + // Bring back remaining capacity info + else + { + // Selection crosses parcel bounds. + // We don't display remaining land capacity in this case. + const LLStringExplicit empty_str(""); + childSetTextArg("more info label", "[CAPACITY_STRING]", empty_str); + } + // // We got this already //if (object_count == 1) @@ -1071,8 +1090,9 @@ void LLFloaterTools::updatePopup(LLCoordGL center, MASK mask) // getChildView("more info label")->setVisible(!land_visible && have_selection); getChildView("selection_count")->setVisible(!land_visible && have_selection); - getChildView("selection_faces")->setVisible(LLToolFace::getInstance() == LLToolMgr::getInstance()->getCurrentTool() - && LLSelectMgr::getInstance()->getSelection()->getObjectCount() == 1); + // We got this already + //getChildView("selection_faces")->setVisible(LLToolFace::getInstance() == LLToolMgr::getInstance()->getCurrentTool() + // && LLSelectMgr::getInstance()->getSelection()->getObjectCount() == 1); getChildView("selection_empty")->setVisible(!land_visible && !have_selection); //mTab->setVisible(!land_visible); @@ -1485,6 +1505,27 @@ void LLFloaterTools::updateLandImpacts() return; } + // Bring back remaining capacity info + S32 rezzed_prims = parcel->getSimWidePrimCount(); + S32 total_capacity = parcel->getSimWideMaxPrimCapacity(); + LLViewerRegion* region = LLViewerParcelMgr::getInstance()->getSelectionRegion(); + if (region) + { + S32 max_tasks_per_region = (S32)region->getMaxTasks(); + total_capacity = llmin(total_capacity, max_tasks_per_region); + } + std::string remaining_capacity_str = ""; + + if (gMeshRepo.meshRezEnabled()) + { + LLStringUtil::format_map_t remaining_capacity_args; + remaining_capacity_args["LAND_CAPACITY"] = llformat("%d", total_capacity - rezzed_prims); + remaining_capacity_str = getString("status_remaining_capacity", remaining_capacity_args); + } + + childSetTextArg("more info label", "[CAPACITY_STRING]", remaining_capacity_str); + // + // Update land impacts info in the weights floater LLFloaterObjectWeights* object_weights_floater = LLFloaterReg::findTypedInstance("object_weights"); if(object_weights_floater) diff --git a/indra/newview/llgesturemgr.cpp b/indra/newview/llgesturemgr.cpp index c03821490d..ef6d91efe6 100644 --- a/indra/newview/llgesturemgr.cpp +++ b/indra/newview/llgesturemgr.cpp @@ -773,7 +773,7 @@ S32 LLGestureMgr::getPlayingCount() const } -struct IsGesturePlaying : public std::unary_function +struct IsGesturePlaying { bool operator()(const LLMultiGesture* gesture) const { diff --git a/indra/newview/llhudtext.cpp b/indra/newview/llhudtext.cpp index c62f36cc27..19ed1e07d7 100644 --- a/indra/newview/llhudtext.cpp +++ b/indra/newview/llhudtext.cpp @@ -371,7 +371,7 @@ void LLHUDText::updateVisibility() if (!mSourceObject) { - LL_WARNS() << "HUD text: mSourceObject is NULL, mOnHUDAttachment: " << mOnHUDAttachment << LL_ENDL; + LL_WARNS_ONCE() << "HUD text: mSourceObject is NULL, mOnHUDAttachment: " << mOnHUDAttachment << LL_ENDL; mVisible = TRUE; if (mOnHUDAttachment) { diff --git a/indra/newview/llinspectavatar.cpp b/indra/newview/llinspectavatar.cpp index 6401d8586e..6e14862044 100644 --- a/indra/newview/llinspectavatar.cpp +++ b/indra/newview/llinspectavatar.cpp @@ -737,7 +737,7 @@ void LLInspectAvatar::onClickShare() void LLInspectAvatar::onToggleMute() { - LLMute mute(mAvatarID, mAvatarName.getDisplayName(), LLMute::AGENT); + LLMute mute(mAvatarID, mAvatarName.getUserName(), LLMute::AGENT); if (LLMuteList::getInstance()->isMuted(mute.mID, mute.mName)) { diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp index f2f6ffe6f7..11f5c8a015 100644 --- a/indra/newview/llinventorybridge.cpp +++ b/indra/newview/llinventorybridge.cpp @@ -3732,6 +3732,12 @@ void LLFolderBridge::performAction(LLInventoryModel* model, std::string action) gSavedPerAccountSettings.setLLSD("FSProtectedFolders", new_protected_folders); } // + // Show folder in new window option + else if ("show_in_new_window" == action) + { + LLFloaterReg::showInstance("fs_partial_inventory", LLSD().with("start_folder_id", mUUID).with("start_folder_name", mDisplayName)); + } + // } void LLFolderBridge::gatherMessage(std::string& message, S32 depth, LLError::ELevel log_level) @@ -4674,6 +4680,9 @@ void LLFolderBridge::buildContextMenuOptions(U32 flags, menuentry_vec_t& items } // + // Show folder in new window option + items.push_back((std::string("Show in new Window"))); + // Add menu items that are dependent on the contents of the folder. LLViewerInventoryCategory* category = (LLViewerInventoryCategory *) model->getCategory(mUUID); if (category && (marketplace_listings_id != mUUID)) diff --git a/indra/newview/llinventoryfunctions.cpp b/indra/newview/llinventoryfunctions.cpp index c0577920be..4f2fbedc15 100644 --- a/indra/newview/llinventoryfunctions.cpp +++ b/indra/newview/llinventoryfunctions.cpp @@ -2653,7 +2653,38 @@ void LLInventoryAction::doToSelected(LLInventoryModel* model, LLFolderView* root // LLSD args; - args["QUESTION"] = LLTrans::getString(root->getSelectedCount() > 1 ? "DeleteItems" : "DeleteItem"); + // FIRE-31816: Include selection count when deleting more than one object from inventory + //args["QUESTION"] = LLTrans::getString(root->getSelectedCount() > 1 ? "DeleteItems" : "DeleteItem"); + //args["QUESTION"] = LLTrans::getString(root->getSelectedCount() > 1 ? "DeleteItems" : "DeleteItem", args); + LLLocale locale(""); + std::string count_str{}; + S32 selection_count = root->getSelectedCount(); + S32 total_count{ 0 }; + + for (const auto item : root->getSelectedItems()) + { + total_count++; + + LLFolderViewModelItemInventory * view_model = dynamic_cast(item->getViewModelItem()); + if (view_model) + { + auto cat = model->getCategory(view_model->getUUID()); + if (cat) + { + LLInventoryModel::cat_array_t cats; + LLInventoryModel::item_array_t items; + model->collectDescendents(cat->getUUID(), cats, items, TRUE); + total_count += (S32)(cats.size() + items.size()); + } + } + } + + LLResMgr::instance().getIntegerString(count_str, selection_count); + args["COUNT_SELECTION"] = count_str; + LLResMgr::instance().getIntegerString(count_str, total_count); + args["COUNT_TOTAL"] = count_str; + args["QUESTION"] = LLTrans::getString(selection_count > 1 ? "DeleteItems" : "DeleteItem", args); + // LLNotificationsUtil::add("DeleteItems", args, LLSD(), boost::bind(&LLInventoryAction::onItemsRemovalConfirmation, _1, _2, root->getHandle())); } // Note: marketplace listings will be updated in the callback if delete confirmed diff --git a/indra/newview/llnetmap.cpp b/indra/newview/llnetmap.cpp index 67cc1efd6b..e92476f465 100644 --- a/indra/newview/llnetmap.cpp +++ b/indra/newview/llnetmap.cpp @@ -1862,9 +1862,9 @@ void LLNetMap::setAvatarMarkColors(const uuid_vec_t& avatar_ids, const LLSD& col // Use the name as color definition name from colors.xml LLColor4 mark_color = LLUIColorTable::instance().getColor(color.asString(), LLColor4::green); - for (uuid_vec_t::const_iterator it = avatar_ids.begin(); it != avatar_ids.end(); ++it) + for (const auto& avatar_id : avatar_ids) { - sAvatarMarksMap[*it] = mark_color; + sAvatarMarksMap[avatar_id] = mark_color; } } @@ -1879,13 +1879,9 @@ void LLNetMap::clearAvatarMarkColor(const LLUUID& avatar_id) // static void LLNetMap::clearAvatarMarkColors(const uuid_vec_t& avatar_ids) { - for (uuid_vec_t::const_iterator it = avatar_ids.begin(); it != avatar_ids.end(); ++it) + for (const auto& avatar_id : avatar_ids) { - avatar_marks_map_t::iterator found = sAvatarMarksMap.find(*it); - if (found != sAvatarMarksMap.end()) - { - sAvatarMarksMap.erase(found); - } + sAvatarMarksMap.erase(avatar_id); } } @@ -1907,10 +1903,7 @@ LLColor4 LLNetMap::getAvatarColor(const LLUUID& avatar_id) color = cs_instance.colorize(avatar_id, color, LGG_CS_MINIMAP); // Color based on contact sets prefs - if (cs_instance.hasFriendColorThatShouldShow(avatar_id, LGG_CS_MINIMAP)) - { - color = cs_instance.getFriendColor(avatar_id); - } + cs_instance.hasFriendColorThatShouldShow(avatar_id, LGG_CS_MINIMAP, color); // Mark Avatars with special colors avatar_marks_map_t::iterator found = sAvatarMarksMap.find(avatar_id); diff --git a/indra/newview/llpaneleditwearable.cpp b/indra/newview/llpaneleditwearable.cpp index e54d35b203..fe63d3b229 100644 --- a/indra/newview/llpaneleditwearable.cpp +++ b/indra/newview/llpaneleditwearable.cpp @@ -1439,7 +1439,7 @@ void LLPanelEditWearable::changeCamera(U8 subpart) gMorphView->setCameraOffset( subpart_entry->mCameraOffset ); if (gSavedSettings.getBOOL("AppearanceCameraMovement")) { - gAgentCamera.setFocusOnAvatar(FALSE, FALSE); + // gAgentCamera.setFocusOnAvatar(FALSE, FALSE); FIRE-31959 Restore proper turning behaviour. gMorphView->updateCamera(); } } diff --git a/indra/newview/llpreviewnotecard.cpp b/indra/newview/llpreviewnotecard.cpp index e6eedd76bf..280611329b 100644 --- a/indra/newview/llpreviewnotecard.cpp +++ b/indra/newview/llpreviewnotecard.cpp @@ -76,6 +76,10 @@ LLPreviewNotecard::LLPreviewNotecard(const LLSD& key) //const LLUUID& item_id, // FIRE-24306: Retain cursor position when saving notecards ,mCursorPos(0) ,mScrollPos(0) + // FIRE-29425: User-selectable font and size for notecards + ,mFontNameChangedCallbackConnection() + ,mFontSizeChangedCallbackConnection() + // { const LLInventoryItem *item = getItem(); if (item) @@ -87,6 +91,17 @@ LLPreviewNotecard::LLPreviewNotecard(const LLSD& key) //const LLUUID& item_id, LLPreviewNotecard::~LLPreviewNotecard() { delete mLiveFile; + + // FIRE-29425: User-selectable font and size for notecards + if (mFontNameChangedCallbackConnection.connected()) + { + mFontNameChangedCallbackConnection.disconnect(); + } + if (mFontSizeChangedCallbackConnection.connected()) + { + mFontSizeChangedCallbackConnection.disconnect(); + } + // } BOOL LLPreviewNotecard::postBuild() @@ -118,6 +133,12 @@ BOOL LLPreviewNotecard::postBuild() } getChild("desc")->setPrevalidate(&LLTextValidate::validateASCIIPrintableNoPipe); + // FIRE-29425: User-selectable font and size for notecards + mFontNameChangedCallbackConnection = gSavedSettings.getControl("FSNotecardFontName")->getSignal()->connect(boost::bind(&LLPreviewNotecard::onFontChanged, this)); + mFontSizeChangedCallbackConnection = gSavedSettings.getControl("FSNotecardFontSize")->getSignal()->connect(boost::bind(&LLPreviewNotecard::onFontChanged, this)); + onFontChanged(); + // + return LLPreview::postBuild(); } @@ -983,5 +1004,15 @@ void LLPreviewNotecard::checkCloseAfterSave() } // +// FIRE-29425: User-selectable font and size for notecards +void LLPreviewNotecard::onFontChanged() +{ + LLFontGL* font = LLFontGL::getFont(LLFontDescriptor(gSavedSettings.getString("FSNotecardFontName"), gSavedSettings.getString("FSNotecardFontSize"), LLFontGL::NORMAL)); + if (font) + { + mEditor->setFont(font); + } +} +// // EOF diff --git a/indra/newview/llpreviewnotecard.h b/indra/newview/llpreviewnotecard.h index 69d949da7c..09a61ea45f 100644 --- a/indra/newview/llpreviewnotecard.h +++ b/indra/newview/llpreviewnotecard.h @@ -129,6 +129,12 @@ protected: bool writeToFile(const std::string& filename); std::string getTmpFileName(); + // FIRE-29425: User-selectable font and size for notecards + boost::signals2::connection mFontNameChangedCallbackConnection; + boost::signals2::connection mFontSizeChangedCallbackConnection; + void onFontChanged(); + // + protected: LLViewerTextEditor* mEditor; LLButton* mSaveBtn; diff --git a/indra/newview/llpreviewscript.cpp b/indra/newview/llpreviewscript.cpp index 0a081176ba..08176044dd 100644 --- a/indra/newview/llpreviewscript.cpp +++ b/indra/newview/llpreviewscript.cpp @@ -1839,11 +1839,9 @@ void LLScriptEdCore::onFontChanged() if (font) { mEditor->setFont(font); - mEditor->needsReflow(); if (mPostEditor) { mPostEditor->setFont(font); - mPostEditor->needsReflow(); } } } diff --git a/indra/newview/lltoast.h b/indra/newview/lltoast.h index 69074b1670..2b1fedf74d 100644 --- a/indra/newview/lltoast.h +++ b/indra/newview/lltoast.h @@ -222,7 +222,7 @@ private: LLPanel* mWrapperPanel; // timer counts a lifetime of a toast - std::auto_ptr mTimer; + std::unique_ptr mTimer; F32 mToastLifetime; // in seconds F32 mToastFadingTime; // in seconds diff --git a/indra/newview/llviewerdisplay.cpp b/indra/newview/llviewerdisplay.cpp index 66d04f9cb8..fc1a16b713 100644 --- a/indra/newview/llviewerdisplay.cpp +++ b/indra/newview/llviewerdisplay.cpp @@ -102,6 +102,9 @@ F32 gSavedDrawDistance = 0.0f; F32 gLastDrawDistanceStep = 0.0f; // FIRE-12004: Attachments getting lost on TP LLFrameTimer gPostTeleportFinishKillObjectDelayTimer; +// FIRE-15917 / FIRE-31906: Mesh attachments sometimes vanish after teleports +bool postTeleportResetVB = false; +LLFrameTimer postTeleportResetVBTimer; BOOL gForceRenderLandFence = FALSE; BOOL gDisplaySwapBuffers = FALSE; @@ -332,6 +335,17 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) stop_glerror(); gPipeline.disableLights(); + + // FIRE-15917 / FIRE-31906: Mesh attachments sometimes vanish after teleports + static LLCachedControl teleportArrivalDelay(gSavedSettings, "TeleportArrivalDelay"); + if (postTeleportResetVB && postTeleportResetVBTimer.getElapsedTimeF32() > teleportArrivalDelay()) + { + LL_INFOS("Teleport") << "Resetting Vertex Buffers after TP finished" << LL_ENDL; + postTeleportResetVB = false; + postTeleportResetVBTimer.stop(); + gPipeline.resetVertexBuffers(); + } + // //reset vertex buffers if needed gPipeline.doResetVertexBuffers(); @@ -556,6 +570,11 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) // FIRE-12004: Attachments getting lost on TP gPostTeleportFinishKillObjectDelayTimer.reset(); + + // FIRE-15917 / FIRE-31906: Mesh attachments sometimes vanish after teleports + postTeleportResetVB = true; + postTeleportResetVBTimer.start(); + // break; case LLAgent::TELEPORT_ARRIVING: diff --git a/indra/newview/llviewerfloaterreg.cpp b/indra/newview/llviewerfloaterreg.cpp index 27e59c14d1..9afe182e7c 100644 --- a/indra/newview/llviewerfloaterreg.cpp +++ b/indra/newview/llviewerfloaterreg.cpp @@ -194,6 +194,7 @@ #include "fsfloaterimport.h" #include "fsfloaterim.h" #include "fsfloaterimcontainer.h" +#include "fsfloaterpartialinventory.h" #include "fsfloaterplacedetails.h" #include "fsfloaterposestand.h" #include "fsfloaterprofile.h" @@ -492,6 +493,7 @@ void LLViewerFloaterReg::registerFloaters() LLFloaterReg::add("fs_export", "floater_fs_export.xml", (LLFloaterBuildFunc)&LLFloaterReg::build); LLFloaterReg::add("fs_import", "floater_fs_import.xml", (LLFloaterBuildFunc)&LLFloaterReg::build); LLFloaterReg::add("fs_posestand", "floater_fs_posestand.xml", (LLFloaterBuildFunc)&LLFloaterReg::build); + LLFloaterReg::add("fs_partial_inventory", "floater_fs_partial_inventory.xml", (LLFloaterBuildFunc)&LLFloaterReg::build); LLFloaterReg::add("fs_placedetails", "floater_fs_placedetails.xml", (LLFloaterBuildFunc)&LLFloaterReg::build); LLFloaterReg::add("fs_protectedfolders", "floater_fs_protectedfolders.xml", (LLFloaterBuildFunc)&LLFloaterReg::build); LLFloaterReg::add("fs_radar", "floater_fs_radar.xml", (LLFloaterBuildFunc)&LLFloaterReg::build); diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp index 65bedf92bb..048bc10a1b 100644 --- a/indra/newview/llviewermessage.cpp +++ b/indra/newview/llviewermessage.cpp @@ -4250,13 +4250,6 @@ void send_agent_update(BOOL force_send, BOOL send_reliable) // trigger a control event. U32 control_flags = gAgent.getControlFlags(); - // Rotation into both directions should cancel out - U32 mask = AGENT_CONTROL_YAW_POS | AGENT_CONTROL_YAW_NEG; - if ((control_flags & mask) == mask) - { - control_flags &= ~mask; - } - MASK key_mask = gKeyboard->currentMask(TRUE); if (key_mask & MASK_ALT || key_mask & MASK_CONTROL) diff --git a/indra/newview/llviewertexteditor.cpp b/indra/newview/llviewertexteditor.cpp index 18096a7f35..bfe83fe944 100644 --- a/indra/newview/llviewertexteditor.cpp +++ b/indra/newview/llviewertexteditor.cpp @@ -211,7 +211,9 @@ public: // [/SL:KB] { - mStyle = new LLStyle(LLStyle::Params().font(LLFontGL::getFontSansSerif())); + // FIRE-29425: User-selectable font and size for notecards + //mStyle = new LLStyle(LLStyle::Params().font(LLFontGL::getFontSansSerif())); + mStyle = new LLStyle(LLStyle::Params().font(mEditor.getFont())); mToolTip = inv_item->getName() + '\n' + inv_item->getDescription(); } @@ -328,11 +330,15 @@ public: // [/SL:KB] /*virtual*/ LLStyleConstSP getStyle() const { return mStyle; } + /*virtual*/ void setStyle(LLStyleConstSP style) { mStyle = style; } // FIRE-29425: User-selectable font and size for notecards private: LLUIImagePtr mImage; LLWString mLabel; - LLStyleSP mStyle; + // FIRE-29425: User-selectable font and size for notecards + //LLStyleSP mStyle; + LLStyleConstSP mStyle; + // std::string mToolTip; LLPointer mItem; LLTextEditor& mEditor; diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index 4c15015162..9ffa404d75 100644 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -293,6 +293,9 @@ static const F32 MIN_UI_SCALE = 0.75f; static const F32 MAX_UI_SCALE = 7.0f; static const F32 MIN_DISPLAY_SCALE = 0.75f; +// FIRE-31852: Now it aggressively executes gestures within focussed floaters... +//static const char KEY_MOUSELOOK = 'M'; + static LLCachedControl sSnapshotBaseName(LLCachedControl(gSavedPerAccountSettings, "SnapshotBaseName", "Snapshot")); static LLCachedControl sSnapshotDir(LLCachedControl(gSavedPerAccountSettings, "SnapshotBaseDir", "")); @@ -3287,8 +3290,17 @@ BOOL LLViewerWindow::handleKey(KEY key, MASK mask) if (keyboard_focus && !gFocusMgr.getKeystrokesOnly()) { - LLUICtrl* cur_focus = dynamic_cast(keyboard_focus); - if (cur_focus && cur_focus->acceptsTextInput()) + //Most things should fall through, but mouselook is an exception, + //don't switch to mouselook if any floater has focus + // FIRE-31852: Now it aggressively executes gestures within focussed floaters... + //if ((key == KEY_MOUSELOOK) && !(mask & (MASK_CONTROL | MASK_ALT))) + //{ + // return TRUE; + //} + + //LLUICtrl* cur_focus = dynamic_cast(keyboard_focus); + //if (cur_focus && cur_focus->acceptsTextInput()) + // { #ifdef LL_WINDOWS // On windows Alt Gr key generates additional Ctrl event, as result handling situations diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index 4503c3bce8..5ccec3408a 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -1913,7 +1913,7 @@ BOOL LLVOVolume::genBBoxes(BOOL force_global, BOOL should_update_octree_bounds) break; // - LLFace *face = mDrawable->getFace(i); + LLFace* face = mDrawable->getFace(i); if (!face) { continue; @@ -5662,7 +5662,7 @@ void LLVolumeGeometryManager::registerFace(LLSpatialGroup* group, LLFace* facep, } } - // if (type == LLRenderPass::PASS_ALPHA) // allow tracking through pipeline + if (type == LLRenderPass::PASS_ALPHA) { //for alpha sorting facep->setDrawInfo(draw_info); } @@ -6547,7 +6547,7 @@ U32 LLVolumeGeometryManager::genDrawInfo(LLSpatialGroup* group, U32 mask, LLFace } #endif - + //calculate maximum number of vertices to store in a single buffer static LLCachedControl max_vbo_size(gSavedSettings, "RenderMaxVBOSize", 512); U32 max_vertices = (max_vbo_size * 1024)/LLVertexBuffer::calcVertexSize(group->getSpatialPartition()->mVertexDataMask); max_vertices = llmin(max_vertices, (U32) 65535); @@ -6615,14 +6615,6 @@ U32 LLVolumeGeometryManager::genDrawInfo(LLSpatialGroup* group, U32 mask, LLFace LLFace* facep = *face_iter; LLViewerTexture* tex = facep->getTexture(); const LLTextureEntry* te = facep->getTextureEntry(); - // Don't batch fully transparent faces - if (te && ( te->getAlpha() == 0.f ) && ( te->getGlow() == 0.0 ) && !LLDrawPoolAlpha::sShowDebugAlpha) - { - facep->setSize(0,0); - ++face_iter; - continue; - } - // LLMaterialPtr mat = te->getMaterialParams(); LLMaterialID matId = te->getMaterialID(); @@ -7027,10 +7019,7 @@ U32 LLVolumeGeometryManager::genDrawInfo(LLSpatialGroup* group, U32 mask, LLFace else if (is_alpha) { // can we safely treat this as an alpha mask? - // Nothing actually sets facecolor use the TE alpha instead. - // if (facep->getFaceColor().mV[3] <= 0.f) - if ((te->getAlpha() <=0.f || facep->getFaceColor().mV[3] <= 0.f) && te->getGlow() == 0.0 ) - // + if (facep->getFaceColor().mV[3] <= 0.f) { //100% transparent, don't render unless we're highlighting transparent LL_PROFILE_ZONE_NAMED_CATEGORY_VOLUME("facep->alpha -> invisible"); registerFace(group, facep, LLRenderPass::PASS_ALPHA_INVISIBLE); diff --git a/indra/newview/llwatchdog.cpp b/indra/newview/llwatchdog.cpp index 152f957cc5..83d88c6af4 100644 --- a/indra/newview/llwatchdog.cpp +++ b/indra/newview/llwatchdog.cpp @@ -231,7 +231,7 @@ void LLWatchdog::run() LL_INFOS() << "Watchdog thread delayed: resetting entries." << LL_ENDL; std::for_each(mSuspects.begin(), mSuspects.end(), - std::mem_fun(&LLWatchdogEntry::reset) + [](SuspectsRegistry::value_type suspect) { suspect->reset(); } ); } else @@ -239,7 +239,7 @@ void LLWatchdog::run() SuspectsRegistry::iterator result = std::find_if(mSuspects.begin(), mSuspects.end(), - std::not1(std::mem_fun(&LLWatchdogEntry::isAlive)) + [](SuspectsRegistry::value_type suspect) { return !suspect->isAlive(); } ); if(result != mSuspects.end()) { diff --git a/indra/newview/llworldmipmap.cpp b/indra/newview/llworldmipmap.cpp index 32c2a4a2fe..c283c65999 100644 --- a/indra/newview/llworldmipmap.cpp +++ b/indra/newview/llworldmipmap.cpp @@ -201,7 +201,7 @@ LLPointer LLWorldMipmap::loadObjectsTile(U32 grid_x, U32 //LL_INFOS("WorldMap") << "LLWorldMipmap::loadObjectsTile(), URL = " << imageurl << LL_ENDL; LLPointer img = LLViewerTextureManager::getFetchedTextureFromUrl(imageurl, FTT_MAP_TILE, TRUE, LLGLTexture::BOOST_NONE, LLViewerTexture::LOD_TEXTURE); - LL_INFOS("MAPURL") << "fetching map tile from " << imageurl << LL_ENDL; + //LL_INFOS("MAPURL") << "fetching map tile from " << imageurl << LL_ENDL; img->setBoostLevel(LLGLTexture::BOOST_MAP); diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index 812f292bfe..c146b7632e 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -11301,7 +11301,10 @@ void LLPipeline::generateImpostor(LLVOAvatar* avatar, bool preview_avatar) ++attachment_iter) { LLViewerObject* attached_object = attachment_iter->get(); - if (attached_object && attached_object->isRiggedMesh()) + // FIRE-31966: Some mesh bodies/objects don't show in shape editor previews -> show everything but animesh + //if (attached_object && attached_object->isRiggedMesh()) + if (attached_object && !attached_object->getControlAvatar()) + // { markVisible(attached_object->mDrawable->getSpatialBridge(), *viewer_camera); } @@ -11587,36 +11590,71 @@ void LLPipeline::generateImpostor(LLVOAvatar* avatar, bool preview_avatar) bool LLPipeline::hasRenderBatches(const U32 type) const { + // FIRE-31942, sCull can be invalid if triggering 360 snapshosts fast enough (due to snapshots running in their own co routine) + if( !sCull ) + return {}; + // + return sCull->getRenderMapSize(type) > 0; } LLCullResult::drawinfo_iterator LLPipeline::beginRenderMap(U32 type) { + // FIRE-31942, sCull can be invalid if triggering 360 snapshosts fast enough (due to snapshots running in their own co routine) + if( !sCull ) + return {}; + // + return sCull->beginRenderMap(type); } LLCullResult::drawinfo_iterator LLPipeline::endRenderMap(U32 type) { + // FIRE-31942, sCull can be invalid if triggering 360 snapshosts fast enough (due to snapshots running in their own co routine) + if( !sCull ) + return {}; + // + return sCull->endRenderMap(type); } LLCullResult::sg_iterator LLPipeline::beginAlphaGroups() { + // FIRE-31942, sCull can be invalid if triggering 360 snapshosts fast enough (due to snapshots running in their own co routine) + if( !sCull ) + return {}; + // + return sCull->beginAlphaGroups(); } LLCullResult::sg_iterator LLPipeline::endAlphaGroups() { + // FIRE-31942, sCull can be invalid if triggering 360 snapshosts fast enough (due to snapshots running in their own co routine) + if( !sCull ) + return {}; + // + return sCull->endAlphaGroups(); } LLCullResult::sg_iterator LLPipeline::beginRiggedAlphaGroups() { + // FIRE-31942, sCull can be invalid if triggering 360 snapshosts fast enough (due to snapshots running in their own co routine) + if( !sCull ) + return {}; + // + return sCull->beginRiggedAlphaGroups(); } LLCullResult::sg_iterator LLPipeline::endRiggedAlphaGroups() { + // FIRE-31942, sCull can be invalid if triggering 360 snapshosts fast enough (due to snapshots running in their own co routine) + if( !sCull ) + return {}; + // + return sCull->endRiggedAlphaGroups(); } diff --git a/indra/newview/skins/ansastorm/colors.xml b/indra/newview/skins/ansastorm/colors.xml index a69ba44a78..4d42f48471 100644 --- a/indra/newview/skins/ansastorm/colors.xml +++ b/indra/newview/skins/ansastorm/colors.xml @@ -1397,4 +1397,16 @@ + + + + diff --git a/indra/newview/skins/ansastorm/themes/blood/colors.xml b/indra/newview/skins/ansastorm/themes/blood/colors.xml index 6bf84c5e92..a68adcd3ff 100644 --- a/indra/newview/skins/ansastorm/themes/blood/colors.xml +++ b/indra/newview/skins/ansastorm/themes/blood/colors.xml @@ -1175,4 +1175,16 @@ + + + + diff --git a/indra/newview/skins/ansastorm/themes/classic_brown/colors.xml b/indra/newview/skins/ansastorm/themes/classic_brown/colors.xml index 4b4768c682..19a7c6591b 100644 --- a/indra/newview/skins/ansastorm/themes/classic_brown/colors.xml +++ b/indra/newview/skins/ansastorm/themes/classic_brown/colors.xml @@ -1394,4 +1394,16 @@ + + + + diff --git a/indra/newview/skins/ansastorm/themes/ectoplasma/colors.xml b/indra/newview/skins/ansastorm/themes/ectoplasma/colors.xml index 510fe7c119..461399ee4e 100644 --- a/indra/newview/skins/ansastorm/themes/ectoplasma/colors.xml +++ b/indra/newview/skins/ansastorm/themes/ectoplasma/colors.xml @@ -1163,4 +1163,16 @@ + + + + diff --git a/indra/newview/skins/default/colors.xml b/indra/newview/skins/default/colors.xml index 52594a1a6a..81a524b4c7 100644 --- a/indra/newview/skins/default/colors.xml +++ b/indra/newview/skins/default/colors.xml @@ -1351,4 +1351,16 @@ + + + + diff --git a/indra/newview/skins/default/xui/de/floater_fs_partial_inventory.xml b/indra/newview/skins/default/xui/de/floater_fs_partial_inventory.xml new file mode 100644 index 0000000000..34237aefd6 --- /dev/null +++ b/indra/newview/skins/default/xui/de/floater_fs_partial_inventory.xml @@ -0,0 +1,5 @@ + + + Inventar: [FOLDERNAME] + + diff --git a/indra/newview/skins/default/xui/de/floater_tools.xml b/indra/newview/skins/default/xui/de/floater_tools.xml index 2987fcd3af..0b96d32e3c 100644 --- a/indra/newview/skins/default/xui/de/floater_tools.xml +++ b/indra/newview/skins/default/xui/de/floater_tools.xml @@ -146,7 +146,7 @@ Flächen ausgewählt: [FACES_STRING] - [secondlife:///app/openfloater/object_weights Mehr Infos] + [CAPACITY_STRING] [secondlife:///app/openfloater/object_weights Mehr Infos] Physikgewicht [PHYS_WEIGHT], Darstellungskosten [DISP_WEIGHT]. diff --git a/indra/newview/skins/default/xui/de/menu_inventory.xml b/indra/newview/skins/default/xui/de/menu_inventory.xml index 7f2a1229cb..ddfd6a1cf1 100644 --- a/indra/newview/skins/default/xui/de/menu_inventory.xml +++ b/indra/newview/skins/default/xui/de/menu_inventory.xml @@ -120,6 +120,7 @@ + diff --git a/indra/newview/skins/default/xui/de/menu_login.xml b/indra/newview/skins/default/xui/de/menu_login.xml index 969d486194..0527a0115e 100644 --- a/indra/newview/skins/default/xui/de/menu_login.xml +++ b/indra/newview/skins/default/xui/de/menu_login.xml @@ -16,7 +16,7 @@ - + diff --git a/indra/newview/skins/default/xui/de/menu_viewer.xml b/indra/newview/skins/default/xui/de/menu_viewer.xml index fb2e4b294b..36aae4565d 100644 --- a/indra/newview/skins/default/xui/de/menu_viewer.xml +++ b/indra/newview/skins/default/xui/de/menu_viewer.xml @@ -270,7 +270,7 @@ - + diff --git a/indra/newview/skins/default/xui/de/notifications.xml b/indra/newview/skins/default/xui/de/notifications.xml index 0a3d43d6fc..f4389a2ee2 100644 --- a/indra/newview/skins/default/xui/de/notifications.xml +++ b/indra/newview/skins/default/xui/de/notifications.xml @@ -4329,7 +4329,7 @@ Sie ist voll oder startet in Kürze neu. Sie können die Form eines Mesh-Objekts nicht ändern. - Sie können diese Region nicht betreten, \nda die Region voll ist. + Sie können diese Region nicht betreten, da die Region voll ist. Verknüpfungsfehler – Eigentümer sind unterschiedlich @@ -4587,7 +4587,7 @@ Wählen Sie eine kleinere Landfläche aus. Land kann nicht geteilt werden. Parzelle kann nicht gefunden werden. -Bitte melden Sie den Fehler über „Hilfe“ -> „Fehler melden“. +Bitte melden Sie das Problem über „Hilfe“ -> „Problem melden“. Land kann nicht geteilt werden. Die gesamte Parzelle ist ausgewählt. @@ -4633,7 +4633,7 @@ Wählen Sie eine kleinere Landfläche aus. Passkauf momentan nicht möglich. Versuchen Sie es später erneut. - Objekt kann nicht erstellt werden, \nda die Parzelle voll ist. + Objekt kann nicht erstellt werden, da die Parzelle voll ist. Objekt konnte nicht an festgelegtem Ort platziert werden. Versuchen Sie es erneut. @@ -5570,7 +5570,7 @@ Falls Sie diesen Nutzungsbestimmungen nicht zustimmen, sollten keinerlei finanzi Mehrfach-Import von Windlight abgeschlossen. - Der Anhang „[NAME]“ enthält geriggtes Mesh, ist aber am HUD-Punkt „[HUD_POINT]“ angehängt. Das bedeutet, dass Sie es korrekt sehen werden, alle anderen werden es hingegen gar nicht sehen. Denken Sie darüber nach, den Anhang zu entfernen und an einem regulären Punkt am Körper anzuhängen. + Der Anhang „[NAME]“ enthält geriggtes Mesh, ist aber am HUD-Punkt „[HUD_POINT]“ angehängt. Geriggte Meshes an HUD-Punkten sind nicht sichtbar, weder für Sie selbst noch für andere. Denken Sie darüber nach, den Anhang zu entfernen und an einem regulären Punkt am Körper anzuhängen. diff --git a/indra/newview/skins/default/xui/de/panel_preferences_UI.xml b/indra/newview/skins/default/xui/de/panel_preferences_UI.xml index d28f52b3fc..55ccfc05be 100644 --- a/indra/newview/skins/default/xui/de/panel_preferences_UI.xml +++ b/indra/newview/skins/default/xui/de/panel_preferences_UI.xml @@ -264,6 +264,23 @@ Standard 0. Größere Werte können nicht korrekt funktionieren. Pixel (Erfordert Neustart) [VIEWER_GENERATION]-Standard 20. Viewer 1-Standard 18. + + Schrift für Notizkarten: + + + + + + + + + + + + + + + diff --git a/indra/newview/skins/default/xui/de/panel_preferences_colors.xml b/indra/newview/skins/default/xui/de/panel_preferences_colors.xml index fade06447b..5a090bd586 100644 --- a/indra/newview/skins/default/xui/de/panel_preferences_colors.xml +++ b/indra/newview/skins/default/xui/de/panel_preferences_colors.xml @@ -206,6 +206,26 @@ Farbe für Markierung der Umgebungssuche: + + + Farben für Notizkarten: + + + Text: + + + + Hintergrund: + + + + Cursor: + + + + Auswahl: + + diff --git a/indra/newview/skins/default/xui/de/panel_region_general.xml b/indra/newview/skins/default/xui/de/panel_region_general.xml index 561051a5b0..2c91021deb 100644 --- a/indra/newview/skins/default/xui/de/panel_region_general.xml +++ b/indra/newview/skins/default/xui/de/panel_region_general.xml @@ -19,8 +19,8 @@ Grid-Position: - - + + Typ: diff --git a/indra/newview/skins/default/xui/de/strings.xml b/indra/newview/skins/default/xui/de/strings.xml index 9dabb94957..e28042f7e3 100644 --- a/indra/newview/skins/default/xui/de/strings.xml +++ b/indra/newview/skins/default/xui/de/strings.xml @@ -5452,10 +5452,10 @@ Falls der Fehler weiterhin auftritt, überprüfen Sie bitte Ihre Netzwerk- und F Meine Premium-Mitgliedschaft - Ausgewählte Objekte löschen? + Ausgewählte [COUNT_SELECTION] Objekte löschen ([COUNT_TOTAL] insgesamt)? - Ausgewähltes Objekt löschen? + Ausgewähltes Objekt löschen ([COUNT_TOTAL] insgesamt)? Keine Objekte in diesem Outfit diff --git a/indra/newview/skins/default/xui/en/floater_about.xml b/indra/newview/skins/default/xui/en/floater_about.xml index 74729a2158..ad13ffcc07 100644 --- a/indra/newview/skins/default/xui/en/floater_about.xml +++ b/indra/newview/skins/default/xui/en/floater_about.xml @@ -165,7 +165,7 @@ Additional code generously contributed to Firestorm by: top_pad="4" width="450" wrap="true"> -Albatroz Hird, Alexie Birman, Andromeda Rage, Angeldark Raymaker, Angus Boyd, Animats, Armin Weatherwax, Beq Janus, Casper Warden, Chalice Yao, Chaser Zaks, Chorazin Allen, Cron Stardust, Damian Zhaoying, Dan Threebeards, Dawa Gurbux, Denver Maksim, Drake Arconis, Felyza Wishbringer, f0rbidden, Fractured Crystal, Geenz Spad, Gibson Firehawk, Hitomi Tiponi, Inusaito Sayori, Jean Severine, Katharine Berry, Kittin Ninetails, Kool Koolhoven, Lance Corrimal, Lassie, Latif Khalifa, Laurent Bechir, Magne Metaverse LLC, Magus Freston, Manami Hokkigai, MartinRJ Fayray, McCabe Maxstead, Melancholy Lemon, Melysmile, Mimika Oh, Mister Acacia, MorganMegan, mygoditsfullofstars, Mysty Saunders, Nagi Michinaga, Name Short, nhede Core, NiranV Dean, Nogardrevlis Lectar, Oren Hurvitz, Paladin Forzane, paperwork, Penny Patton, Peyton Menges, programmtest, Qwerty Venom, Rebecca Ashbourne, Revolution Smythe, Romka Swallowtail, Sahkolihaa Contepomi, sal Kaligawa, Samm Florian, Satomi Ahn, Sei Lisa, Sempervirens Oddfellow, Shin Wasp, Shyotl Kuhr, Sione Lomu, Skills Hak, StarlightShining, Sunset Faulkes, Testicular Slingshot, Thickbrick Sleaford, Ubit Umarov, Vaalith Jinn, Vincent Sylvester, Whirly Fizzle, Xenhat Liamano, Zwagoth Klaar and others. +Albatroz Hird, Alexie Birman, Andromeda Rage, Angeldark Raymaker, Angus Boyd, Animats, Armin Weatherwax, Beq Janus, Casper Warden, Chalice Yao, Chaser Zaks, Chorazin Allen, Cron Stardust, Damian Zhaoying, Dan Threebeards, Dawa Gurbux, Denver Maksim, Drake Arconis, Felyza Wishbringer, f0rbidden, Fractured Crystal, Geenz Spad, Gibson Firehawk, Hitomi Tiponi, Inusaito Sayori, Jean Severine, Katharine Berry, Kittin Ninetails, Kool Koolhoven, Lance Corrimal, Lassie, Latif Khalifa, Laurent Bechir, Magne Metaverse LLC, Magus Freston, Manami Hokkigai, MartinRJ Fayray, McCabe Maxstead, Melancholy Lemon, Melysmile, Mimika Oh, Mister Acacia, MorganMegan, Morgan Pennent, mygoditsfullofstars, Mysty Saunders, Nagi Michinaga, Name Short, nhede Core, NiranV Dean, Nogardrevlis Lectar, Oren Hurvitz, Paladin Forzane, paperwork, Penny Patton, Peyton Menges, programmtest, Qwerty Venom, Rebecca Ashbourne, Revolution Smythe, Romka Swallowtail, Sahkolihaa Contepomi, sal Kaligawa, Samm Florian, Satomi Ahn, Sei Lisa, Sempervirens Oddfellow, Shin Wasp, Shyotl Kuhr, Sione Lomu, Skills Hak, StarlightShining, Sunset Faulkes, Testicular Slingshot, Thickbrick Sleaford, Ubit Umarov, Vaalith Jinn, Vincent Sylvester, Whirly Fizzle, Xenhat Liamano, Zwagoth Klaar and others. diff --git a/indra/newview/skins/default/xui/en/floater_fs_partial_inventory.xml b/indra/newview/skins/default/xui/en/floater_fs_partial_inventory.xml new file mode 100644 index 0000000000..3f40d1c755 --- /dev/null +++ b/indra/newview/skins/default/xui/en/floater_fs_partial_inventory.xml @@ -0,0 +1,34 @@ + + + Inventory: [FOLDERNAME] + + + + diff --git a/indra/newview/skins/default/xui/en/floater_preview_notecard.xml b/indra/newview/skins/default/xui/en/floater_preview_notecard.xml index 6024086167..c92e4224f7 100644 --- a/indra/newview/skins/default/xui/en/floater_preview_notecard.xml +++ b/indra/newview/skins/default/xui/en/floater_preview_notecard.xml @@ -60,6 +60,11 @@ name="desc" width="296" /> - [secondlife:///app/openfloater/object_weights More info] + [CAPACITY_STRING] [secondlife:///app/openfloater/object_weights More info] - - - - - + + + + --> diff --git a/indra/newview/skins/default/xui/en/menu_viewer.xml b/indra/newview/skins/default/xui/en/menu_viewer.xml index 24c32df727..f874237d77 100644 --- a/indra/newview/skins/default/xui/en/menu_viewer.xml +++ b/indra/newview/skins/default/xui/en/menu_viewer.xml @@ -2519,7 +2519,7 @@ function="ReportAbuse" /> diff --git a/indra/newview/skins/default/xui/en/notifications.xml b/indra/newview/skins/default/xui/en/notifications.xml index 052baaeec8..7fd4e56493 100644 --- a/indra/newview/skins/default/xui/en/notifications.xml +++ b/indra/newview/skins/default/xui/en/notifications.xml @@ -11749,7 +11749,7 @@ You may not alter the shape of a mesh object name="FullRegionCantEnter" type="notify"> fail -You can't enter this region because \nthe region is full. +You can't enter this region because the region is full. fail Can't divide land. Can't find the parcel. -Please report with Help -> Report Bug... +Please report with Help -> Report Problem... fail -Can't create object because \nthe parcel is full. +Can't create object because the parcel is full. -An attachment named "[NAME]" contains rigged mesh but is attached to the HUD point "[HUD_POINT]". This means you will see it rendered correctly, but everyone else is not going to be able see it at all. You might want to consider taking it off and re-attaching it to a regular body attachment point. +An attachment named "[NAME]" contains rigged mesh but is attached to the HUD point "[HUD_POINT]". Rigged meshes attached to HUD points won't be visible at all - neither for you nor for anybody else. You might want to consider taking it off and re-attaching it to a regular body attachment point. 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 d8b2cc9058..dbc1b32401 100644 --- a/indra/newview/skins/default/xui/en/panel_navigation_bar.xml +++ b/indra/newview/skins/default/xui/en/panel_navigation_bar.xml @@ -8,6 +8,7 @@ top="19" left="0" follows="left|top|right" + focus_root="true" height="39" layout="topleft" name="navigation_bar" diff --git a/indra/newview/skins/default/xui/en/panel_preferences_UI.xml b/indra/newview/skins/default/xui/en/panel_preferences_UI.xml index dc98ebf690..7d1166bcfe 100644 --- a/indra/newview/skins/default/xui/en/panel_preferences_UI.xml +++ b/indra/newview/skins/default/xui/en/panel_preferences_UI.xml @@ -1734,6 +1734,49 @@ Default 0. Larger values may not work well. [VIEWER_GENERATION] default 20. Viewer 1 default 18. + + Notecard Editor Font: + + + + + + + + + + + + + + + + - Delete selected items? - Delete selected item? + Delete selected [COUNT_SELECTION] items ([COUNT_TOTAL]] total)? + Delete selected item ([COUNT_TOTAL]] total)? There are no items in this outfit diff --git a/indra/newview/skins/default/xui/es/notifications.xml b/indra/newview/skins/default/xui/es/notifications.xml index e292fd9cf1..4d447090b3 100644 --- a/indra/newview/skins/default/xui/es/notifications.xml +++ b/indra/newview/skins/default/xui/es/notifications.xml @@ -4146,7 +4146,7 @@ Prueba otra vez dentro de un minuto. No se puede cambiar la forma de un objeto de la malla - No puedes entrar en esta región porque \nla región está llena. + No puedes entrar en esta región porque la región está llena. Error de vínculo: los propietarios son diferentes @@ -4447,7 +4447,7 @@ Prueba a seleccionar un terreno más pequeño. No se puede comprar el pase ahora mismo. Vuelve a intentarlo más tarde. - No se puede crear el objeto porque \nla parcela está llena. + No se puede crear el objeto porque la parcela está llena. Error al colocar el objeto en el lugar especificado. Vuelve a intentarlo. diff --git a/indra/newview/skins/default/xui/es/panel_region_general.xml b/indra/newview/skins/default/xui/es/panel_region_general.xml index 511b33baf8..11e9c3d235 100644 --- a/indra/newview/skins/default/xui/es/panel_region_general.xml +++ b/indra/newview/skins/default/xui/es/panel_region_general.xml @@ -19,8 +19,6 @@ Pos. en la red: - - Tipo: diff --git a/indra/newview/skins/default/xui/fr/floater_fs_partial_inventory.xml b/indra/newview/skins/default/xui/fr/floater_fs_partial_inventory.xml new file mode 100644 index 0000000000..5f5064ffea --- /dev/null +++ b/indra/newview/skins/default/xui/fr/floater_fs_partial_inventory.xml @@ -0,0 +1,5 @@ + + + Inventaire : [FOLDERNAME] + + diff --git a/indra/newview/skins/default/xui/fr/floater_model_preview.xml b/indra/newview/skins/default/xui/fr/floater_model_preview.xml index 306250572f..61c3deffb8 100644 --- a/indra/newview/skins/default/xui/fr/floater_model_preview.xml +++ b/indra/newview/skins/default/xui/fr/floater_model_preview.xml @@ -80,7 +80,7 @@ - + - + + + width="149"> Mesh Information: @@ -2628,7 +2622,7 @@ Lowest: left="125" halign="left" name="LOD_swap_label" - top_pad="3" + top_pad="3" value="LOD Swap" visible="false" width="60" /> @@ -2654,7 +2648,7 @@ Lowest: name="LOD_swap_fs_default" top_delta="0" visible="false" - width="30"> + width="30" > [APP_NAME_ABBR] [FACTOR] @@ -2795,6 +2789,34 @@ Low ↔ Lwst tool_tip="Allows object to flex about the Z axis (Client-side only)" top_pad="5" width="121" /> + + Physics Shape Type: @@ -3051,7 +3073,7 @@ Low ↔ Lwst layout="topleft" name="material" top_pad="5" - width="150" + width="134" left="144"> + + + + diff --git a/indra/newview/skins/starlightcui/themes/custom_dark/colors.xml b/indra/newview/skins/starlightcui/themes/custom_dark/colors.xml index 72328f968c..5585c9638f 100755 --- a/indra/newview/skins/starlightcui/themes/custom_dark/colors.xml +++ b/indra/newview/skins/starlightcui/themes/custom_dark/colors.xml @@ -1126,5 +1126,17 @@ + + + + diff --git a/indra/newview/skins/starlightcui/themes/custom_light/colors.xml b/indra/newview/skins/starlightcui/themes/custom_light/colors.xml index 417d97de02..658c3abda9 100755 --- a/indra/newview/skins/starlightcui/themes/custom_light/colors.xml +++ b/indra/newview/skins/starlightcui/themes/custom_light/colors.xml @@ -1181,4 +1181,16 @@ + + + + diff --git a/indra/newview/skins/starlightcui/xui/en/floater_tools.xml b/indra/newview/skins/starlightcui/xui/en/floater_tools.xml index b8d8f8dcc0..0b8542ecde 100644 --- a/indra/newview/skins/starlightcui/xui/en/floater_tools.xml +++ b/indra/newview/skins/starlightcui/xui/en/floater_tools.xml @@ -830,6 +830,22 @@ width="100"> Nothing selected. + - [CAPACITY_STRING] [secondlife:///app/openfloater/object_weights More info] + [CAPACITY_STRING] [secondlife:///app/openfloater/object_weights More info] - - Paste Position + +Paste Position [VALUE] - - Paste Size + +Paste Size [VALUE] - - Paste Rotation + +Paste Rotation [VALUE] - + + + width="149"> Mesh Information: @@ -2628,7 +2622,7 @@ Lowest: left="125" halign="left" name="LOD_swap_label" - top_pad="3" + top_pad="3" value="LOD Swap" visible="false" width="60" /> @@ -2654,7 +2648,7 @@ Lowest: name="LOD_swap_fs_default" top_delta="0" visible="false" - width="30"> + width="30" > [APP_NAME_ABBR] [FACTOR] @@ -2795,6 +2789,34 @@ Low ↔ Lwst tool_tip="Allows object to flex about the Z axis (Client-side only)" top_pad="5" width="121" /> + + Physics Shape Type: @@ -3051,7 +3073,7 @@ Low ↔ Lwst layout="topleft" name="material" top_pad="5" - width="150" + width="134" left="144"> + + + + diff --git a/indra/newview/skins/vintage/xui/en/floater_tools.xml b/indra/newview/skins/vintage/xui/en/floater_tools.xml index 1029df0290..eda1ac3be8 100644 --- a/indra/newview/skins/vintage/xui/en/floater_tools.xml +++ b/indra/newview/skins/vintage/xui/en/floater_tools.xml @@ -872,7 +872,7 @@ top_pad="-5" visible="false" width="280"> - [secondlife:///app/openfloater/object_weights More info] + [CAPACITY_STRING] [secondlife:///app/openfloater/object_weights More info] Properly name OS version, also add Phoenix- in front of installer name #installer_file = self.installer_base_name() + '_Setup.exe' - installer_file = "Phoenix-%(app_name)s-%(version_dashes)s_Setup.exe" % substitution_strings + installer_file = self.fs_installer_basename() + "_Setup.exe" # substitution_strings['installer_file'] = installer_file @@ -1622,8 +1623,11 @@ class DarwinManifest(ViewerManifest): volname=CHANNEL_VENDOR_BASE+" Installer" # DO NOT CHANGE without understanding comment above - imagename = self.installer_base_name() - + # Make sure all our package names look similar + #imagename = self.installer_base_name() + imagename = self.fs_installer_basename() + # + sparsename = imagename + ".sparseimage" finalname = imagename + ".dmg" # make sure we don't have stale files laying about @@ -2075,9 +2079,9 @@ class LinuxManifest(ViewerManifest): def package_finish(self): # a standard map of strings for replacing in the templates - installer_name_components = ['Phoenix',self.app_name(),self.args.get('arch'),'.'.join(self.args['version'])] - installer_name = "_".join(installer_name_components) + #installer_name = self.installer_base_name() + installer_name = self.fs_installer_basename() self.fs_save_breakpad_symbols("linux") self.fs_delete_linux_symbols() # Delete old syms diff --git a/indra/test/lldoubledispatch_tut.cpp b/indra/test/lldoubledispatch_tut.cpp index ad8f6454d4..e38d0e92a3 100644 --- a/indra/test/lldoubledispatch_tut.cpp +++ b/indra/test/lldoubledispatch_tut.cpp @@ -135,10 +135,10 @@ namespace tut // Instantiate a few GameObjects. Make sure we refer to them // polymorphically, and don't let them leak. - std::auto_ptr home; - std::auto_ptr obstacle; - std::auto_ptr tug; - std::auto_ptr patrol; + std::unique_ptr home; + std::unique_ptr obstacle; + std::unique_ptr tug; + std::unique_ptr patrol; // prototype objects Asteroid dummyAsteroid; diff --git a/scripts/configure_firestorm.sh b/scripts/configure_firestorm.sh index 3f92c1b439..353c760f9e 100755 --- a/scripts/configure_firestorm.sh +++ b/scripts/configure_firestorm.sh @@ -50,7 +50,7 @@ LL_ARGS_PASSTHRU="" JOBS="0" WANTS_NINJA=$FALSE WANTS_VSCODE=$FALSE -USE_VSTOOL=$TRUE +USE_VSTOOL=$FALSE TESTBUILD_PERIOD="0" SINGLEGRID_URI="" @@ -88,7 +88,7 @@ showUsage() echo " --ninja : Build using Ninja" echo " --vscode : Exports compile commands for VSCode (Linux only)" echo " --compiler-cache : Try to detect and use compiler cache (needs also --ninja for OSX and Windows)" - echo " --no-vstools : Do not use vstool to setup project startup properties (windows only)" + echo " --vstools : Use vstool to setup project startup properties (Windows only)" echo echo "All arguments not in the above list will be passed through to LL's configure/build." echo @@ -98,7 +98,7 @@ getArgs() # $* = the options passed in from main { if [ $# -gt 0 ]; then - while getoptex "clean build config version package no-package fmodstudio openal ninja vscode compiler-cache no-vstools jobs: platform: kdu opensim no-opensim singlegrid: avx avx2 tracy crashreporting testbuild: help chan: btype:" "$@" ; do + while getoptex "clean build config version package no-package fmodstudio openal ninja vscode compiler-cache vstools jobs: platform: kdu opensim no-opensim singlegrid: avx avx2 tracy crashreporting testbuild: help chan: btype:" "$@" ; do #ensure options are valid if [ -z "$OPTOPT" ] ; then @@ -138,7 +138,7 @@ getArgs() ninja) WANTS_NINJA=$TRUE;; vscode) WANTS_VSCODE=$TRUE;; compiler-cache) WANTS_CACHE=$TRUE;; - no-vstools) USE_VSTOOL=$FALSE;; + vstools) USE_VSTOOL=$TRUE;; help) showUsage && exit 0;; @@ -578,7 +578,7 @@ if [ $WANTS_CONFIG -eq $TRUE ] ; then cmake -G "$TARGET" ../indra $CHANNEL ${GITHASH} $FMODSTUDIO $OPENAL $KDU $OPENSIM $SINGLEGRID $AVX_OPTIMIZATION $AVX2_OPTIMIZATION $TRACY_PROFILER $TESTBUILD $PACKAGE \ $UNATTENDED -DLL_TESTS:BOOL=OFF -DADDRESS_SIZE:STRING=$AUTOBUILD_ADDRSIZE -DCMAKE_BUILD_TYPE:STRING=$BTYPE $CACHE_OPT \ - $CRASH_REPORTING -DVIEWER_SYMBOL_FILE:STRING="${VIEWER_SYMBOL_FILE:-}" -DROOT_PROJECT_NAME:STRING=Firestorm $LL_ARGS_PASSTHRU ${VSCODE_FLAGS:-} | tee $LOG + $CRASH_REPORTING -DVIEWER_SYMBOL_FILE:STRING="${VIEWER_SYMBOL_FILE:-}" $LL_ARGS_PASSTHRU ${VSCODE_FLAGS:-} | tee $LOG if [ $TARGET_PLATFORM == "windows" -a $USE_VSTOOL -eq $TRUE ] ; then echo "Setting startup project via vstool"