From 570b91f4724c30065a047a9270c7daef1963a548 Mon Sep 17 00:00:00 2001 From: "Boroondas Gupte (patch by Robin Cornelius)" Date: Tue, 31 Aug 2010 12:16:03 +0200 Subject: VWR-20911 FIXED CMake build arch detection is inaccurate and incomplete Robin Cornelius' patch from http://jira.secondlife.com/secure/attachment/42801/SNOW-776+Don%27t+use+uname+for+build+arch+detection%2C+use+compiler.patch applied without fuzz: patching file indra/cmake/Variables.cmake Hunk #1 succeeded at 52 (offset -2 lines). Added entry in doc/contributions.txt. No further changes other than that. --- doc/contributions.txt | 1 + indra/cmake/Variables.cmake | 17 +++++++++-------- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/doc/contributions.txt b/doc/contributions.txt index 31ea1bbc5b..4b97e78b0f 100644 --- a/doc/contributions.txt +++ b/doc/contributions.txt @@ -475,6 +475,7 @@ Robin Cornelius VWR-2488 VWR-9557 VWR-12587 + VWR-20911 Ryozu Kojima VWR-53 VWR-287 diff --git a/indra/cmake/Variables.cmake b/indra/cmake/Variables.cmake index 75b66a85da..12a9ab7db9 100644 --- a/indra/cmake/Variables.cmake +++ b/indra/cmake/Variables.cmake @@ -52,19 +52,20 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "Linux") set(LINUX ON BOOl FORCE) # If someone has specified a word size, use that to determine the - # architecture. Otherwise, let the architecture specify the word size. + # architecture. Otherwise, let the compiler specify the word size. + # Using uname will break under chroots and other cross arch compiles. RC if (WORD_SIZE EQUAL 32) set(ARCH i686) elseif (WORD_SIZE EQUAL 64) set(ARCH x86_64) else (WORD_SIZE EQUAL 32) - execute_process(COMMAND uname -m COMMAND sed s/i.86/i686/ - OUTPUT_VARIABLE ARCH OUTPUT_STRIP_TRAILING_WHITESPACE) - if (ARCH STREQUAL x86_64) - set(WORD_SIZE 64) - else (ARCH STREQUAL x86_64) - set(WORD_SIZE 32) - endif (ARCH STREQUAL x86_64) + if(CMAKE_SIZEOF_VOID_P MATCHES 4) + set(ARCH i686) + set(WORD_SIZE 32) + else(CMAKE_SIZEOF_VOID_P MATCHES 4) + set(ARCH x86_64) + set(WORD_SIZE 64) + endif(CMAKE_SIZEOF_VOID_P MATCHES 4) endif (WORD_SIZE EQUAL 32) set(LL_ARCH ${ARCH}_linux) -- cgit v1.2.3 From 88e7a631b3e4c3d63aa80fe9b3e7f2595d3f45f8 Mon Sep 17 00:00:00 2001 From: "Boroondas Gupte (daggyfied changeset by Techwolf Lupindo, original fix by Robin Cornelius)" Date: Thu, 16 Sep 2010 13:26:45 +0200 Subject: SNOW-512/SNOW-287: Build of LLPlugin fails on 64bit linux due to non PIC code linking into the DSO Formatting, cleanup, and one minor change by Techwolf Lupindo. Minor change was a move of the hunk in indra/media_plugins/webkit/CmakeLists.txt to same area as the other plugins CmakeLists.txt files. daggyfied version of https://bitbucket.org/Techwolf/viewer-development/changeset/00bd21962052 --- doc/contributions.txt | 2 ++ indra/llcommon/CMakeLists.txt | 7 +++++++ indra/llplugin/CMakeLists.txt | 8 ++++++++ indra/media_plugins/base/CMakeLists.txt | 8 ++++++++ indra/media_plugins/example/CMakeLists.txt | 8 ++++++++ indra/media_plugins/gstreamer010/CMakeLists.txt | 8 ++++++++ indra/media_plugins/webkit/CMakeLists.txt | 8 ++++++++ 7 files changed, 49 insertions(+) diff --git a/doc/contributions.txt b/doc/contributions.txt index 2e4d803252..461ddeb6b9 100644 --- a/doc/contributions.txt +++ b/doc/contributions.txt @@ -502,6 +502,8 @@ Ringo Tuxing Robin Cornelius SNOW-108 SNOW-204 + SNOW-287 + SNOW-512 VWR-2488 VWR-9557 VWR-11128 diff --git a/indra/llcommon/CMakeLists.txt b/indra/llcommon/CMakeLists.txt index 9ead183a9e..feb6d50799 100644 --- a/indra/llcommon/CMakeLists.txt +++ b/indra/llcommon/CMakeLists.txt @@ -250,6 +250,13 @@ list(APPEND llcommon_SOURCE_FILES ${llcommon_HEADER_FILES}) if(LLCOMMON_LINK_SHARED) add_library (llcommon SHARED ${llcommon_SOURCE_FILES}) + if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + if(WINDOWS) + add_definitions(/FIXED:NO) + else(WINDOWS) # not windows therefore gcc LINUX and DARWIN + add_definitions(-fPIC) + endif(WINDOWS) + endif(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) ll_stage_sharedlib(llcommon) else(LLCOMMON_LINK_SHARED) add_library (llcommon ${llcommon_SOURCE_FILES}) diff --git a/indra/llplugin/CMakeLists.txt b/indra/llplugin/CMakeLists.txt index 6706775d4f..d9b623d5c0 100644 --- a/indra/llplugin/CMakeLists.txt +++ b/indra/llplugin/CMakeLists.txt @@ -48,6 +48,14 @@ set(llplugin_HEADER_FILES set_source_files_properties(${llplugin_HEADER_FILES} PROPERTIES HEADER_FILE_ONLY TRUE) +if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + if(WINDOWS) + add_definitions(/FIXED:NO) + else(WINDOWS) # not windows therefore gcc LINUX and DARWIN + add_definitions(-fPIC) + endif(WINDOWS) +endif (NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + list(APPEND llplugin_SOURCE_FILES ${llplugin_HEADER_FILES}) add_library (llplugin ${llplugin_SOURCE_FILES}) diff --git a/indra/media_plugins/base/CMakeLists.txt b/indra/media_plugins/base/CMakeLists.txt index f8d2dabc6c..16fd024139 100644 --- a/indra/media_plugins/base/CMakeLists.txt +++ b/indra/media_plugins/base/CMakeLists.txt @@ -25,6 +25,14 @@ include_directories( ### media_plugin_base +if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + if(WINDOWS) + add_definitions(/FIXED:NO) + else(WINDOWS) # not windows therefore gcc LINUX and DARWIN + add_definitions(-fPIC) + endif(WINDOWS) +endif (NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + set(media_plugin_base_SOURCE_FILES media_plugin_base.cpp ) diff --git a/indra/media_plugins/example/CMakeLists.txt b/indra/media_plugins/example/CMakeLists.txt index 4d82f2747c..7e4cdb0daf 100644 --- a/indra/media_plugins/example/CMakeLists.txt +++ b/indra/media_plugins/example/CMakeLists.txt @@ -29,6 +29,14 @@ include_directories( ### media_plugin_example +if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + if(WINDOWS) + add_definitions(/FIXED:NO) + else(WINDOWS) # not windows therefore gcc LINUX and DARWIN + add_definitions(-fPIC) + endif(WINDOWS) +endif (NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + set(media_plugin_example_SOURCE_FILES media_plugin_example.cpp ) diff --git a/indra/media_plugins/gstreamer010/CMakeLists.txt b/indra/media_plugins/gstreamer010/CMakeLists.txt index 3b73e04786..d6d697ba81 100644 --- a/indra/media_plugins/gstreamer010/CMakeLists.txt +++ b/indra/media_plugins/gstreamer010/CMakeLists.txt @@ -30,6 +30,14 @@ include_directories( ### media_plugin_gstreamer010 +if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + if(WINDOWS) + add_definitions(/FIXED:NO) + else(WINDOWS) # not windows therefore gcc LINUX and DARWIN + add_definitions(-fPIC) + endif(WINDOWS) +endif (NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + set(media_plugin_gstreamer010_SOURCE_FILES media_plugin_gstreamer010.cpp llmediaimplgstreamer_syms.cpp diff --git a/indra/media_plugins/webkit/CMakeLists.txt b/indra/media_plugins/webkit/CMakeLists.txt index 5bccd589d8..2073ee00de 100644 --- a/indra/media_plugins/webkit/CMakeLists.txt +++ b/indra/media_plugins/webkit/CMakeLists.txt @@ -29,6 +29,14 @@ include_directories( ### media_plugin_webkit +if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + if(WINDOWS) + add_definitions(/FIXED:NO) + else(WINDOWS) # not windows therefore gcc LINUX and DARWIN + add_definitions(-fPIC) + endif(WINDOWS) +endif (NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + set(media_plugin_webkit_SOURCE_FILES media_plugin_webkit.cpp ) -- cgit v1.2.3 From 64f0b9a7f8d96e170049990372f445d471b826ac Mon Sep 17 00:00:00 2001 From: "Boroondas Gupte (original patches by Aimee Linden)" Date: Tue, 31 Aug 2010 13:48:30 +0200 Subject: SNOW-748 FIXED Building on OSX 10.6 fails with "warning: -mdynamic-no-pic overrides - fpic or -fPIC" Originally commited at http://svn.secondlife.com/trac/linden/changeset/3499/projects/2010/snowglobe and http://svn.secondlife.com/trac/linden/changeset/3501 SVN changeset 3499 partially applied with --ignore-whitespace: Hunk #1 FAILED at 259. Hunk #2 FAILED at 265. 2 out of 2 hunks FAILED -- saving rejects to file indra/llcommon/CMakeLists.txt.rej patching file indra/media_plugins/webkit/CMakeLists.txt Hunk #1 succeeded at 33 with fuzz 1 (offset -8 lines). patching file indra/media_plugins/base/CMakeLists.txt patching file indra/media_plugins/gstreamer010/CMakeLists.txt patching file indra/media_plugins/example/CMakeLists.txt patching file indra/llplugin/CMakeLists.txt Manually applied to indra/llcommon/CMakeLists.txt (straight forward). SVN changeset 3501 applied with fuzz 1: patching file indra/media_plugins/webkit/CMakeLists.txt Hunk #1 succeeded at 33 with fuzz 1 (offset -8 lines). Hunk #2 succeeded at 39 with fuzz 1 (offset -8 lines). No further changes other than that. --- indra/llcommon/CMakeLists.txt | 4 ++-- indra/llplugin/CMakeLists.txt | 14 +++++++------- indra/media_plugins/base/CMakeLists.txt | 4 ++-- indra/media_plugins/example/CMakeLists.txt | 4 ++-- indra/media_plugins/gstreamer010/CMakeLists.txt | 4 ++-- indra/media_plugins/webkit/CMakeLists.txt | 4 ++-- 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/indra/llcommon/CMakeLists.txt b/indra/llcommon/CMakeLists.txt index feb6d50799..20a6c8d709 100644 --- a/indra/llcommon/CMakeLists.txt +++ b/indra/llcommon/CMakeLists.txt @@ -250,13 +250,13 @@ list(APPEND llcommon_SOURCE_FILES ${llcommon_HEADER_FILES}) if(LLCOMMON_LINK_SHARED) add_library (llcommon SHARED ${llcommon_SOURCE_FILES}) - if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + if(NOT WORD_SIZE EQUAL 32) if(WINDOWS) add_definitions(/FIXED:NO) else(WINDOWS) # not windows therefore gcc LINUX and DARWIN add_definitions(-fPIC) endif(WINDOWS) - endif(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) + endif(NOT WORD_SIZE EQUAL 32) ll_stage_sharedlib(llcommon) else(LLCOMMON_LINK_SHARED) add_library (llcommon ${llcommon_SOURCE_FILES}) diff --git a/indra/llplugin/CMakeLists.txt b/indra/llplugin/CMakeLists.txt index d9b623d5c0..51cb0d78b4 100644 --- a/indra/llplugin/CMakeLists.txt +++ b/indra/llplugin/CMakeLists.txt @@ -48,13 +48,13 @@ set(llplugin_HEADER_FILES set_source_files_properties(${llplugin_HEADER_FILES} PROPERTIES HEADER_FILE_ONLY TRUE) -if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) - if(WINDOWS) - add_definitions(/FIXED:NO) - else(WINDOWS) # not windows therefore gcc LINUX and DARWIN - add_definitions(-fPIC) - endif(WINDOWS) -endif (NOT CMAKE_SIZEOF_VOID_P MATCHES 4) +if(NOT WORD_SIZE EQUAL 32) + if(WINDOWS) + add_definitions(/FIXED:NO) + else(WINDOWS) # not windows therefore gcc LINUX and DARWIN + add_definitions(-fPIC) + endif(WINDOWS) +endif(NOT WORD_SIZE EQUAL 32) list(APPEND llplugin_SOURCE_FILES ${llplugin_HEADER_FILES}) diff --git a/indra/media_plugins/base/CMakeLists.txt b/indra/media_plugins/base/CMakeLists.txt index 16fd024139..3ad94b0c64 100644 --- a/indra/media_plugins/base/CMakeLists.txt +++ b/indra/media_plugins/base/CMakeLists.txt @@ -25,13 +25,13 @@ include_directories( ### media_plugin_base -if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) +if(NOT WORD_SIZE EQUAL 32) if(WINDOWS) add_definitions(/FIXED:NO) else(WINDOWS) # not windows therefore gcc LINUX and DARWIN add_definitions(-fPIC) endif(WINDOWS) -endif (NOT CMAKE_SIZEOF_VOID_P MATCHES 4) +endif(NOT WORD_SIZE EQUAL 32) set(media_plugin_base_SOURCE_FILES media_plugin_base.cpp diff --git a/indra/media_plugins/example/CMakeLists.txt b/indra/media_plugins/example/CMakeLists.txt index 7e4cdb0daf..56cefde4bd 100644 --- a/indra/media_plugins/example/CMakeLists.txt +++ b/indra/media_plugins/example/CMakeLists.txt @@ -29,13 +29,13 @@ include_directories( ### media_plugin_example -if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) +if(NOT WORD_SIZE EQUAL 32) if(WINDOWS) add_definitions(/FIXED:NO) else(WINDOWS) # not windows therefore gcc LINUX and DARWIN add_definitions(-fPIC) endif(WINDOWS) -endif (NOT CMAKE_SIZEOF_VOID_P MATCHES 4) +endif(NOT WORD_SIZE EQUAL 32) set(media_plugin_example_SOURCE_FILES media_plugin_example.cpp diff --git a/indra/media_plugins/gstreamer010/CMakeLists.txt b/indra/media_plugins/gstreamer010/CMakeLists.txt index d6d697ba81..ba66166c55 100644 --- a/indra/media_plugins/gstreamer010/CMakeLists.txt +++ b/indra/media_plugins/gstreamer010/CMakeLists.txt @@ -30,13 +30,13 @@ include_directories( ### media_plugin_gstreamer010 -if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) +if(NOT WORD_SIZE EQUAL 32) if(WINDOWS) add_definitions(/FIXED:NO) else(WINDOWS) # not windows therefore gcc LINUX and DARWIN add_definitions(-fPIC) endif(WINDOWS) -endif (NOT CMAKE_SIZEOF_VOID_P MATCHES 4) +endif(NOT WORD_SIZE EQUAL 32) set(media_plugin_gstreamer010_SOURCE_FILES media_plugin_gstreamer010.cpp diff --git a/indra/media_plugins/webkit/CMakeLists.txt b/indra/media_plugins/webkit/CMakeLists.txt index 2073ee00de..673e059c34 100644 --- a/indra/media_plugins/webkit/CMakeLists.txt +++ b/indra/media_plugins/webkit/CMakeLists.txt @@ -29,13 +29,13 @@ include_directories( ### media_plugin_webkit -if(NOT CMAKE_SIZEOF_VOID_P MATCHES 4) +if(NOT WORD_SIZE EQUAL 32) if(WINDOWS) add_definitions(/FIXED:NO) else(WINDOWS) # not windows therefore gcc LINUX and DARWIN add_definitions(-fPIC) endif(WINDOWS) -endif (NOT CMAKE_SIZEOF_VOID_P MATCHES 4) +endif(NOT WORD_SIZE EQUAL 32) set(media_plugin_webkit_SOURCE_FILES media_plugin_webkit.cpp -- cgit v1.2.3 From ea112188e258cd51856b767311ee7917c114413a Mon Sep 17 00:00:00 2001 From: Boroondas Gupte Date: Tue, 31 Aug 2010 14:33:27 +0200 Subject: SNOW-748 FOLLOWUP make CMake if indentation consistent with other occurrences (i.e. two spaces only) --- indra/llcommon/CMakeLists.txt | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/indra/llcommon/CMakeLists.txt b/indra/llcommon/CMakeLists.txt index 20a6c8d709..f5acadf30c 100644 --- a/indra/llcommon/CMakeLists.txt +++ b/indra/llcommon/CMakeLists.txt @@ -249,15 +249,15 @@ set_source_files_properties(${llcommon_HEADER_FILES} list(APPEND llcommon_SOURCE_FILES ${llcommon_HEADER_FILES}) if(LLCOMMON_LINK_SHARED) - add_library (llcommon SHARED ${llcommon_SOURCE_FILES}) - if(NOT WORD_SIZE EQUAL 32) - if(WINDOWS) - add_definitions(/FIXED:NO) - else(WINDOWS) # not windows therefore gcc LINUX and DARWIN - add_definitions(-fPIC) - endif(WINDOWS) - endif(NOT WORD_SIZE EQUAL 32) - ll_stage_sharedlib(llcommon) + add_library (llcommon SHARED ${llcommon_SOURCE_FILES}) + if(NOT WORD_SIZE EQUAL 32) + if(WINDOWS) + add_definitions(/FIXED:NO) + else(WINDOWS) # not windows therefore gcc LINUX and DARWIN + add_definitions(-fPIC) + endif(WINDOWS) + endif(NOT WORD_SIZE EQUAL 32) + ll_stage_sharedlib(llcommon) else(LLCOMMON_LINK_SHARED) add_library (llcommon ${llcommon_SOURCE_FILES}) endif(LLCOMMON_LINK_SHARED) -- cgit v1.2.3 From 3ca4baeebc3fd3cd10faf27560237daae0b39547 Mon Sep 17 00:00:00 2001 From: Boroondas Gupte Date: Tue, 31 Aug 2010 14:41:46 +0200 Subject: VWR-20911 FOLLOWUP fixed indentation (cmake files use spaces only) --- indra/cmake/Variables.cmake | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/indra/cmake/Variables.cmake b/indra/cmake/Variables.cmake index 12a9ab7db9..0573aa85d1 100644 --- a/indra/cmake/Variables.cmake +++ b/indra/cmake/Variables.cmake @@ -60,12 +60,12 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "Linux") set(ARCH x86_64) else (WORD_SIZE EQUAL 32) if(CMAKE_SIZEOF_VOID_P MATCHES 4) - set(ARCH i686) - set(WORD_SIZE 32) - else(CMAKE_SIZEOF_VOID_P MATCHES 4) - set(ARCH x86_64) - set(WORD_SIZE 64) - endif(CMAKE_SIZEOF_VOID_P MATCHES 4) + set(ARCH i686) + set(WORD_SIZE 32) + else(CMAKE_SIZEOF_VOID_P MATCHES 4) + set(ARCH x86_64) + set(WORD_SIZE 64) + endif(CMAKE_SIZEOF_VOID_P MATCHES 4) endif (WORD_SIZE EQUAL 32) set(LL_ARCH ${ARCH}_linux) -- cgit v1.2.3 From 862a951880a8dfb2096b8bb88842f427d3c5f152 Mon Sep 17 00:00:00 2001 From: Merov Linden Date: Wed, 6 Oct 2010 20:22:53 -0700 Subject: Backed out changeset 28f52b3d2e3d (optimizations in button rendering). --- indra/llui/llbutton.cpp | 12 +++++------- indra/llui/llbutton.h | 1 - indra/newview/llviewerwindow.cpp | 11 +++++++++++ 3 files changed, 16 insertions(+), 8 deletions(-) diff --git a/indra/llui/llbutton.cpp b/indra/llui/llbutton.cpp index 5a4f0515fc..aeedf62379 100644 --- a/indra/llui/llbutton.cpp +++ b/indra/llui/llbutton.cpp @@ -120,7 +120,6 @@ LLButton::LLButton(const LLButton::Params& p) mFlashing( FALSE ), mCurGlowStrength(0.f), mNeedsHighlight(FALSE), - mMouseOver(false), mUnselectedLabel(p.label()), mSelectedLabel(p.label_selected()), mGLFont(p.font), @@ -505,11 +504,7 @@ void LLButton::onMouseEnter(S32 x, S32 y, MASK mask) LLUICtrl::onMouseEnter(x, y, mask); if (isInEnabledChain()) - { mNeedsHighlight = TRUE; - } - - mMouseOver = true; } void LLButton::onMouseLeave(S32 x, S32 y, MASK mask) @@ -517,7 +512,6 @@ void LLButton::onMouseLeave(S32 x, S32 y, MASK mask) LLUICtrl::onMouseLeave(x, y, mask); mNeedsHighlight = FALSE; - mMouseOver = true; } void LLButton::setHighlight(bool b) @@ -571,10 +565,14 @@ void LLButton::draw() } // Unselected image assignments + S32 local_mouse_x; + S32 local_mouse_y; + LLUI::getMousePositionLocal(this, &local_mouse_x, &local_mouse_y); + bool enabled = isInEnabledChain(); bool pressed = pressed_by_keyboard - || (hasMouseCapture() && mMouseOver) + || (hasMouseCapture() && pointInView(local_mouse_x, local_mouse_y)) || mForcePressedState; bool selected = getToggleState(); diff --git a/indra/llui/llbutton.h b/indra/llui/llbutton.h index 5f25084b35..f4af19b696 100644 --- a/indra/llui/llbutton.h +++ b/indra/llui/llbutton.h @@ -356,7 +356,6 @@ private: BOOL mCommitOnReturn; BOOL mFadeWhenDisabled; bool mForcePressedState; - bool mMouseOver; LLFrameTimer mFlashingTimer; }; diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index b36af7d95b..00873a797c 100644 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -2482,6 +2482,17 @@ void LLViewerWindow::updateUI() // only update mouse hover set when UI is visible (since we shouldn't send hover events to invisible UI if (gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_UI)) { + // include all ancestors of captor_view as automatically having mouse + if (captor_view) + { + LLView* captor_parent_view = captor_view->getParent(); + while(captor_parent_view) + { + mouse_hover_set.insert(captor_parent_view->getHandle()); + captor_parent_view = captor_parent_view->getParent(); + } + } + // aggregate visible views that contain mouse cursor in display order LLPopupView::popup_list_t popups = mPopupView->getCurrentPopups(); -- cgit v1.2.3 From d0bc4fc5e656b07308fe5fe0dc99ed78c00efd78 Mon Sep 17 00:00:00 2001 From: Richard Linden Date: Thu, 9 Sep 2010 19:07:07 -0700 Subject: DEV-53015 FIX Volume slider disappears when sliding on panel_prim_media_controls.xml --- indra/llui/llbutton.cpp | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/indra/llui/llbutton.cpp b/indra/llui/llbutton.cpp index f014a2a98d..65ef3e5f8f 100644 --- a/indra/llui/llbutton.cpp +++ b/indra/llui/llbutton.cpp @@ -558,15 +558,19 @@ void LLButton::draw() pressed_by_keyboard = gKeyboard->getKeyDown(' ') || (mCommitOnReturn && gKeyboard->getKeyDown(KEY_RETURN)); } - // Unselected image assignments - S32 local_mouse_x; - S32 local_mouse_y; - LLUI::getMousePositionLocal(this, &local_mouse_x, &local_mouse_y); + bool mouse_pressed_and_over = false; + if (hasMouseCapture()) + { + S32 local_mouse_x ; + S32 local_mouse_y; + LLUI::getMousePositionLocal(this, &local_mouse_x, &local_mouse_y); + mouse_pressed_and_over = pointInView(local_mouse_x, local_mouse_y); + } bool enabled = isInEnabledChain(); bool pressed = pressed_by_keyboard - || (hasMouseCapture() && pointInView(local_mouse_x, local_mouse_y)) + || mouse_pressed_and_over || mForcePressedState; bool selected = getToggleState(); -- cgit v1.2.3 From 81ef82840db65fd873b96ed428bbb2684a40ee2a Mon Sep 17 00:00:00 2001 From: Vadim Savchuk Date: Tue, 21 Sep 2010 17:41:53 +0300 Subject: STORM-166 FIXED Memory leak in LLSelectNode constructor. Submitting on behalf of Thickbrick Sleaford. One of the LLSelectNode constructors has a leak where it does "new LLPermisions()" twice, thus leaking the address of the first object created. This constructor is called every time you interact (click, hover, select, possibly other) with an object, once for each prim in the object. Since sizeof(LLPermissions) is 92 bytes, this can be a significant amount after a while. I think this might explain VWR-18528 (leaking LLpemissions instances), at least partially. This was fixed in snowglobe 1.x as part of SNOW-267. --- doc/contributions.txt | 1 + indra/newview/llselectmgr.cpp | 22 ++++++---------------- 2 files changed, 7 insertions(+), 16 deletions(-) diff --git a/doc/contributions.txt b/doc/contributions.txt index d58539dd71..e48924d0f6 100644 --- a/doc/contributions.txt +++ b/doc/contributions.txt @@ -661,6 +661,7 @@ Thickbrick Sleaford SNOW-390 SNOW-421 SNOW-462 + SNOW-635 SNOW-586 SNOW-743 VWR-7109 diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp index fb60b1ece7..9260abb2ac 100644 --- a/indra/newview/llselectmgr.cpp +++ b/indra/newview/llselectmgr.cpp @@ -5058,23 +5058,13 @@ LLSelectNode::LLSelectNode(LLViewerObject* object, BOOL glow) mSilhouetteExists(FALSE), mDuplicated(FALSE), mTESelectMask(0), - mLastTESelected(0) + mLastTESelected(0), + mName(LLStringUtil::null), + mDescription(LLStringUtil::null), + mTouchName(LLStringUtil::null), + mSitName(LLStringUtil::null), + mCreationDate(0) { - mObject = object; - selectAllTEs(FALSE); - mIndividualSelection = FALSE; - mTransient = FALSE; - mValid = FALSE; - mPermissions = new LLPermissions(); - mInventorySerial = 0; - mName = LLStringUtil::null; - mDescription = LLStringUtil::null; - mTouchName = LLStringUtil::null; - mSitName = LLStringUtil::null; - mSilhouetteExists = FALSE; - mDuplicated = FALSE; - mCreationDate = 0; - saveColors(); } -- cgit v1.2.3 From 1df1f822aa4f8633207023ef78f9aa4606649732 Mon Sep 17 00:00:00 2001 From: Seth ProductEngine Date: Fri, 24 Sep 2010 00:53:21 +0300 Subject: STORM-189 FIXED Truncations in DE ans ES locales in Build Tools floater. - Some checkboxes moved in DE locale and EN xml file. - Removed floater width override for ES locale. --- indra/newview/skins/default/xui/de/floater_tools.xml | 4 ++-- indra/newview/skins/default/xui/en/floater_tools.xml | 8 ++++---- indra/newview/skins/default/xui/es/floater_tools.xml | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/indra/newview/skins/default/xui/de/floater_tools.xml b/indra/newview/skins/default/xui/de/floater_tools.xml index 12ae9898c3..3de3718f66 100644 --- a/indra/newview/skins/default/xui/de/floater_tools.xml +++ b/indra/newview/skins/default/xui/de/floater_tools.xml @@ -71,8 +71,8 @@ Beide Seiten dehnen - - + + diff --git a/indra/newview/skins/default/xui/en/floater_tools.xml b/indra/newview/skins/default/xui/en/floater_tools.xml index af8ab3fd9e..cea2ba2c7f 100644 --- a/indra/newview/skins/default/xui/en/floater_tools.xml +++ b/indra/newview/skins/default/xui/en/floater_tools.xml @@ -255,7 +255,7 @@ label="Edit linked" layout="topleft" name="checkbox edit linked parts" - top_pad="0"> + top_pad="2"> @@ -267,7 +267,7 @@ left="13" name="RenderingCost" tool_tip="Shows the rendering cost calculated for this object" - top_pad="2" + top_pad="0" type="string" width="100"> þ: [COUNT] @@ -732,7 +732,7 @@ layout="topleft" right="-10" name="obj_count" - top_pad="5" + top_pad="7" width="143"> Objects: [COUNT] @@ -758,7 +758,7 @@ tab_min_width="40" tab_position="top" tab_height="25" - top="170" + top="173" width="295"> - + Arrastra las bandas de color para girar el objeto. -- cgit v1.2.3 From 3cd522c5a6dd71a61769a65a7e6fa39a55fcf73b Mon Sep 17 00:00:00 2001 From: Xiaohong Bao Date: Wed, 22 Sep 2010 14:44:40 -0600 Subject: fix for SH-173/VWR-22868: Development Viewer freezes just after startup / greedy with file handles / 'WARNING: ll_apr_warn_status: APR: Too many open files' (transplanted from a9aefa70c029eb9dddec3833d0ce22ef4b4421b5) --- indra/newview/lltexturefetch.cpp | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/indra/newview/lltexturefetch.cpp b/indra/newview/lltexturefetch.cpp index 4e9ebce4d1..fafef84aa2 100644 --- a/indra/newview/lltexturefetch.cpp +++ b/indra/newview/lltexturefetch.cpp @@ -847,10 +847,16 @@ bool LLTextureFetchWorker::doWork(S32 param) if(mCanUseHTTP) { //NOTE: - //it seems ok to let sim control the UDP traffic - //so there is no throttle for http here. + //control the number of the http requests issued for: + //1, not openning too many file descriptors at the same time; + //2, control the traffic of http so udp gets bandwidth. // - + static const S32 MAX_NUM_OF_HTTP_REQUESTS_IN_QUEUE = 32 ; + if(mFetcher->getNumHTTPRequests() > MAX_NUM_OF_HTTP_REQUESTS_IN_QUEUE) + { + return false ; //wait. + } + mFetcher->removeFromNetworkQueue(this, false); S32 cur_size = 0; -- cgit v1.2.3 From 4f3339ff99af47e6a21f555489cdc9eb66c5ea06 Mon Sep 17 00:00:00 2001 From: Vadim ProductEngine Date: Wed, 29 Sep 2010 20:43:41 +0300 Subject: STORM-227 FIXED Made long cache location in Preferences->Setup readable. Changes: - The line editor is now scrollable. - Its value is duplicated in the tool-tip. Technical notes: If you set the "enabled" param of a line editor to "false", that will disable text selection in the widget. However, if a line editor is initially enabled and then gets disabled with setEnabled(FALSE), it will remain selectable. It looks like bug, but I'm not going to fix it now to not introduce issues like this one. Instead, I'm applying to workaround which is to enable the widget initially and disable later, thus keeping it read-only but selectable. --- indra/newview/llfloaterpreference.cpp | 11 +++++++++-- indra/newview/llfloaterpreference.h | 2 ++ .../newview/skins/default/xui/en/panel_preferences_setup.xml | 1 - 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp index ff6df548c4..41f85ae29d 100644 --- a/indra/newview/llfloaterpreference.cpp +++ b/indra/newview/llfloaterpreference.cpp @@ -323,8 +323,9 @@ BOOL LLFloaterPreference::postBuild() if (!tabcontainer->selectTab(gSavedSettings.getS32("LastPrefTab"))) tabcontainer->selectFirstTab(); + getChild("cache_location")->setEnabled(FALSE); // make it read-only but selectable (STORM-227) std::string cache_location = gDirUtilp->getExpandedFilename(LL_PATH_CACHE, ""); - getChild("cache_location")->setValue(cache_location); + setCacheLocation(cache_location); // if floater is opened before login set default localized busy message if (LLStartUp::getStartupState() < STATE_STARTED) @@ -414,7 +415,7 @@ void LLFloaterPreference::apply() fov_slider->setMaxValue(LLViewerCamera::getInstance()->getMaxView()); std::string cache_location = gDirUtilp->getExpandedFilename(LL_PATH_CACHE, ""); - getChild("cache_location")->setValue(cache_location); + setCacheLocation(cache_location); LLViewerMedia::setCookiesEnabled(getChild("cookies_enabled")->getValue()); @@ -1310,6 +1311,12 @@ void LLFloaterPreference::getUIColor(LLUICtrl* ctrl, const LLSD& param) color_swatch->setOriginal(LLUIColorTable::instance().getColor(param.asString())); } +void LLFloaterPreference::setCacheLocation(const LLStringExplicit& location) +{ + LLUICtrl* cache_location_editor = getChild("cache_location"); + cache_location_editor->setValue(location); + cache_location_editor->setToolTip(location); +} //---------------------------------------------------------------------------- static LLRegisterPanelClassWrapper t_places("panel_preference"); diff --git a/indra/newview/llfloaterpreference.h b/indra/newview/llfloaterpreference.h index d1e15d5ab8..e99731b92e 100644 --- a/indra/newview/llfloaterpreference.h +++ b/indra/newview/llfloaterpreference.h @@ -103,6 +103,8 @@ protected: public: + void setCacheLocation(const LLStringExplicit& location); + void onClickSetCache(); void onClickResetCache(); void onClickSkin(LLUICtrl* ctrl,const LLSD& userdata); diff --git a/indra/newview/skins/default/xui/en/panel_preferences_setup.xml b/indra/newview/skins/default/xui/en/panel_preferences_setup.xml index 879781f746..140d16e37f 100644 --- a/indra/newview/skins/default/xui/en/panel_preferences_setup.xml +++ b/indra/newview/skins/default/xui/en/panel_preferences_setup.xml @@ -195,7 +195,6 @@ control_name="CacheLocationTopFolder" border_style="line" border_thickness="1" - enabled="false" follows="left|top" font="SansSerif" height="23" -- cgit v1.2.3 From 62a46df736cf88d7a2ad4bd55e285e4026328eb9 Mon Sep 17 00:00:00 2001 From: Seth ProductEngine Date: Wed, 29 Sep 2010 21:44:30 +0300 Subject: STORM-269 FIXED Added strings for missing land types in strings.xml If localized land type name is not found it is displayed as original string to avoid MissingString error. --- indra/newview/llfloaterland.cpp | 5 ++++- indra/newview/skins/default/xui/en/strings.xml | 2 ++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/indra/newview/llfloaterland.cpp b/indra/newview/llfloaterland.cpp index df0d22561e..e124263db5 100644 --- a/indra/newview/llfloaterland.cpp +++ b/indra/newview/llfloaterland.cpp @@ -565,7 +565,10 @@ void LLPanelLandGeneral::refresh() if (regionp) { insert_maturity_into_textbox(mContentRating, gFloaterView->getParentFloater(this), MATURITY); - mLandType->setText(LLTrans::getString(regionp->getSimProductName())); + + std::string land_type; + bool is_land_type_localized = LLTrans::findString(land_type, regionp->getSimProductName()); + mLandType->setText(is_land_type_localized ? land_type : regionp->getSimProductName()); } // estate owner/manager cannot edit other parts of the parcel diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml index 6b3fd9ff9e..8470d91b8c 100644 --- a/indra/newview/skins/default/xui/en/strings.xml +++ b/indra/newview/skins/default/xui/en/strings.xml @@ -321,6 +321,8 @@ Estate / Full Region + Estate / Homestead + Mainland / Homestead Mainland / Full Region -- cgit v1.2.3 From d3a9d6a6cef6630995c652b4cc04c8807dbe6d4e Mon Sep 17 00:00:00 2001 From: Tofu Linden Date: Fri, 24 Sep 2010 15:44:26 +0100 Subject: trivial indentation changes while I'm poking around here. (transplanted from 01d8534678f5613c924a036128addf6b7447c92a) --- indra/llui/llnotifications.cpp | 8 ++++---- indra/llui/llnotifications.h | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/indra/llui/llnotifications.cpp b/indra/llui/llnotifications.cpp index 67b3c5cfce..30cd85619e 100644 --- a/indra/llui/llnotifications.cpp +++ b/indra/llui/llnotifications.cpp @@ -1060,12 +1060,12 @@ std::string LLNotificationChannel::summarize() // LLNotifications implementation // --- LLNotifications::LLNotifications() : LLNotificationChannelBase(LLNotificationFilters::includeEverything, - LLNotificationComparators::orderByUUID()), - mIgnoreAllNotifications(false) + LLNotificationComparators::orderByUUID()), + mIgnoreAllNotifications(false) { LLUICtrl::CommitCallbackRegistry::currentRegistrar().add("Notification.Show", boost::bind(&LLNotifications::addFromCallback, this, _2)); - - mListener.reset(new LLNotificationsListener(*this)); + + mListener.reset(new LLNotificationsListener(*this)); } diff --git a/indra/llui/llnotifications.h b/indra/llui/llnotifications.h index 4fe1687f0e..f075c44520 100644 --- a/indra/llui/llnotifications.h +++ b/indra/llui/llnotifications.h @@ -504,7 +504,7 @@ public: std::string getLabel() const; std::string getURL() const; S32 getURLOption() const; - S32 getURLOpenExternally() const; + S32 getURLOpenExternally() const; const LLNotificationFormPtr getForm(); -- cgit v1.2.3 From eb932c0e73795dc27c6d31b9962627fd65042666 Mon Sep 17 00:00:00 2001 From: Sergei Litovchuk Date: Mon, 27 Sep 2010 16:03:31 +0300 Subject: STORM-190 FIXED text truncations in floater EDIT CONTENT PERMISSIONS. - Increased overall floater width. - Increased permissions columns width. - Increased 'Check All' and 'Clear' buttons width. - Applied text wrapping to permissions labels. - Removed 'NextOwnerLabel' dimensions overrides for German. - Removed 'Check All' and 'Clear' buttons dimensions overrides for Polish. --- .../skins/default/xui/de/floater_bulk_perms.xml | 2 +- .../skins/default/xui/en/floater_bulk_perms.xml | 37 ++++++++++++---------- .../skins/default/xui/pl/floater_bulk_perms.xml | 4 +-- 3 files changed, 23 insertions(+), 20 deletions(-) diff --git a/indra/newview/skins/default/xui/de/floater_bulk_perms.xml b/indra/newview/skins/default/xui/de/floater_bulk_perms.xml index d3f0d6d78f..8f99fc933c 100644 --- a/indra/newview/skins/default/xui/de/floater_bulk_perms.xml +++ b/indra/newview/skins/default/xui/de/floater_bulk_perms.xml @@ -43,7 +43,7 @@ Jeder: - + Nächster Eigentümer: diff --git a/indra/newview/skins/default/xui/en/floater_bulk_perms.xml b/indra/newview/skins/default/xui/en/floater_bulk_perms.xml index d007ceff98..457142f11c 100644 --- a/indra/newview/skins/default/xui/en/floater_bulk_perms.xml +++ b/indra/newview/skins/default/xui/en/floater_bulk_perms.xml @@ -7,7 +7,7 @@ name="floaterbulkperms" help_topic="floaterbulkperms" title="EDIT CONTENT PERMISSIONS" - width="270"> + width="300"> Selection contains no editable contents. @@ -164,7 +164,7 @@ label="√ All" left="180" top="26" - width="70"> + width="115"> @@ -176,7 +176,7 @@ layout="topleft" top_pad="8" name="check_none" - width="70" > + width="115" > @@ -199,10 +199,11 @@ length="1" follows="left|top" layout="topleft" - height="16" + height="28" left="10" name="GroupLabel" - width="88"> + width="92" + word_wrap="true"> Group: + width="92" /> + width="92" + word_wrap="true"> Anyone: + width="92" /> + left="189" + width="92" + word_wrap="true"> Next owner: + width="92" /> + width="92"> @@ -274,7 +277,7 @@ layout="topleft" name="next_owner_transfer" tool_tip="Next owner can give away or resell this object" - width="106" /> + width="92" /> diff --git a/indra/newview/skins/default/xui/pl/floater_bulk_perms.xml b/indra/newview/skins/default/xui/pl/floater_bulk_perms.xml index 0f49061002..1c24e0b35e 100644 --- a/indra/newview/skins/default/xui/pl/floater_bulk_perms.xml +++ b/indra/newview/skins/default/xui/pl/floater_bulk_perms.xml @@ -30,8 +30,8 @@ -