diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2017-05-04 17:16:12 -0400 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2017-05-04 17:16:12 -0400 |
commit | a4467e9ffe9dc378451d7bb6b8c70f6c0c42a814 (patch) | |
tree | c6a918a0a3a0d7e1117ca71bfc966e3d6cd4b5ea /indra/newview | |
parent | 1f2fcc12980dd21659bce493431b7a1b3fe2ef00 (diff) | |
parent | 07ec10781e45b3d92e27e92ddad39cf74fa7ff0b (diff) |
Automated merge with ssh://bitbucket.org/lindenlab/viewer64-c-11
Diffstat (limited to 'indra/newview')
172 files changed, 2948 insertions, 865 deletions
diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt index c4ded8c5ae..62451e4856 100644 --- a/indra/newview/CMakeLists.txt +++ b/indra/newview/CMakeLists.txt @@ -202,6 +202,7 @@ set(viewer_SOURCE_FILES llfloaterautoreplacesettings.cpp llfloateravatar.cpp llfloateravatarpicker.cpp + llfloateravatarrendersettings.cpp llfloateravatartextures.cpp llfloaterbeacons.cpp llfloaterbigpreview.cpp @@ -235,6 +236,7 @@ set(viewer_SOURCE_FILES llfloatergesture.cpp llfloatergodtools.cpp llfloatergotoline.cpp + llfloatergridstatus.cpp llfloatergroupbulkban.cpp llfloatergroupinvite.cpp llfloatergroups.cpp @@ -818,6 +820,7 @@ set(viewer_HEADER_FILES llfloaterautoreplacesettings.h llfloateravatar.h llfloateravatarpicker.h + llfloateravatarrendersettings.h llfloateravatartextures.h llfloaterbeacons.h llfloaterbigpreview.h @@ -851,6 +854,7 @@ set(viewer_HEADER_FILES llfloatergesture.h llfloatergodtools.h llfloatergotoline.h + llfloatergridstatus.h llfloatergroupbulkban.h llfloatergroupinvite.h llfloatergroups.h @@ -1745,6 +1749,7 @@ if (WINDOWS) SLPlugin media_plugin_cef media_plugin_libvlc + media_plugin_example winmm_shim windows-crash-logger ) diff --git a/indra/newview/app_settings/commands.xml b/indra/newview/app_settings/commands.xml index 9bc0a7c701..412d3a53b3 100644 --- a/indra/newview/app_settings/commands.xml +++ b/indra/newview/app_settings/commands.xml @@ -292,4 +292,15 @@ is_running_function="Floater.IsOpen" is_running_parameters="reporter" /> + <command name="gridstatus" + available_in_toybox="true" + is_flashing_allowed="true" + icon="Command_Grid_Status_Icon" + label_ref="Command_Grid_Status_Label" + tooltip_ref="Command_Grid_Status_Tooltip" + execute_function="Floater.ToggleOrBringToFront" + execute_parameters="grid_status" + is_running_function="Floater.IsOpen" + is_running_parameters="grid_status" + /> </commands> diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index 7a897172c2..4a6f30b5a9 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -1608,18 +1608,6 @@ <real>60.0</real> </map> - <key>CameraAspectRatio</key> - <map> - <key>Comment</key> - <string>Camera aspect ratio for DoF effect</string> - <key>Persist</key> - <integer>1</integer> - <key>Type</key> - <string>F32</string> - <key>Value</key> - <real>1.5</real> - </map> - <key>CertStore</key> <map> <key>Comment</key> @@ -5175,6 +5163,39 @@ <key>Value</key> <string>http://wiki.secondlife.com/wiki/[LSL_STRING]</string> </map> + <key>GridStatusRSS</key> + <map> + <key>Comment</key> + <string>URL that points to SL Grid Status RSS</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string>https://secondlife-status.statuspage.io/history.atom</string> + </map> + <key>GridStatusUpdateDelay</key> + <map> + <key>Comment</key> + <string>Timer delay for updating Grid Status RSS.</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>F32</string> + <key>Value</key> + <real>60.0</real> + </map> + <key>TestGridStatusRSSFromFile</key> + <map> + <key>Comment</key> + <string>For testing only: Don't update rss xml file from server.</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> <key>LagMeterShrunk</key> <map> <key>Comment</key> @@ -5388,7 +5409,7 @@ <key>LeftClickShowMenu</key> <map> <key>Comment</key> - <string>Left click opens pie menu (FALSE = left click touches or grabs object)</string> + <string>Unused obsolete setting</string> <key>Persist</key> <integer>1</integer> <key>Type</key> @@ -8394,6 +8415,17 @@ <key>Value</key> <integer>1</integer> </map> + <key>AlwaysRenderFriends</key> + <map> + <key>Comment</key> + <string>Always render friends regardless of max complexity</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> <key>RenderAvatar</key> <map> <key>Comment</key> @@ -11813,6 +11845,17 @@ <key>Value</key> <integer>75</integer> </map> + <key>AbuseReportScreenshotDelay</key> + <map> + <key>Comment</key> + <string>Time delay before taking screenshot to avoid UI artifacts.</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>F32</string> + <key>Value</key> + <real>0.3</real> + </map> <key>SpeedTest</key> <map> <key>Comment</key> @@ -14733,6 +14776,7 @@ <string>snapshot</string> <string>postcard</string> <string>mini_map</string> + <string>beacons</string> </array> </map> <key>LandmarksSortedByDate</key> @@ -15114,6 +15158,22 @@ <integer>0</integer> </array> </map> + <key>GridStatusFloaterRect</key> + <map> + <key>Comment</key> + <string>Web profile floater dimensions</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Rect</string> + <key>Value</key> + <array> + <integer>0</integer> + <integer>520</integer> + <integer>625</integer> + <integer>0</integer> + </array> + </map> <key>HelpFloaterOpen</key> <map> <key>Comment</key> diff --git a/indra/newview/app_settings/settings_per_account.xml b/indra/newview/app_settings/settings_per_account.xml index eee13fb28e..92e61d2e86 100644 --- a/indra/newview/app_settings/settings_per_account.xml +++ b/indra/newview/app_settings/settings_per_account.xml @@ -348,5 +348,49 @@ <key>Value</key> <integer>1</integer> </map> + <key>ModelUploadFolder</key> + <map> + <key>Comment</key> + <string>All model uploads will be stored in this directory (UUID)</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string></string> + </map> + <key>TextureUploadFolder</key> + <map> + <key>Comment</key> + <string>All image(texture) uploads will be stored in this directory (UUID)</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string></string> + </map> + <key>SoundUploadFolder</key> + <map> + <key>Comment</key> + <string>All sound uploads will be stored in this directory (UUID)</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string></string> + </map> + <key>AnimationUploadFolder</key> + <map> + <key>Comment</key> + <string>All animation uploads will be stored in this directory (UUID)</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string></string> + </map> </map> </llsd> diff --git a/indra/newview/installers/windows/installer_template.nsi b/indra/newview/installers/windows/installer_template.nsi index 89317f2793..71a33a0dc0 100644 --- a/indra/newview/installers/windows/installer_template.nsi +++ b/indra/newview/installers/windows/installer_template.nsi @@ -90,8 +90,11 @@ InstProgressFlags smooth colored # New colored smooth look SetOverwrite on # Overwrite files by default
AutoCloseWindow true # After all files install, close window
-InstallDir "$PROGRAMFILES\${INSTNAME}"
-InstallDirRegKey HKEY_LOCAL_MACHINE "SOFTWARE\Linden Research, Inc.\${INSTNAME}" ""
+# initial location of install (default when not already installed)
+# note: Now we defer looking for existing install until onInit when we
+# are able to engage the 32/64 registry function
+InstallDir "%%PROGRAMFILES%%\${INSTNAME}"
+
UninstallText $(UninstallTextMsg)
DirText $(DirectoryChooseTitle) $(DirectoryChooseSetup)
Page directory dirPre
@@ -118,6 +121,8 @@ Var DO_UNINSTALL_V2 # If non-null, path to a previous Viewer 2 installation !insertmacro GetParameters
!insertmacro GetOptions
!include WinVer.nsh # For OS and SP detection
+!include 'LogicLib.nsh' # for value comparison
+!include "x64.nsh" # for 64bit detection
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Pre-directory page callback
@@ -136,6 +141,21 @@ FunctionEnd ;; entry to the language ID selector below
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Function .onInit
+
+%%ENGAGEREGISTRY%%
+
+# read the current location of the install for this version
+# if $0 is empty, this is the first time for this viewer name
+ReadRegStr $0 HKEY_LOCAL_MACHINE "SOFTWARE\\Linden Research, Inc.\\${INSTNAME}" ""
+
+# viewer with this name not installed before
+${If} $0 == ""
+ # nothing to do here
+${Else}
+ # use the value we got from registry as install location
+ StrCpy $INSTDIR $0
+${EndIf}
+
Call CheckCPUFlags # Make sure we have SSE2 support
Call CheckWindowsVersion # Don't install On unsupported systems
Push $0
@@ -194,6 +214,9 @@ FunctionEnd ;; Prep Uninstaller Section
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Function un.onInit
+
+%%ENGAGEREGISTRY%%
+
# Read language from registry and set for uninstaller. Key will be removed on successful uninstall
ReadRegStr $0 HKEY_LOCAL_MACHINE "SOFTWARE\Linden Research, Inc.\${INSTNAME}" "InstallerLanguage"
IfErrors lbl_end
@@ -318,6 +341,10 @@ WriteRegStr HKEY_LOCAL_MACHINE "Software\Microsoft\Windows\CurrentVersion\Uninst WriteRegStr HKEY_LOCAL_MACHINE "Software\Microsoft\Windows\CurrentVersion\Uninstall\$INSTPROG" "UninstallString" '"$INSTDIR\uninst.exe"'
WriteRegStr HKEY_LOCAL_MACHINE "Software\Microsoft\Windows\CurrentVersion\Uninstall\$INSTPROG" "DisplayVersion" "${VERSION_LONG}"
WriteRegDWORD HKEY_LOCAL_MACHINE "Software\Microsoft\Windows\CurrentVersion\Uninstall\$INSTPROG" "EstimatedSize" "0x0001D500" # ~117 MB
+
+# from FS:Ansariel
+WriteRegStr HKEY_LOCAL_MACHINE "Software\Microsoft\Windows\CurrentVersion\Uninstall\$INSTPROG" "DisplayIcon" '"$INSTDIR\$INSTEXE"'
+
# BUG-2707 Disable SEHOP for installed viewer.
WriteRegDWORD HKEY_LOCAL_MACHINE "Software\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\$INSTEXE" "DisableExceptionChainValidation" 1
@@ -559,7 +586,7 @@ FunctionEnd Function RemoveProgFilesOnInst
# Remove old SecondLife.exe to invalidate any old shortcuts to it that may be in non-standard locations. See MAINT-3575
-Delete "$INSTDIR\SecondLife.exe"
+Delete "$INSTDIR\$INSTEXE"
# Remove old shader files first so fallbacks will work. See DEV-5663
RMDir /r "$INSTDIR\app_settings\shaders"
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp index cfb09d329b..7d0d39e22a 100644 --- a/indra/newview/llagent.cpp +++ b/indra/newview/llagent.cpp @@ -2050,7 +2050,10 @@ void LLAgent::endAnimationUpdateUI() { skip_list.insert(LLFloaterReg::findInstance("mini_map")); } - + if (LLFloaterReg::findInstance("beacons")) + { + skip_list.insert(LLFloaterReg::findInstance("beacons")); + } LLFloaterIMContainer* im_box = LLFloaterReg::getTypedInstance<LLFloaterIMContainer>("im_container"); LLFloaterIMContainer::floater_list_t conversations; im_box->getDetachedConversationFloaters(conversations); @@ -2172,6 +2175,7 @@ void LLAgent::endAnimationUpdateUI() #else // Use this for now LLFloaterView::skip_list_t skip_list; skip_list.insert(LLFloaterReg::findInstance("mini_map")); + skip_list.insert(LLFloaterReg::findInstance("beacons")); gFloaterView->pushVisibleAll(FALSE, skip_list); #endif diff --git a/indra/newview/llagentcamera.cpp b/indra/newview/llagentcamera.cpp index e335eabd1a..5b9f1b9d4f 100644 --- a/indra/newview/llagentcamera.cpp +++ b/indra/newview/llagentcamera.cpp @@ -1537,6 +1537,14 @@ LLVector3d LLAgentCamera::calcFocusPositionTargetGlobal() } else if (mCameraMode == CAMERA_MODE_CUSTOMIZE_AVATAR) { + if (mFocusOnAvatar) + { + LLVector3 focus_target = isAgentAvatarValid() + ? gAgentAvatarp->mHeadp->getWorldPosition() + : gAgent.getPositionAgent(); + LLVector3d focus_target_global = gAgent.getPosGlobalFromAgent(focus_target); + mFocusTargetGlobal = focus_target_global; + } return mFocusTargetGlobal; } else if (!mFocusOnAvatar) diff --git a/indra/newview/llappearancemgr.cpp b/indra/newview/llappearancemgr.cpp index fc4be98fbd..feb981217d 100644 --- a/indra/newview/llappearancemgr.cpp +++ b/indra/newview/llappearancemgr.cpp @@ -1227,11 +1227,12 @@ void LLWearableHoldingPattern::onWearableAssetFetch(LLViewerWearable *wearable) return; } + U32 use_count = 0; for (LLWearableHoldingPattern::found_list_t::iterator iter = getFoundList().begin(); - iter != getFoundList().end(); ++iter) + iter != getFoundList().end(); ++iter) { LLFoundData& data = *iter; - if(wearable->getAssetID() == data.mAssetID) + if (wearable->getAssetID() == data.mAssetID) { // Failing this means inventory or asset server are corrupted in a way we don't handle. if ((data.mWearableType >= LLWearableType::WT_COUNT) || (wearable->getType() != data.mWearableType)) @@ -1240,9 +1241,48 @@ void LLWearableHoldingPattern::onWearableAssetFetch(LLViewerWearable *wearable) break; } - data.mWearable = wearable; + if (use_count == 0) + { + data.mWearable = wearable; + use_count++; + } + else + { + LLViewerInventoryItem* wearable_item = gInventory.getItem(data.mItemID); + if (wearable_item && wearable_item->isFinished() && wearable_item->getPermissions().allowModifyBy(gAgentID)) + { + // We can't edit and do some other interactions with same asset twice, copy it + // Note: can't update incomplete items. Usually attached from previous viewer build, but + // consider adding fetch and completion callback + LLViewerWearable* new_wearable = LLWearableList::instance().createCopy(wearable, wearable->getName()); + data.mWearable = new_wearable; + data.mAssetID = new_wearable->getAssetID(); + + // Update existing inventory item + wearable_item->setAssetUUID(new_wearable->getAssetID()); + wearable_item->setTransactionID(new_wearable->getTransactionID()); + gInventory.updateItem(wearable_item, LLInventoryObserver::INTERNAL); + wearable_item->updateServer(FALSE); + + use_count++; + } + else + { + // Note: technically a bug, LLViewerWearable can identify only one item id at a time, + // yet we are tying it to multiple items here. + // LLViewerWearable need to support more then one item. + LL_WARNS() << "Same LLViewerWearable is used by multiple items! " << wearable->getAssetID() << LL_ENDL; + data.mWearable = wearable; + } + } } } + + if (use_count > 1) + { + LL_WARNS() << "Copying wearable, multiple asset id uses! " << wearable->getAssetID() << LL_ENDL; + gInventory.notifyObservers(); + } } static void onWearableAssetFetch(LLViewerWearable* wearable, void* data) diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index ed86145e10..a26ee2204b 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -125,10 +125,8 @@ #include "llcoros.h" #include "llexception.h" #if !LL_LINUX -#include "cef/llceflib.h" -#if LL_WINDOWS +#include "cef/dullahan.h" #include "vlc/libvlc_version.h" -#endif // LL_WINDOWS #endif // LL_LINUX // Third party library includes @@ -334,10 +332,10 @@ BOOL gDisconnected = FALSE; // used to restore texture state after a mode switch LLFrameTimer gRestoreGLTimer; BOOL gRestoreGL = FALSE; -BOOL gUseWireframe = FALSE; +bool gUseWireframe = FALSE; //use for remember deferred mode in wireframe switch -BOOL gInitialDeferredModeForWireframe = FALSE; +bool gInitialDeferredModeForWireframe = FALSE; // VFS globals - see llappviewer.h LLVFS* gStaticVFS = NULL; @@ -740,10 +738,7 @@ LLAppViewer::LLAppViewer() LLAppViewer::~LLAppViewer() { delete mSettingsLocationList; - LLViewerEventRecorder::deleteSingleton(); - LLLoginInstance::instance().setUpdaterService(0); - destroyMainloopTimeout(); // If we got to this destructor somehow, the app didn't hang. @@ -1104,7 +1099,7 @@ bool LLAppViewer::init() minSpecs += "\n"; unsupported = true; } - if(gSysMemory.getPhysicalMemoryClamped() < minRAM) + if(gSysMemory.getPhysicalMemoryKB() < minRAM) { minSpecs += LLNotifications::instance().getGlobalString("UnsupportedRAM"); minSpecs += "\n"; @@ -1235,7 +1230,8 @@ bool LLAppViewer::init() boost::bind(&LLControlGroup::getU32, boost::ref(gSavedSettings), _1), boost::bind(&LLControlGroup::declareU32, boost::ref(gSavedSettings), _1, _2, _3, LLControlVariable::PERSIST_ALWAYS)); - showReleaseNotesIfRequired(); + // TODO: consider moving proxy initialization here or LLCopocedureManager after proxy initialization, may be implement + // some other protection to make sure we don't use network before initializng proxy /*----------------------------------------------------------------------*/ // nat 2016-06-29 moved the following here from the former mainLoop(). @@ -1489,11 +1485,9 @@ bool LLAppViewer::frame() ms_sleep(500); } - const F64Milliseconds max_idle_time = llmin(.005f*10.f*(F32Milliseconds)gFrameTimeSeconds, F32Milliseconds(5)); // 5 ms a second idleTimer.reset(); S32 total_work_pending = 0; S32 total_io_pending = 0; - while(1) { S32 work_pending = 0; S32 io_pending = 0; @@ -1517,11 +1511,7 @@ bool LLAppViewer::frame() total_work_pending += work_pending ; total_io_pending += io_pending ; - - if (!work_pending || idleTimer.getElapsedTimeF64() >= max_idle_time) - { - break; - } + } gMeshRepo.update() ; @@ -2117,20 +2107,15 @@ bool LLAppViewer::cleanup() // realtime, or might throw an exception. LLSingletonBase::cleanupAll(); + // The logging subsystem depends on an LLSingleton. Any logging after + // LLSingletonBase::deleteAll() won't be recorded. + LL_INFOS() << "Goodbye!" << LL_ENDL; + // This calls every remaining LLSingleton's deleteSingleton() method. // No class destructor should perform any cleanup that might take // significant realtime, or throw an exception. - // LLSingleton machinery includes a last-gasp implicit deleteAll() call, - // so this explicit call shouldn't strictly be necessary. However, by the - // time the runtime engages that implicit call, it may already have - // destroyed things like std::cerr -- so the implicit deleteAll() refrains - // from logging anything. Since both cleanupAll() and deleteAll() call - // their respective cleanup methods in computed dependency order, it's - // probably useful to be able to log that order. LLSingletonBase::deleteAll(); - LL_INFOS() << "Goodbye!" << LL_ENDL; - removeDumpDir(); // return 0; @@ -3119,7 +3104,12 @@ void LLAppViewer::initUpdater() mUpdater->setAppExitCallback(boost::bind(&LLAppViewer::forceQuit, this)); mUpdater->initialize(channel, version, +// DRTVWR-418 transitional: query using "win64" until VMP is in place +#if LL_WINDOWS && (ADDRESS_SIZE == 64) + "win64", +#else gPlatform, +#endif getOSInfo().getOSVersionString(), unique_id, willing_to_test @@ -3318,7 +3308,12 @@ LLSD LLAppViewer::getViewerInfo() const std::string url = LLTrans::getString("RELEASE_NOTES_BASE_URL"); if (! LLStringUtil::endsWith(url, "/")) url += "/"; - url += LLURI::escape(LLVersionInfo::getChannel()) + "/"; + std::string channel = LLVersionInfo::getChannel(); + if (LLStringUtil::endsWith(boost::to_lower_copy(channel), " edu")) // Release Notes url shouldn't include the EDU parameter + { + boost::erase_tail(channel, 4); + } + url += LLURI::escape(channel) + "/"; url += LLURI::escape(LLVersionInfo::getVersion()); info["VIEWER_RELEASE_NOTES_URL"] = url; @@ -3393,20 +3388,33 @@ LLSD LLAppViewer::getViewerInfo() const } #if !LL_LINUX - info["LLCEFLIB_VERSION"] = LLCEFLIB_VERSION; -#else - info["LLCEFLIB_VERSION"] = "Undefined"; + std::ostringstream cef_ver_codec; + cef_ver_codec << "Dullahan: "; + cef_ver_codec << DULLAHAN_VERSION_MAJOR; + cef_ver_codec << "."; + cef_ver_codec << DULLAHAN_VERSION_MINOR; + cef_ver_codec << "."; + cef_ver_codec << DULLAHAN_VERSION_BUILD; + + cef_ver_codec << " / CEF: "; + cef_ver_codec << CEF_VERSION; + cef_ver_codec << " / Chrome: "; + cef_ver_codec << CHROME_VERSION_MAJOR; + + info["LIBCEF_VERSION"] = cef_ver_codec.str(); +#else + info["LIBCEF_VERSION"] = "Undefined"; #endif -#if LL_WINDOWS - std::ostringstream ver_codec; - ver_codec << LIBVLC_VERSION_MAJOR; - ver_codec << "."; - ver_codec << LIBVLC_VERSION_MINOR; - ver_codec << "."; - ver_codec << LIBVLC_VERSION_REVISION; - info["LIBVLC_VERSION"] = ver_codec.str(); +#if !LL_LINUX + std::ostringstream vlc_ver_codec; + vlc_ver_codec << LIBVLC_VERSION_MAJOR; + vlc_ver_codec << "."; + vlc_ver_codec << LIBVLC_VERSION_MINOR; + vlc_ver_codec << "."; + vlc_ver_codec << LIBVLC_VERSION_REVISION; + info["LIBVLC_VERSION"] = vlc_ver_codec.str(); #else info["LIBVLC_VERSION"] = "Undefined"; #endif @@ -3733,11 +3741,10 @@ void LLAppViewer::handleViewerCrash() { gDebugInfo["Dynamic"]["ParcelMediaURL"] = parcel->getMediaURL(); } - - + gDebugInfo["Dynamic"]["SessionLength"] = F32(LLFrameTimer::getElapsedSeconds()); - gDebugInfo["Dynamic"]["RAMInfo"]["Allocated"] = (LLSD::Integer) LLMemory::getCurrentRSS() >> 10; - + gDebugInfo["Dynamic"]["RAMInfo"]["Allocated"] = LLSD::Integer(LLMemory::getCurrentRSS() / 1024); + if(gLogoutInProgress) { gDebugInfo["Dynamic"]["LastExecEvent"] = LAST_EXEC_LOGOUT_CRASH; @@ -5593,6 +5600,8 @@ void LLAppViewer::forceErrorBreakpoint() LL_WARNS() << "Forcing a deliberate breakpoint" << LL_ENDL; #ifdef LL_WINDOWS DebugBreak(); +#else + asm ("int $3"); #endif return; } @@ -5870,21 +5879,6 @@ void LLAppViewer::launchUpdater() // LLAppViewer::instance()->forceQuit(); } -/** -* Check if user is running a new version of the viewer. -* Display the Release Notes if it's not overriden by the "UpdaterShowReleaseNotes" setting. -*/ -void LLAppViewer::showReleaseNotesIfRequired() -{ - if (LLVersionInfo::getChannelAndVersion() != gLastRunVersion - && gSavedSettings.getBOOL("UpdaterShowReleaseNotes") - && !gSavedSettings.getBOOL("FirstLoginThisInstall")) - { - LLSD info(getViewerInfo()); - LLWeb::loadURLInternal(info["VIEWER_RELEASE_NOTES_URL"]); - } -} - //virtual void LLAppViewer::setMasterSystemAudioMute(bool mute) { diff --git a/indra/newview/llappviewer.h b/indra/newview/llappviewer.h index 948d316009..16a00c8cee 100644 --- a/indra/newview/llappviewer.h +++ b/indra/newview/llappviewer.h @@ -255,8 +255,6 @@ private: void sendLogoutRequest(); void disconnectViewer(); - void showReleaseNotesIfRequired(); - // *FIX: the app viewer class should be some sort of singleton, no? // Perhaps its child class is the singleton and this should be an abstract base. static LLAppViewer* sInstance; @@ -391,8 +389,8 @@ extern BOOL gDisconnected; extern LLFrameTimer gRestoreGLTimer; extern BOOL gRestoreGL; -extern BOOL gUseWireframe; -extern BOOL gInitialDeferredModeForWireframe; +extern bool gUseWireframe; +extern bool gInitialDeferredModeForWireframe; // VFS globals - gVFS is for general use // gStaticVFS is read-only and is shipped w/ the viewer diff --git a/indra/newview/llappviewerwin32.cpp b/indra/newview/llappviewerwin32.cpp index 5107030476..d6039f6d7f 100644 --- a/indra/newview/llappviewerwin32.cpp +++ b/indra/newview/llappviewerwin32.cpp @@ -502,7 +502,8 @@ bool LLAppViewerWin32::init() disableWinErrorReporting(); #ifndef LL_RELEASE_FOR_DOWNLOAD - LLWinDebug::instance().init(); + // Merely requesting the LLSingleton instance initializes it. + LLWinDebug::instance(); #endif #if LL_WINDOWS @@ -526,10 +527,6 @@ bool LLAppViewerWin32::cleanup() gDXHardware.cleanup(); -#ifndef LL_RELEASE_FOR_DOWNLOAD - LLWinDebug::instance().cleanup(); -#endif - if (mIsConsoleAllocated) { FreeConsole(); diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index 36e95c07f4..2045c3e297 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -478,15 +478,14 @@ void LLAvatarActions::kick(const LLUUID& id) // static void LLAvatarActions::freezeAvatar(const LLUUID& id) { - std::string fullname; - gCacheName->getFullName(id, fullname); + LLAvatarName av_name; LLSD payload; payload["avatar_id"] = id; - if (!fullname.empty()) + if (LLAvatarNameCache::get(id, &av_name)) { LLSD args; - args["AVATAR_NAME"] = fullname; + args["AVATAR_NAME"] = av_name.getUserName(); LLNotificationsUtil::add("FreezeAvatarFullname", args, payload, handleFreezeAvatar); } else @@ -498,15 +497,15 @@ void LLAvatarActions::freezeAvatar(const LLUUID& id) // static void LLAvatarActions::ejectAvatar(const LLUUID& id, bool ban_enabled) { - std::string fullname; - gCacheName->getFullName(id, fullname); + LLAvatarName av_name; LLSD payload; payload["avatar_id"] = id; payload["ban_enabled"] = ban_enabled; LLSD args; - if (!fullname.empty()) + bool has_name = LLAvatarNameCache::get(id, &av_name); + if (has_name) { - args["AVATAR_NAME"] = fullname; + args["AVATAR_NAME"] = av_name.getUserName(); } if (ban_enabled) @@ -515,7 +514,7 @@ void LLAvatarActions::ejectAvatar(const LLUUID& id, bool ban_enabled) } else { - if (!fullname.empty()) + if (has_name) { LLNotificationsUtil::add("EjectAvatarFullnameNoBan", args, payload, handleEjectAvatar); } @@ -991,10 +990,10 @@ bool LLAvatarActions::canShareSelectedItems(LLInventoryPanel* inv_panel /* = NUL // static void LLAvatarActions::toggleBlock(const LLUUID& id) { - std::string name; + LLAvatarName av_name; + LLAvatarNameCache::get(id, &av_name); - gCacheName->getFullName(id, name); // needed for mute - LLMute mute(id, name, LLMute::AGENT); + LLMute mute(id, av_name.getUserName(), LLMute::AGENT); if (LLMuteList::getInstance()->isMuted(mute.mID, mute.mName)) { @@ -1009,13 +1008,13 @@ void LLAvatarActions::toggleBlock(const LLUUID& id) // static void LLAvatarActions::toggleMuteVoice(const LLUUID& id) { - std::string name; - gCacheName->getFullName(id, name); // needed for mute + LLAvatarName av_name; + LLAvatarNameCache::get(id, &av_name); LLMuteList* mute_list = LLMuteList::getInstance(); bool is_muted = mute_list->isMuted(id, LLMute::flagVoiceChat); - LLMute mute(id, name, LLMute::AGENT); + LLMute mute(id, av_name.getUserName(), LLMute::AGENT); if (!is_muted) { mute_list->add(mute, LLMute::flagVoiceChat); @@ -1329,9 +1328,9 @@ bool LLAvatarActions::isFriend(const LLUUID& id) // static bool LLAvatarActions::isBlocked(const LLUUID& id) { - std::string name; - gCacheName->getFullName(id, name); // needed for mute - return LLMuteList::getInstance()->isMuted(id, name); + LLAvatarName av_name; + LLAvatarNameCache::get(id, &av_name); + return LLMuteList::getInstance()->isMuted(id, av_name.getUserName()); } // static @@ -1343,8 +1342,10 @@ bool LLAvatarActions::isVoiceMuted(const LLUUID& id) // static bool LLAvatarActions::canBlock(const LLUUID& id) { - std::string full_name; - gCacheName->getFullName(id, full_name); // needed for mute + LLAvatarName av_name; + LLAvatarNameCache::get(id, &av_name); + + std::string full_name = av_name.getUserName(); bool is_linden = (full_name.find("Linden") != std::string::npos); bool is_self = id == gAgentID; return !is_self && !is_linden; diff --git a/indra/newview/llblocklist.cpp b/indra/newview/llblocklist.cpp index 272a68bdf7..1eab2d8e23 100644 --- a/indra/newview/llblocklist.cpp +++ b/indra/newview/llblocklist.cpp @@ -55,7 +55,9 @@ LLBlockList::LLBlockList(const Params& p) registrar.add ("Block.Action", boost::bind(&LLBlockList::onCustomAction, this, _2)); enable_registrar.add("Block.Enable", boost::bind(&LLBlockList::isActionEnabled, this, _2)); - + enable_registrar.add("Block.Check", boost::bind(&LLBlockList::isMenuItemChecked, this, _2)); + enable_registrar.add("Block.Visible", boost::bind(&LLBlockList::isMenuItemVisible, this, _2)); + LLToggleableMenu* context_menu = LLUICtrlFactory::getInstance()->createFromFile<LLToggleableMenu>( "menu_people_blocked_gear.xml", gMenuHolder, @@ -128,7 +130,14 @@ BOOL LLBlockList::handleRightMouseDown(S32 x, S32 y, MASK mask) void LLBlockList::removeListItem(const LLMute* mute) { - removeItemByUUID(mute->mID); + if (mute->mID.notNull()) + { + removeItemByUUID(mute->mID); + } + else + { + removeItemByValue(mute->mName); + } } void LLBlockList::hideListItem(LLBlockedListItem* item, bool show) @@ -176,7 +185,14 @@ void LLBlockList::addNewItem(const LLMute* mute) { item->highlightName(mNameFilter); } - addItem(item, item->getUUID(), ADD_BOTTOM); + if (item->getUUID().notNull()) + { + addItem(item, item->getUUID(), ADD_BOTTOM); + } + else + { + addItem(item, item->getName(), ADD_BOTTOM); + } } void LLBlockList::refresh() @@ -184,7 +200,8 @@ void LLBlockList::refresh() bool have_filter = !mNameFilter.empty(); // save selection to restore it after list rebuilt - LLUUID selected = getSelectedUUID(), next_selected; + LLSD selected = getSelectedValue(); + LLSD next_selected; if(mShouldAddAll) // creating list of blockers { @@ -202,14 +219,15 @@ void LLBlockList::refresh() } else if(mActionType == REMOVE) { - if(selected == mute.mID) + if ((mute.mID.notNull() && selected.isUUID() && selected.asUUID() == mute.mID) + || (mute.mID.isNull() && selected.isString() && selected.asString() == mute.mName)) { // we are going to remove currently selected item, so select next item and save the selection to restore it - if (!selectNextItemPair(false, true)) - { - selectNextItemPair(true, true); - } - next_selected = getSelectedUUID(); + if (!selectNextItemPair(false, true)) + { + selectNextItemPair(true, true); + } + next_selected = getSelectedValue(); } removeListItem(&mute); } @@ -235,15 +253,18 @@ void LLBlockList::refresh() } mPrevNameFilter = mNameFilter; - if (getItemPair(selected)) - { - // restore previously selected item - selectItemPair(getItemPair(selected), true); - } - else if (getItemPair(next_selected)) + if (selected.isDefined()) { - // previously selected item was removed, so select next item - selectItemPair(getItemPair(next_selected), true); + if (getItemPair(selected)) + { + // restore previously selected item + selectItemPair(getItemPair(selected), true); + } + else if (next_selected.isDefined() && getItemPair(next_selected)) + { + // previously selected item was removed, so select next item + selectItemPair(getItemPair(next_selected), true); + } } mMuteListSize = LLMuteList::getInstance()->getMutes().size(); @@ -272,7 +293,11 @@ bool LLBlockList::isActionEnabled(const LLSD& userdata) const std::string command_name = userdata.asString(); - if ("profile_item" == command_name) + if ("profile_item" == command_name + || "block_voice" == command_name + || "block_text" == command_name + || "block_particles" == command_name + || "block_obj_sounds" == command_name) { LLBlockedListItem* item = getBlockedItem(); action_enabled = item && (LLMute::AGENT == item->getType()); @@ -314,6 +339,83 @@ void LLBlockList::onCustomAction(const LLSD& userdata) break; } } + else if ("block_voice" == command_name) + { + toggleMute(LLMute::flagVoiceChat); + } + else if ("block_text" == command_name) + { + toggleMute(LLMute::flagTextChat); + } + else if ("block_particles" == command_name) + { + toggleMute(LLMute::flagParticles); + } + else if ("block_obj_sounds" == command_name) + { + toggleMute(LLMute::flagObjectSounds); + } +} + +bool LLBlockList::isMenuItemChecked(const LLSD& userdata) +{ + LLBlockedListItem* item = getBlockedItem(); + if (!item) + { + return false; + } + + const std::string command_name = userdata.asString(); + + if ("block_voice" == command_name) + { + return LLMuteList::getInstance()->isMuted(item->getUUID(), LLMute::flagVoiceChat); + } + else if ("block_text" == command_name) + { + return LLMuteList::getInstance()->isMuted(item->getUUID(), LLMute::flagTextChat); + } + else if ("block_particles" == command_name) + { + return LLMuteList::getInstance()->isMuted(item->getUUID(), LLMute::flagParticles); + } + else if ("block_obj_sounds" == command_name) + { + return LLMuteList::getInstance()->isMuted(item->getUUID(), LLMute::flagObjectSounds); + } + + return false; +} + +bool LLBlockList::isMenuItemVisible(const LLSD& userdata) +{ + LLBlockedListItem* item = getBlockedItem(); + const std::string command_name = userdata.asString(); + + if ("block_voice" == command_name + || "block_text" == command_name + || "block_particles" == command_name + || "block_obj_sounds" == command_name) + { + return item && (LLMute::AGENT == item->getType()); + } + + return false; +} + +void LLBlockList::toggleMute(U32 flags) +{ + LLBlockedListItem* item = getBlockedItem(); + LLMute mute(item->getUUID(), item->getName(), item->getType()); + + if (!LLMuteList::getInstance()->isMuted(item->getUUID(), flags)) + { + LLMuteList::getInstance()->add(mute, flags); + } + else + { + LLMuteList::getInstance()->remove(mute, flags); + } } bool LLBlockListItemComparator::compare(const LLPanel* item1, const LLPanel* item2) const diff --git a/indra/newview/llblocklist.h b/indra/newview/llblocklist.h index 0f7fa41c32..ac0729c610 100644 --- a/indra/newview/llblocklist.h +++ b/indra/newview/llblocklist.h @@ -67,6 +67,8 @@ public: void sortByType(); void refresh(); + U32 getMuteListSize() { return mMuteListSize; } + private: void addNewItem(const LLMute* mute); @@ -77,6 +79,9 @@ private: bool isActionEnabled(const LLSD& userdata); void onCustomAction (const LLSD& userdata); + bool isMenuItemChecked(const LLSD& userdata); + bool isMenuItemVisible(const LLSD& userdata); + void toggleMute(U32 flags); void createList(); BlockListActionType getCurrentMuteListActionType(); diff --git a/indra/newview/llcallingcard.cpp b/indra/newview/llcallingcard.cpp index f79d1aa609..6d20b23e9f 100644 --- a/indra/newview/llcallingcard.cpp +++ b/indra/newview/llcallingcard.cpp @@ -243,7 +243,6 @@ S32 LLAvatarTracker::addBuddyList(const LLAvatarTracker::buddy_map_t& buds) using namespace std; U32 new_buddy_count = 0; - std::string full_name; LLUUID agent_id; for(buddy_map_t::const_iterator itr = buds.begin(); itr != buds.end(); ++itr) { @@ -253,8 +252,11 @@ S32 LLAvatarTracker::addBuddyList(const LLAvatarTracker::buddy_map_t& buds) { ++new_buddy_count; mBuddyInfo[agent_id] = (*itr).second; - // IDEVO: is this necessary? name is unused? - gCacheName->getFullName(agent_id, full_name); + + // pre-request name for notifications? + LLAvatarName av_name; + LLAvatarNameCache::get(agent_id, &av_name); + addChangedMask(LLFriendObserver::ADD, agent_id); LL_DEBUGS() << "Added buddy " << agent_id << ", " << (mBuddyInfo[agent_id]->isOnline() ? "Online" : "Offline") @@ -889,7 +891,9 @@ bool LLCollectMappableBuddies::operator()(const LLUUID& buddy_id, LLRelationship bool LLCollectOnlineBuddies::operator()(const LLUUID& buddy_id, LLRelationship* buddy) { - gCacheName->getFullName(buddy_id, mFullName); + LLAvatarName av_name; + LLAvatarNameCache::get(buddy_id, &av_name); + mFullName = av_name.getUserName(); buddy_map_t::value_type value(buddy_id, mFullName); if(buddy->isOnline()) { diff --git a/indra/newview/llchathistory.cpp b/indra/newview/llchathistory.cpp index 5d2997688f..9798ef3529 100644 --- a/indra/newview/llchathistory.cpp +++ b/indra/newview/llchathistory.cpp @@ -271,9 +271,9 @@ public: void mute(const LLUUID& participant_id, U32 flags) { BOOL is_muted = LLMuteList::getInstance()->isMuted(participant_id, flags); - std::string name; - gCacheName->getFullName(participant_id, name); - LLMute mute(participant_id, name, LLMute::AGENT); + LLAvatarName av_name; + LLAvatarNameCache::get(participant_id, &av_name); + LLMute mute(participant_id, av_name.getUserName(), LLMute::AGENT); if (!is_muted) { diff --git a/indra/newview/llconversationloglist.cpp b/indra/newview/llconversationloglist.cpp index ffc235bdbf..86e23e7c83 100644 --- a/indra/newview/llconversationloglist.cpp +++ b/indra/newview/llconversationloglist.cpp @@ -369,8 +369,13 @@ bool LLConversationLogList::isActionEnabled(const LLSD& userdata) bool is_p2p = LLIMModel::LLIMSession::P2P_SESSION == stype; bool is_group = LLIMModel::LLIMSession::GROUP_SESSION == stype; + bool is_group_member = is_group && gAgent.isInGroup(selected_id, TRUE); - if ("can_im" == command_name || "can_view_profile" == command_name) + if ("can_im" == command_name) + { + return is_p2p || is_group_member; + } + else if ("can_view_profile" == command_name) { return is_p2p || is_group; } @@ -380,7 +385,7 @@ bool LLConversationLogList::isActionEnabled(const LLSD& userdata) } else if ("can_call" == command_name) { - return (is_p2p || is_group) && LLAvatarActions::canCall(); + return (is_p2p || is_group_member) && LLAvatarActions::canCall(); } else if ("add_rem_friend" == command_name || "can_invite_to_group" == command_name || diff --git a/indra/newview/llconversationmodel.cpp b/indra/newview/llconversationmodel.cpp index 328a638f2f..ebbbf23dee 100644 --- a/indra/newview/llconversationmodel.cpp +++ b/indra/newview/llconversationmodel.cpp @@ -602,12 +602,12 @@ bool LLConversationItemParticipant::isVoiceMuted() void LLConversationItemParticipant::muteVoice(bool mute_voice) { - std::string name; - gCacheName->getFullName(mUUID, name); + LLAvatarName av_name; + LLAvatarNameCache::get(mUUID, &av_name); LLMuteList * mute_listp = LLMuteList::getInstance(); - bool voice_already_muted = mute_listp->isMuted(mUUID, name); + bool voice_already_muted = mute_listp->isMuted(mUUID, av_name.getUserName()); - LLMute mute(mUUID, name, LLMute::AGENT); + LLMute mute(mUUID, av_name.getUserName(), LLMute::AGENT); if (voice_already_muted && !mute_voice) { mute_listp->remove(mute); diff --git a/indra/newview/lldrawpoolavatar.cpp b/indra/newview/lldrawpoolavatar.cpp index 499cf76bff..b221221f16 100644 --- a/indra/newview/lldrawpoolavatar.cpp +++ b/indra/newview/lldrawpoolavatar.cpp @@ -2063,7 +2063,9 @@ void LLDrawPoolAvatar::removeRiggedFace(LLFace* facep) } else { - LL_ERRS() << "Face reference data corrupt for rigged type " << i << LL_ENDL; + LL_ERRS() << "Face reference data corrupt for rigged type " << i + << ((mRiggedFace[i].size() <= index) ? "; wrong index (out of bounds)" : (mRiggedFace[i][index] != facep) ? "; wrong face pointer" : "") + << LL_ENDL; } } } diff --git a/indra/newview/llexpandabletextbox.cpp b/indra/newview/llexpandabletextbox.cpp index f0331f20d8..314b859cea 100644 --- a/indra/newview/llexpandabletextbox.cpp +++ b/indra/newview/llexpandabletextbox.cpp @@ -63,10 +63,10 @@ public: { return start_offset; } - /*virtual*/ S32 getNumChars(S32 num_pixels, S32 segment_offset, S32 line_offset, S32 max_chars) const + /*virtual*/ S32 getNumChars(S32 num_pixels, S32 segment_offset, S32 line_offset, S32 max_chars, S32 line_ind) const { // require full line to ourselves - if (line_offset == 0) + if (line_offset == 0) { // print all our text return getEnd() - getStart(); diff --git a/indra/newview/llfeaturemanager.cpp b/indra/newview/llfeaturemanager.cpp index d4ba230feb..ad048f6668 100644 --- a/indra/newview/llfeaturemanager.cpp +++ b/indra/newview/llfeaturemanager.cpp @@ -789,7 +789,7 @@ void LLFeatureManager::applyBaseMasks() maskFeatures(gpustr); // now mask cpu type ones - if (gSysMemory.getPhysicalMemoryClamped() <= U32Megabytes(256)) + if (gSysMemory.getPhysicalMemoryKB() <= U32Megabytes(256)) { maskFeatures("RAM256MB"); } diff --git a/indra/newview/llfilteredwearablelist.cpp b/indra/newview/llfilteredwearablelist.cpp index f2af9b5300..e67a6a2b77 100644 --- a/indra/newview/llfilteredwearablelist.cpp +++ b/indra/newview/llfilteredwearablelist.cpp @@ -37,6 +37,7 @@ LLFilteredWearableListManager::LLFilteredWearableListManager(LLInventoryItemsList* list, LLInventoryCollectFunctor* collector) : mWearableList(list) , mCollector(collector) +, mListStale(true) { llassert(mWearableList); gInventory.addObserver(this); @@ -64,7 +65,16 @@ void LLFilteredWearableListManager::changed(U32 mask) return; } - populateList(); + if (mWearableList->isInVisibleChain() || mWearableList->getForceRefresh()) + { + // Todo: current populateList() is time consuming and changed() is time-sensitive, + // either move from here or optimize + populateList(); + } + else + { + mListStale = true; + } } void LLFilteredWearableListManager::setFilterCollector(LLInventoryCollectFunctor* collector) @@ -73,13 +83,31 @@ void LLFilteredWearableListManager::setFilterCollector(LLInventoryCollectFunctor populateList(); } +void LLFilteredWearableListManager::populateIfNeeded() +{ + if (mListStale) + { + populateList(); + } +} + +LLTrace::BlockTimerStatHandle FTM_MANAGER_LIST_POPULATION("Manager List Population"); + void LLFilteredWearableListManager::populateList() { + LL_RECORD_BLOCK_TIME(FTM_MANAGER_LIST_POPULATION); + LLInventoryModel::cat_array_t cat_array; LLInventoryModel::item_array_t item_array; if(mCollector) { + // Too slow with large inventory! + // Consider refactoring into "request once, append ids on changed()", since + // Inventory observer provides ids of changed items this should be possible, + // but will likely require modifying LLInventoryItemsList to avoid code-repeats. + // Or make something like "gather everything and filter manually on idle" + mListStale = false; gInventory.collectDescendentsIf( gInventory.getRootFolderID(), cat_array, diff --git a/indra/newview/llfilteredwearablelist.h b/indra/newview/llfilteredwearablelist.h index f44ab1466f..197302f41d 100644 --- a/indra/newview/llfilteredwearablelist.h +++ b/indra/newview/llfilteredwearablelist.h @@ -52,9 +52,9 @@ public: void setFilterCollector(LLInventoryCollectFunctor* collector); /** - * Populates wearable list with filtered data. - */ - void populateList(); + * Populates wearable list with filtered data in case there were any updates. + */ + void populateIfNeeded(); /** * Drop operation @@ -62,8 +62,14 @@ public: void holdProgress(); private: + /** + * Populates wearable list with filtered data. + */ + void populateList(); + LLInventoryItemsList* mWearableList; LLInventoryCollectFunctor* mCollector; + bool mListStale; }; #endif //LL_LLFILTEREDWEARABLELIST_H diff --git a/indra/newview/llfloateravatarrendersettings.cpp b/indra/newview/llfloateravatarrendersettings.cpp new file mode 100644 index 0000000000..e7ac3f2737 --- /dev/null +++ b/indra/newview/llfloateravatarrendersettings.cpp @@ -0,0 +1,286 @@ +/** + * @file llfloateravatarrendersettings.cpp + * @brief Shows the list of avatars with non-default rendering settings + * + * $LicenseInfo:firstyear=2009&license=viewerlgpl$ + * Second Life Viewer Source Code + * Copyright (C) 2017, Linden Research, Inc. + * + * 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 "llfloateravatarrendersettings.h" + +#include "llavatarnamecache.h" +#include "llfloateravatarpicker.h" +#include "llfiltereditor.h" +#include "llfloaterreg.h" +#include "llnamelistctrl.h" +#include "llmenugl.h" +#include "llviewerobjectlist.h" +#include "llvoavatar.h" + +class LLSettingsContextMenu : public LLListContextMenu + +{ +public: + LLSettingsContextMenu(LLFloaterAvatarRenderSettings* floater_settings) + : mFloaterSettings(floater_settings) + {} +protected: + LLContextMenu* createMenu() + { + LLUICtrl::CommitCallbackRegistry::ScopedRegistrar registrar; + LLUICtrl::EnableCallbackRegistry::ScopedRegistrar enable_registrar; + registrar.add("Settings.SetRendering", boost::bind(&LLFloaterAvatarRenderSettings::onCustomAction, mFloaterSettings, _2, mUUIDs.front())); + enable_registrar.add("Settings.IsSelected", boost::bind(&LLFloaterAvatarRenderSettings::isActionChecked, mFloaterSettings, _2, mUUIDs.front())); + LLContextMenu* menu = createFromFile("menu_avatar_rendering_settings.xml"); + + return menu; + } + + LLFloaterAvatarRenderSettings* mFloaterSettings; +}; + +class LLAvatarRenderMuteListObserver : public LLMuteListObserver +{ + /* virtual */ void onChange() { LLFloaterAvatarRenderSettings::setNeedsUpdate();} +}; + +static LLAvatarRenderMuteListObserver sAvatarRenderMuteListObserver; + +LLFloaterAvatarRenderSettings::LLFloaterAvatarRenderSettings(const LLSD& key) +: LLFloater(key), + mAvatarSettingsList(NULL), + mNeedsUpdate(false) +{ + mContextMenu = new LLSettingsContextMenu(this); + LLRenderMuteList::getInstance()->addObserver(&sAvatarRenderMuteListObserver); + mCommitCallbackRegistrar.add("Settings.AddNewEntry", boost::bind(&LLFloaterAvatarRenderSettings::onClickAdd, this, _2)); +} + +LLFloaterAvatarRenderSettings::~LLFloaterAvatarRenderSettings() +{ + delete mContextMenu; + LLRenderMuteList::getInstance()->removeObserver(&sAvatarRenderMuteListObserver); +} + +BOOL LLFloaterAvatarRenderSettings::postBuild() +{ + LLFloater::postBuild(); + mAvatarSettingsList = getChild<LLNameListCtrl>("render_settings_list"); + mAvatarSettingsList->setRightMouseDownCallback(boost::bind(&LLFloaterAvatarRenderSettings::onAvatarListRightClick, this, _1, _2, _3)); + this->setVisibleCallback(boost::bind(&LLFloaterAvatarRenderSettings::removePicker, this)); + getChild<LLFilterEditor>("people_filter_input")->setCommitCallback(boost::bind(&LLFloaterAvatarRenderSettings::onFilterEdit, this, _2)); + + return TRUE; +} + +void LLFloaterAvatarRenderSettings::removePicker() +{ + if(mPicker.get()) + { + mPicker.get()->closeFloater(); + } +} + +void LLFloaterAvatarRenderSettings::draw() +{ + if(mNeedsUpdate) + { + updateList(); + mNeedsUpdate = false; + } + + LLFloater::draw(); +} + +void LLFloaterAvatarRenderSettings::onAvatarListRightClick(LLUICtrl* ctrl, S32 x, S32 y) +{ + LLNameListCtrl* list = dynamic_cast<LLNameListCtrl*>(ctrl); + if (!list) return; + list->selectItemAt(x, y, MASK_NONE); + uuid_vec_t selected_uuids; + + if(list->getCurrentID().notNull()) + { + selected_uuids.push_back(list->getCurrentID()); + mContextMenu->show(ctrl, selected_uuids, x, y); + } +} + +void LLFloaterAvatarRenderSettings::onOpen(const LLSD& key) +{ + updateList(); +} + +void LLFloaterAvatarRenderSettings::updateList() +{ + mAvatarSettingsList->deleteAllItems(); + LLAvatarName av_name; + LLNameListCtrl::NameItem item_params; + for (std::map<LLUUID, S32>::iterator iter = LLRenderMuteList::getInstance()->sVisuallyMuteSettingsMap.begin(); iter != LLRenderMuteList::getInstance()->sVisuallyMuteSettingsMap.end(); iter++) + { + item_params.value = iter->first; + LLAvatarNameCache::get(iter->first, &av_name); + if(!isHiddenRow(av_name.getCompleteName())) + { + item_params.columns.add().value(av_name.getCompleteName()).column("name"); + std::string setting = getString(iter->second == 1 ? "av_never_render" : "av_always_render"); + item_params.columns.add().value(setting).column("setting"); + mAvatarSettingsList->addNameItemRow(item_params); + } + } +} + +void LLFloaterAvatarRenderSettings::onFilterEdit(const std::string& search_string) +{ + std::string filter_upper = search_string; + LLStringUtil::toUpper(filter_upper); + if (mNameFilter != filter_upper) + { + mNameFilter = filter_upper; + mNeedsUpdate = true; + } +} + +bool LLFloaterAvatarRenderSettings::isHiddenRow(const std::string& av_name) +{ + if (mNameFilter.empty()) return false; + std::string upper_name = av_name; + LLStringUtil::toUpper(upper_name); + return std::string::npos == upper_name.find(mNameFilter); +} + +static LLVOAvatar* find_avatar(const LLUUID& id) +{ + LLViewerObject *obj = gObjectList.findObject(id); + while (obj && obj->isAttachment()) + { + obj = (LLViewerObject *)obj->getParent(); + } + + if (obj && obj->isAvatar()) + { + return (LLVOAvatar*)obj; + } + else + { + return NULL; + } +} + + +void LLFloaterAvatarRenderSettings::onCustomAction (const LLSD& userdata, const LLUUID& av_id) +{ + const std::string command_name = userdata.asString(); + + S32 new_setting = 0; + if ("default" == command_name) + { + new_setting = S32(LLVOAvatar::AV_RENDER_NORMALLY); + } + else if ("never" == command_name) + { + new_setting = S32(LLVOAvatar::AV_DO_NOT_RENDER); + } + else if ("always" == command_name) + { + new_setting = S32(LLVOAvatar::AV_ALWAYS_RENDER); + } + + LLVOAvatar *avatarp = find_avatar(av_id); + if (avatarp) + { + avatarp->setVisualMuteSettings(LLVOAvatar::VisualMuteSettings(new_setting)); + } + else + { + LLRenderMuteList::getInstance()->saveVisualMuteSetting(av_id, new_setting); + } +} + + +bool LLFloaterAvatarRenderSettings::isActionChecked(const LLSD& userdata, const LLUUID& av_id) +{ + const std::string command_name = userdata.asString(); + + S32 visual_setting = LLRenderMuteList::getInstance()->getSavedVisualMuteSetting(av_id); + if ("default" == command_name) + { + return (visual_setting == S32(LLVOAvatar::AV_RENDER_NORMALLY)); + } + else if ("never" == command_name) + { + return (visual_setting == S32(LLVOAvatar::AV_DO_NOT_RENDER)); + } + else if ("always" == command_name) + { + return (visual_setting == S32(LLVOAvatar::AV_ALWAYS_RENDER)); + } + return false; +} + +void LLFloaterAvatarRenderSettings::setNeedsUpdate() +{ + LLFloaterAvatarRenderSettings* instance = LLFloaterReg::getTypedInstance<LLFloaterAvatarRenderSettings>("avatar_render_settings"); + if(!instance) return; + instance->mNeedsUpdate = true; +} + +void LLFloaterAvatarRenderSettings::onClickAdd(const LLSD& userdata) +{ + const std::string command_name = userdata.asString(); + S32 visual_setting = 0; + if ("never" == command_name) + { + visual_setting = S32(LLVOAvatar::AV_DO_NOT_RENDER); + } + else if ("always" == command_name) + { + visual_setting = S32(LLVOAvatar::AV_ALWAYS_RENDER); + } + + LLView * button = findChild<LLButton>("plus_btn", TRUE); + LLFloater* root_floater = gFloaterView->getParentFloater(this); + LLFloaterAvatarPicker * picker = LLFloaterAvatarPicker::show(boost::bind(&LLFloaterAvatarRenderSettings::callbackAvatarPicked, this, _1, visual_setting), + FALSE, TRUE, FALSE, root_floater->getName(), button); + + if (root_floater) + { + root_floater->addDependentFloater(picker); + } + + mPicker = picker->getHandle(); +} + +void LLFloaterAvatarRenderSettings::callbackAvatarPicked(const uuid_vec_t& ids, S32 visual_setting) +{ + if (ids.empty()) return; + + LLVOAvatar *avatarp = find_avatar(ids[0]); + if (avatarp) + { + avatarp->setVisualMuteSettings(LLVOAvatar::VisualMuteSettings(visual_setting)); + } + else + { + LLRenderMuteList::getInstance()->saveVisualMuteSetting(ids[0], visual_setting); + } +} diff --git a/indra/newview/llfloateravatarrendersettings.h b/indra/newview/llfloateravatarrendersettings.h new file mode 100644 index 0000000000..fe727bcf32 --- /dev/null +++ b/indra/newview/llfloateravatarrendersettings.h @@ -0,0 +1,71 @@ +/** + * @file llfloateravatarrendersettings.h + * @brief Shows the list of avatars with non-default rendering settings + * + * $LicenseInfo:firstyear=2009&license=viewerlgpl$ + * Second Life Viewer Source Code + * Copyright (C) 2017, Linden Research, Inc. + * + * 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 LL_LLFLOATERAVATARRENDERSETTINGS_H +#define LL_LLFLOATERAVATARRENDERSETTINGS_H + +#include "llfloater.h" +#include "lllistcontextmenu.h" +#include "llmutelist.h" + +class LLNameListCtrl; + +class LLFloaterAvatarRenderSettings : public LLFloater +{ +public: + + LLFloaterAvatarRenderSettings(const LLSD& key); + virtual ~LLFloaterAvatarRenderSettings(); + + /*virtual*/ BOOL postBuild(); + /*virtual*/ void onOpen(const LLSD& key); + /*virtual*/ void draw(); + + void onAvatarListRightClick(LLUICtrl* ctrl, S32 x, S32 y); + + void updateList(); + void onFilterEdit(const std::string& search_string); + void onCustomAction (const LLSD& userdata, const LLUUID& av_id); + bool isActionChecked(const LLSD& userdata, const LLUUID& av_id); + void onClickAdd(const LLSD& userdata); + + static void setNeedsUpdate(); + +private: + bool isHiddenRow(const std::string& av_name); + void callbackAvatarPicked(const uuid_vec_t& ids, S32 visual_setting); + void removePicker(); + + bool mNeedsUpdate; + LLListContextMenu* mContextMenu; + LLNameListCtrl* mAvatarSettingsList; + LLHandle<LLFloater> mPicker; + + std::string mNameFilter; +}; + + +#endif //LL_LLFLOATERAVATARRENDERSETTINGS_H diff --git a/indra/newview/llfloaterconversationpreview.cpp b/indra/newview/llfloaterconversationpreview.cpp index a358b7c10b..b48ecc8f31 100644 --- a/indra/newview/llfloaterconversationpreview.cpp +++ b/indra/newview/llfloaterconversationpreview.cpp @@ -25,6 +25,7 @@ #include "llviewerprecompiledheaders.h" +#include "llavatarnamecache.h" #include "llconversationlog.h" #include "llfloaterconversationpreview.h" #include "llimview.h" @@ -220,7 +221,7 @@ void LLFloaterConversationPreview::showHistory() else { std::string legacy_name = gCacheName->buildLegacyName(from); - gCacheName->getUUID(legacy_name, from_id); + from_id = LLAvatarNameCache::findIdByName(legacy_name); } LLChat chat; diff --git a/indra/newview/llfloatergridstatus.cpp b/indra/newview/llfloatergridstatus.cpp new file mode 100644 index 0000000000..c47ff1c1d9 --- /dev/null +++ b/indra/newview/llfloatergridstatus.cpp @@ -0,0 +1,184 @@ +/** + * @file llfloatergridstatus.cpp + * @brief Grid status floater - uses an embedded web browser to show Grid status info + * + * $LicenseInfo:firstyear=2009&license=viewerlgpl$ + * Second Life Viewer Source Code + * Copyright (C) 2017, Linden Research, Inc. + * + * 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 "llfloatergridstatus.h" + +#include "llcallbacklist.h" +#include "llcorehttputil.h" +#include "llfloaterreg.h" +#include "llhttpconstants.h" +#include "llmediactrl.h" +#include "llsdserialize.h" +#include "lltoolbarview.h" +#include "llviewercontrol.h" +#include "llxmltree.h" + +std::map<std::string, std::string> LLFloaterGridStatus::sItemsMap; +const std::string DEFAULT_GRID_STATUS_URL = "http://secondlife-status.statuspage.io/"; + +LLFloaterGridStatus::LLFloaterGridStatus(const Params& key) : + LLFloaterWebContent(key), + mIsFirstUpdate(TRUE) +{ +} + +BOOL LLFloaterGridStatus::postBuild() +{ + LLFloaterWebContent::postBuild(); + mWebBrowser->addObserver(this); + + return TRUE; +} + +void LLFloaterGridStatus::onOpen(const LLSD& key) +{ + Params p(key); + p.trusted_content = true; + p.allow_address_entry = false; + + LLFloaterWebContent::onOpen(p); + applyPreferredRect(); + if (mWebBrowser) + { + mWebBrowser->navigateTo(DEFAULT_GRID_STATUS_URL, HTTP_CONTENT_TEXT_HTML); + } +} + +void LLFloaterGridStatus::startGridStatusTimer() +{ + checkGridStatusRSS(); + doPeriodically(boost::bind(&LLFloaterGridStatus::checkGridStatusRSS), gSavedSettings.getF32("GridStatusUpdateDelay")); +} + +bool LLFloaterGridStatus::checkGridStatusRSS() +{ + if(gToolBarView->hasCommand(LLCommandId("gridstatus"))) + { + LLCoros::instance().launch("LLFloaterGridStatus::getGridStatusRSSCoro", + boost::bind(&LLFloaterGridStatus::getGridStatusRSSCoro)); + } + return false; +} + +void LLFloaterGridStatus::getGridStatusRSSCoro() +{ + + LLCore::HttpRequest::policy_t httpPolicy(LLCore::HttpRequest::DEFAULT_POLICY_ID); + LLCoreHttpUtil::HttpCoroutineAdapter::ptr_t + httpAdapter(new LLCoreHttpUtil::HttpCoroutineAdapter("getGridStatusRSSCoro", httpPolicy)); + LLCore::HttpRequest::ptr_t httpRequest(new LLCore::HttpRequest); + LLCore::HttpOptions::ptr_t httpOpts(new LLCore::HttpOptions); + LLCore::HttpHeaders::ptr_t httpHeaders(new LLCore::HttpHeaders); + + httpHeaders->append(HTTP_OUT_HEADER_CONTENT_TYPE, HTTP_CONTENT_TEXT_XML); + std::string url = gSavedSettings.getString("GridStatusRSS"); + + LLSD result = httpAdapter->getRawAndSuspend(httpRequest, url, httpOpts, httpHeaders); + LLSD httpResults = result[LLCoreHttpUtil::HttpCoroutineAdapter::HTTP_RESULTS]; + LLCore::HttpStatus status = LLCoreHttpUtil::HttpCoroutineAdapter::getStatusFromLLSD(httpResults); + if (!status) + { + return; + } + + const LLSD::Binary &rawBody = result[LLCoreHttpUtil::HttpCoroutineAdapter::HTTP_RESULTS_RAW].asBinary(); + std::string body(rawBody.begin(), rawBody.end()); + + std::string fullpath = gDirUtilp->getExpandedFilename(LL_PATH_LOGS,"grid_status_rss.xml"); + if(!gSavedSettings.getBOOL("TestGridStatusRSSFromFile")) + { + llofstream custom_file_out(fullpath.c_str(), std::ios::trunc); + if (custom_file_out.is_open()) + { + custom_file_out << body; + custom_file_out.close(); + } + } + LLXmlTree grid_status_xml; + if (!grid_status_xml.parseFile(fullpath)) + { + return ; + } + bool new_entries = false; + LLXmlTreeNode* rootp = grid_status_xml.getRoot(); + for (LLXmlTreeNode* item = rootp->getChildByName( "entry" ); item; item = rootp->getNextNamedChild()) + { + LLXmlTreeNode* id_node = item->getChildByName("id"); + LLXmlTreeNode* updated_node = item->getChildByName("updated"); + if (!id_node || !updated_node) + { + continue; + } + std::string guid = id_node->getContents(); + std::string date = updated_node->getContents(); + if(sItemsMap.find( guid ) == sItemsMap.end()) + { + new_entries = true; + } + else + { + if(sItemsMap[guid] != date) + { + new_entries = true; + } + } + sItemsMap[guid] = date; + } + if(new_entries && !getInstance()->isFirstUpdate()) + { + gToolBarView->flashCommand(LLCommandId("gridstatus"), true); + } + getInstance()->setFirstUpdate(FALSE); +} + +// virtual +void LLFloaterGridStatus::handleReshape(const LLRect& new_rect, bool by_user) +{ + if (by_user && !isMinimized()) + { + gSavedSettings.setRect("GridStatusFloaterRect", new_rect); + } + + LLFloaterWebContent::handleReshape(new_rect, by_user); +} + +void LLFloaterGridStatus::applyPreferredRect() +{ + const LLRect preferred_rect = gSavedSettings.getRect("GridStatusFloaterRect"); + + LLRect new_rect = getRect(); + new_rect.setLeftTopAndSize( + new_rect.mLeft, new_rect.mTop, + preferred_rect.getWidth(), preferred_rect.getHeight()); + setShape(new_rect); +} + +LLFloaterGridStatus* LLFloaterGridStatus::getInstance() +{ + return LLFloaterReg::getTypedInstance<LLFloaterGridStatus>("grid_status"); +} diff --git a/indra/newview/llfloatergridstatus.h b/indra/newview/llfloatergridstatus.h new file mode 100644 index 0000000000..0c3deb7d4c --- /dev/null +++ b/indra/newview/llfloatergridstatus.h @@ -0,0 +1,71 @@ +/** + * @file llfloatergridstatus.h + * @brief Grid status floater - uses an embedded web browser to show Grid status info + * + * $LicenseInfo:firstyear=2009&license=viewerlgpl$ + * Second Life Viewer Source Code + * Copyright (C) 2017, Linden Research, Inc. + * + * 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 LL_LLFLOATERGRIDSTATUS_H +#define LL_LLFLOATERGRIDSTATUS_H + +#include "llfloaterwebcontent.h" +#include "llviewermediaobserver.h" + +#include <string> + +class LLMediaCtrl; + + +class LLFloaterGridStatus : + public LLFloaterWebContent +{ +public: + typedef LLSDParamAdapter<_Params> Params; + + LLFloaterGridStatus(const Params& key); + + /*virtual*/ void onOpen(const LLSD& key); + /*virtual*/ void handleReshape(const LLRect& new_rect, bool by_user = false); + + static bool checkGridStatusRSS(); + static void getGridStatusRSSCoro(); + + void startGridStatusTimer(); + BOOL isFirstUpdate() { return mIsFirstUpdate; } + void setFirstUpdate(BOOL first_update) { mIsFirstUpdate = first_update; } + + static LLFloaterGridStatus* getInstance(); + + +private: + /*virtual*/ BOOL postBuild(); + + void applyPreferredRect(); + + static std::map<std::string, std::string> sItemsMap; + + LLFrameTimer mGridStatusTimer; + BOOL mIsFirstUpdate; +}; + +#endif // LL_LLFLOATERGRIDSTATUS_H + diff --git a/indra/newview/llfloaterimcontainer.cpp b/indra/newview/llfloaterimcontainer.cpp index 7039e48e74..3522932d03 100644 --- a/indra/newview/llfloaterimcontainer.cpp +++ b/indra/newview/llfloaterimcontainer.cpp @@ -1505,15 +1505,21 @@ bool LLFloaterIMContainer::checkContextMenuItem(const std::string& item, uuid_ve bool LLFloaterIMContainer::visibleContextMenuItem(const LLSD& userdata) { + const LLConversationItem *conversation_item = getCurSelectedViewModelItem(); + if(!conversation_item) + { + return false; + } + const std::string& item = userdata.asString(); if ("show_mute" == item) { - return !isMuted(getCurSelectedViewModelItem()->getUUID()); + return !isMuted(conversation_item->getUUID()); } else if ("show_unmute" == item) { - return isMuted(getCurSelectedViewModelItem()->getUUID()); + return isMuted(conversation_item->getUUID()); } return true; @@ -2093,9 +2099,10 @@ void LLFloaterIMContainer::toggleAllowTextChat(const LLUUID& participant_uuid) void LLFloaterIMContainer::toggleMute(const LLUUID& participant_id, U32 flags) { BOOL is_muted = LLMuteList::getInstance()->isMuted(participant_id, flags); - std::string name; - gCacheName->getFullName(participant_id, name); - LLMute mute(participant_id, name, LLMute::AGENT); + + LLAvatarName av_name; + LLAvatarNameCache::get(participant_id, &av_name); + LLMute mute(participant_id, av_name.getUserName(), LLMute::AGENT); if (!is_muted) { diff --git a/indra/newview/llfloaterimnearbychat.cpp b/indra/newview/llfloaterimnearbychat.cpp index e9af22d336..d18f03d8e9 100644 --- a/indra/newview/llfloaterimnearbychat.cpp +++ b/indra/newview/llfloaterimnearbychat.cpp @@ -218,7 +218,7 @@ void LLFloaterIMNearbyChat::loadHistory() else { std::string legacy_name = gCacheName->buildLegacyName(from); - gCacheName->getUUID(legacy_name, from_id); + from_id = LLAvatarNameCache::findIdByName(legacy_name); } LLChat chat; @@ -304,6 +304,13 @@ void LLFloaterIMNearbyChat::onClose(bool app_quitting) { // Override LLFloaterIMSessionTab::onClose() so that Nearby Chat is not removed from the conversation floater LLFloaterIMSessionTab::restoreFloater(); + if (app_quitting) + { + // We are starting and closing floater in "expanded" state + // Update expanded (restored) rect and position for use in next session + forceReshape(); + storeRectControl(); + } } // virtual diff --git a/indra/newview/llfloaterland.cpp b/indra/newview/llfloaterland.cpp index 7f952d4dd4..a340cd1143 100644 --- a/indra/newview/llfloaterland.cpp +++ b/indra/newview/llfloaterland.cpp @@ -2029,7 +2029,6 @@ void LLPanelLandOptions::refresh() else { // something selected, hooray! - LLViewerRegion* regionp = LLViewerParcelMgr::getInstance()->getSelectionRegion(); // Display options BOOL can_change_options = LLViewerParcelMgr::isParcelModifiableByAgent(parcel, GP_LAND_OPTIONS); @@ -2045,9 +2044,8 @@ void LLPanelLandOptions::refresh() mCheckGroupObjectEntry ->set( parcel->getAllowGroupObjectEntry() || parcel->getAllowAllObjectEntry()); mCheckGroupObjectEntry ->setEnabled( can_change_options && !parcel->getAllowAllObjectEntry() ); - BOOL region_damage = regionp ? regionp->getAllowDamage() : FALSE; mCheckSafe ->set( !parcel->getAllowDamage() ); - mCheckSafe ->setEnabled( can_change_options && region_damage ); + mCheckSafe ->setEnabled( can_change_options ); mCheckFly ->set( parcel->getAllowFly() ); mCheckFly ->setEnabled( can_change_options ); @@ -2127,6 +2125,7 @@ void LLPanelLandOptions::refresh() // they can see the checkbox, but its disposition depends on the // state of the region + LLViewerRegion* regionp = LLViewerParcelMgr::getInstance()->getSelectionRegion(); if (regionp) { if (regionp->getSimAccess() == SIM_ACCESS_PG) @@ -2448,6 +2447,7 @@ void LLPanelLandAccess::refresh() mListAccess->deleteAllItems(); S32 count = parcel->mAccessList.size(); getChild<LLUICtrl>("AllowedText")->setTextArg("[COUNT]", llformat("%d",count)); + getChild<LLUICtrl>("AllowedText")->setTextArg("[MAX]", llformat("%d",PARCEL_MAX_ACCESS_LIST)); getChild<LLUICtrl>("AccessList")->setToolTipArg(LLStringExplicit("[LISTED]"), llformat("%d",count)); getChild<LLUICtrl>("AccessList")->setToolTipArg(LLStringExplicit("[MAX]"), llformat("%d",PARCEL_MAX_ACCESS_LIST)); @@ -2495,6 +2495,7 @@ void LLPanelLandAccess::refresh() mListBanned->deleteAllItems(); S32 count = parcel->mBanList.size(); getChild<LLUICtrl>("BanCheck")->setTextArg("[COUNT]", llformat("%d",count)); + getChild<LLUICtrl>("BanCheck")->setTextArg("[MAX]", llformat("%d",PARCEL_MAX_ACCESS_LIST)); getChild<LLUICtrl>("BannedList")->setToolTipArg(LLStringExplicit("[LISTED]"), llformat("%d",count)); getChild<LLUICtrl>("BannedList")->setToolTipArg(LLStringExplicit("[MAX]"), llformat("%d",PARCEL_MAX_ACCESS_LIST)); diff --git a/indra/newview/llfloatermarketplacelistings.cpp b/indra/newview/llfloatermarketplacelistings.cpp index 18f0bc4498..889d017389 100644 --- a/indra/newview/llfloatermarketplacelistings.cpp +++ b/indra/newview/llfloatermarketplacelistings.cpp @@ -603,6 +603,7 @@ void LLFloaterMarketplaceListings::updateView() text = LLTrans::getString("InventoryMarketplaceError", subs); title = LLTrans::getString("InventoryOutboxErrorTitle"); tooltip = LLTrans::getString("InventoryOutboxErrorTooltip"); + LL_WARNS() << "Marketplace status code: " << mkt_status << LL_ENDL; } mInventoryText->setValue(text); diff --git a/indra/newview/llfloaterpathfindingobjects.cpp b/indra/newview/llfloaterpathfindingobjects.cpp index f6ff83eaf4..5cf16f3ad6 100644 --- a/indra/newview/llfloaterpathfindingobjects.cpp +++ b/indra/newview/llfloaterpathfindingobjects.cpp @@ -329,7 +329,7 @@ void LLFloaterPathfindingObjects::handleUpdateObjectList(LLPathfindingManager::r } } -void LLFloaterPathfindingObjects::rebuildObjectsScrollList() +void LLFloaterPathfindingObjects::rebuildObjectsScrollList(bool update_if_needed) { if (!mHasObjectsToBeSelected) { @@ -355,7 +355,14 @@ void LLFloaterPathfindingObjects::rebuildObjectsScrollList() { buildObjectsScrollList(mObjectList); - mObjectsScrollList->selectMultiple(mObjectsToBeSelected); + if(mObjectsScrollList->selectMultiple(mObjectsToBeSelected) == 0) + { + if(update_if_needed && mRefreshListButton->getEnabled()) + { + requestGetObjects(); + return; + } + } if (mHasObjectsToBeSelected) { mObjectsScrollList->scrollToShowSelected(); @@ -484,7 +491,7 @@ void LLFloaterPathfindingObjects::showFloaterWithSelectionObjects() } else { - rebuildObjectsScrollList(); + rebuildObjectsScrollList(true); if (isMinimized()) { setMinimized(FALSE); diff --git a/indra/newview/llfloaterpathfindingobjects.h b/indra/newview/llfloaterpathfindingobjects.h index 4024e15fd6..752f741959 100644 --- a/indra/newview/llfloaterpathfindingobjects.h +++ b/indra/newview/llfloaterpathfindingobjects.h @@ -80,7 +80,7 @@ protected: void handleNewObjectList(LLPathfindingManager::request_id_t pRequestId, LLPathfindingManager::ERequestStatus pRequestStatus, LLPathfindingObjectListPtr pObjectList); void handleUpdateObjectList(LLPathfindingManager::request_id_t pRequestId, LLPathfindingManager::ERequestStatus pRequestStatus, LLPathfindingObjectListPtr pObjectList); - void rebuildObjectsScrollList(); + void rebuildObjectsScrollList(bool update_if_needed = false); virtual void buildObjectsScrollList(const LLPathfindingObjectListPtr pObjectListPtr); void addObjectToScrollList(const LLPathfindingObjectPtr pObjectPr, const LLSD &pScrollListItemData); diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp index 100ee5ab72..1f460c05ec 100644 --- a/indra/newview/llfloaterpreference.cpp +++ b/indra/newview/llfloaterpreference.cpp @@ -360,6 +360,7 @@ LLFloaterPreference::LLFloaterPreference(const LLSD& key) mCommitCallbackRegistrar.add("Pref.ClickEnablePopup", boost::bind(&LLFloaterPreference::onClickEnablePopup, this)); mCommitCallbackRegistrar.add("Pref.ClickDisablePopup", boost::bind(&LLFloaterPreference::onClickDisablePopup, this)); mCommitCallbackRegistrar.add("Pref.LogPath", boost::bind(&LLFloaterPreference::onClickLogPath, this)); + mCommitCallbackRegistrar.add("Pref.RenderExceptions", boost::bind(&LLFloaterPreference::onClickRenderExceptions, this)); mCommitCallbackRegistrar.add("Pref.HardwareDefaults", boost::bind(&LLFloaterPreference::setHardwareDefaults, this)); mCommitCallbackRegistrar.add("Pref.AvatarImpostorsEnable", boost::bind(&LLFloaterPreference::onAvatarImpostorsEnable, this)); mCommitCallbackRegistrar.add("Pref.UpdateIndirectMaxComplexity", boost::bind(&LLFloaterPreference::updateMaxComplexity, this)); @@ -385,7 +386,7 @@ LLFloaterPreference::LLFloaterPreference(const LLSD& key) gSavedSettings.getControl("NameTagShowUsernames")->getCommitSignal()->connect(boost::bind(&handleNameTagOptionChanged, _2)); gSavedSettings.getControl("NameTagShowFriends")->getCommitSignal()->connect(boost::bind(&handleNameTagOptionChanged, _2)); gSavedSettings.getControl("UseDisplayNames")->getCommitSignal()->connect(boost::bind(&handleDisplayNamesOptionChanged, _2)); - + gSavedSettings.getControl("AppearanceCameraMovement")->getCommitSignal()->connect(boost::bind(&handleAppearanceCameraMovementChanged, _2)); LLAvatarPropertiesProcessor::getInstance()->addObserver( gAgent.getID(), this ); @@ -467,6 +468,11 @@ BOOL LLFloaterPreference::postBuild() gSavedSettings.getControl("PreferredMaturity")->getSignal()->connect(boost::bind(&LLFloaterPreference::onChangeMaturity, this)); + gSavedPerAccountSettings.getControl("ModelUploadFolder")->getSignal()->connect(boost::bind(&LLFloaterPreference::onChangeModelFolder, this)); + gSavedPerAccountSettings.getControl("TextureUploadFolder")->getSignal()->connect(boost::bind(&LLFloaterPreference::onChangeTextureFolder, this)); + gSavedPerAccountSettings.getControl("SoundUploadFolder")->getSignal()->connect(boost::bind(&LLFloaterPreference::onChangeSoundFolder, this)); + gSavedPerAccountSettings.getControl("AnimationUploadFolder")->getSignal()->connect(boost::bind(&LLFloaterPreference::onChangeAnimationFolder, this)); + LLTabContainer* tabcontainer = getChild<LLTabContainer>("pref core"); if (!tabcontainer->selectTab(gSavedSettings.getS32("LastPrefTab"))) tabcontainer->selectFirstTab(); @@ -501,6 +507,7 @@ BOOL LLFloaterPreference::postBuild() fov_slider->setMinValue(LLViewerCamera::getInstance()->getMinView()); fov_slider->setMaxValue(LLViewerCamera::getInstance()->getMaxView()); + return TRUE; } @@ -742,7 +749,12 @@ void LLFloaterPreference::onOpen(const LLSD& key) // Display selected maturity icons. onChangeMaturity(); - + + onChangeModelFolder(); + onChangeTextureFolder(); + onChangeSoundFolder(); + onChangeAnimationFolder(); + // Load (double-)click to walk/teleport settings. updateClickActionControls(); @@ -775,10 +787,12 @@ void LLFloaterPreference::onOpen(const LLSD& key) LLButton* load_btn = findChild<LLButton>("PrefLoadButton"); LLButton* save_btn = findChild<LLButton>("PrefSaveButton"); LLButton* delete_btn = findChild<LLButton>("PrefDeleteButton"); + LLButton* exceptions_btn = findChild<LLButton>("RenderExceptionsButton"); load_btn->setEnabled(started); save_btn->setEnabled(started); delete_btn->setEnabled(started); + exceptions_btn->setEnabled(started); } void LLFloaterPreference::onVertexShaderEnable() @@ -1979,6 +1993,63 @@ void LLFloaterPreference::onChangeMaturity() getChild<LLIconCtrl>("rating_icon_adult")->setVisible(sim_access == SIM_ACCESS_ADULT); } +std::string get_category_path(LLUUID cat_id) +{ + LLViewerInventoryCategory* cat = gInventory.getCategory(cat_id); + std::string localized_cat_name; + if (!LLTrans::findString(localized_cat_name, "InvFolder " + cat->getName())) + { + localized_cat_name = cat->getName(); + } + + if (cat->getParentUUID().notNull()) + { + return get_category_path(cat->getParentUUID()) + " > " + localized_cat_name; + } + else + { + return localized_cat_name; + } +} + +std::string get_category_path(LLFolderType::EType cat_type) +{ + LLUUID cat_id = gInventory.findUserDefinedCategoryUUIDForType(cat_type); + return get_category_path(cat_id); +} + +void LLFloaterPreference::onChangeModelFolder() +{ + if (gInventory.isInventoryUsable()) + { + getChild<LLTextBox>("upload_models")->setText(get_category_path(LLFolderType::FT_OBJECT)); + } +} + +void LLFloaterPreference::onChangeTextureFolder() +{ + if (gInventory.isInventoryUsable()) + { + getChild<LLTextBox>("upload_textures")->setText(get_category_path(LLFolderType::FT_TEXTURE)); + } +} + +void LLFloaterPreference::onChangeSoundFolder() +{ + if (gInventory.isInventoryUsable()) + { + getChild<LLTextBox>("upload_sounds")->setText(get_category_path(LLFolderType::FT_SOUND)); + } +} + +void LLFloaterPreference::onChangeAnimationFolder() +{ + if (gInventory.isInventoryUsable()) + { + getChild<LLTextBox>("upload_animation")->setText(get_category_path(LLFolderType::FT_ANIMATION)); + } +} + // FIXME: this will stop you from spawning the sidetray from preferences dialog on login screen // but the UI for this will still be enabled void LLFloaterPreference::onClickBlockList() @@ -2007,6 +2078,11 @@ void LLFloaterPreference::onClickSpellChecker() LLFloaterReg::showInstance("prefs_spellchecker"); } +void LLFloaterPreference::onClickRenderExceptions() +{ + LLFloaterReg::showInstance("avatar_render_settings"); +} + void LLFloaterPreference::onClickAdvanced() { LLFloaterReg::showInstance("prefs_graphics_advanced"); diff --git a/indra/newview/llfloaterpreference.h b/indra/newview/llfloaterpreference.h index fa0c09e97a..2bb2e7e9ff 100644 --- a/indra/newview/llfloaterpreference.h +++ b/indra/newview/llfloaterpreference.h @@ -161,12 +161,17 @@ public: void onCommitMusicEnabled(); void applyResolution(); void onChangeMaturity(); + void onChangeModelFolder(); + void onChangeTextureFolder(); + void onChangeSoundFolder(); + void onChangeAnimationFolder(); void onClickBlockList(); void onClickProxySettings(); void onClickTranslationSettings(); void onClickPermsDefault(); void onClickAutoReplace(); void onClickSpellChecker(); + void onClickRenderExceptions(); void onClickAdvanced(); void applyUIColor(LLUICtrl* ctrl, const LLSD& param); void getUIColor(LLUICtrl* ctrl, const LLSD& param); diff --git a/indra/newview/llfloaterproperties.cpp b/indra/newview/llfloaterproperties.cpp index 6bfc780722..1310a60638 100644 --- a/indra/newview/llfloaterproperties.cpp +++ b/indra/newview/llfloaterproperties.cpp @@ -30,6 +30,7 @@ #include <algorithm> #include <functional> #include "llcachename.h" +#include "llavatarnamecache.h" #include "lldbstrings.h" #include "llfloaterreg.h" @@ -274,12 +275,12 @@ void LLFloaterProperties::refreshFromItem(LLInventoryItem* item) if (item->getCreatorUUID().notNull()) { - std::string name; - gCacheName->getFullName(item->getCreatorUUID(), name); + LLAvatarName av_name; + LLAvatarNameCache::get(item->getCreatorUUID(), &av_name); getChildView("BtnCreator")->setEnabled(TRUE); getChildView("LabelCreatorTitle")->setEnabled(TRUE); getChildView("LabelCreatorName")->setEnabled(TRUE); - getChild<LLUICtrl>("LabelCreatorName")->setValue(name); + getChild<LLUICtrl>("LabelCreatorName")->setValue(av_name.getUserName()); } else { @@ -301,7 +302,9 @@ void LLFloaterProperties::refreshFromItem(LLInventoryItem* item) } else { - gCacheName->getFullName(perm.getOwner(), name); + LLAvatarName av_name; + LLAvatarNameCache::get(perm.getOwner(), &av_name); + name = av_name.getUserName(); } getChildView("BtnOwner")->setEnabled(TRUE); getChildView("LabelOwnerTitle")->setEnabled(TRUE); diff --git a/indra/newview/llfloaterregioninfo.cpp b/indra/newview/llfloaterregioninfo.cpp index 843dbbf25e..75d7d787b1 100644 --- a/indra/newview/llfloaterregioninfo.cpp +++ b/indra/newview/llfloaterregioninfo.cpp @@ -357,6 +357,7 @@ void LLFloaterRegionInfo::processRegionInfo(LLMessageSystem* msg) std::string sim_type = LLTrans::getString("land_type_unknown"); U64 region_flags; U8 agent_limit; + S32 hard_agent_limit; F32 object_bonus_factor; U8 sim_access; F32 water_height; @@ -366,6 +367,7 @@ void LLFloaterRegionInfo::processRegionInfo(LLMessageSystem* msg) F32 sun_hour; msg->getString("RegionInfo", "SimName", sim_name); msg->getU8("RegionInfo", "MaxAgents", agent_limit); + msg->getS32("RegionInfo2", "HardMaxAgents", hard_agent_limit); msg->getF32("RegionInfo", "ObjectBonusFactor", object_bonus_factor); msg->getU8("RegionInfo", "SimAccess", sim_access); msg->getF32Fast(_PREHASH_RegionInfo, _PREHASH_WaterHeight, water_height); @@ -412,6 +414,8 @@ void LLFloaterRegionInfo::processRegionInfo(LLMessageSystem* msg) panel->getChild<LLUICtrl>("object_bonus_spin")->setValue(LLSD(object_bonus_factor) ); panel->getChild<LLUICtrl>("access_combo")->setValue(LLSD(sim_access) ); + panel->getChild<LLSpinCtrl>("agent_limit_spin")->setMaxValue(hard_agent_limit); + LLPanelRegionGeneralInfo* panel_general = LLFloaterRegionInfo::getPanelGeneral(); if (panel) { diff --git a/indra/newview/llfloaterreporter.cpp b/indra/newview/llfloaterreporter.cpp index 275554540e..515c2b0c4b 100644 --- a/indra/newview/llfloaterreporter.cpp +++ b/indra/newview/llfloaterreporter.cpp @@ -35,6 +35,7 @@ #include "llassetstorage.h" #include "llavatarnamecache.h" #include "llcachename.h" +#include "llcallbacklist.h" #include "llcheckboxctrl.h" #include "llfontgl.h" #include "llimagebmp.h" @@ -211,7 +212,7 @@ BOOL LLFloaterReporter::postBuild() // grab the user's name std::string reporter = LLSLURL("agent", gAgent.getID(), "inspect").getSLURLString(); getChild<LLUICtrl>("reporter_field")->setValue(reporter); - + center(); return TRUE; @@ -837,8 +838,9 @@ void LLFloaterReporter::takeScreenshot(bool use_prev_screenshot) } } -void LLFloaterReporter::onOpen(const LLSD& key) +void LLFloaterReporter::takeNewSnapshot() { + childSetEnabled("send_btn", true); mImageRaw = new LLImageRaw; const S32 IMAGE_WIDTH = 1024; const S32 IMAGE_HEIGHT = 768; @@ -867,10 +869,18 @@ void LLFloaterReporter::onOpen(const LLSD& key) } } } - takeScreenshot(); } + +void LLFloaterReporter::onOpen(const LLSD& key) +{ + childSetEnabled("send_btn", false); + //Time delay to avoid UI artifacts. MAINT-7067 + doAfterInterval(boost::bind(&LLFloaterReporter::takeNewSnapshot,this), gSavedSettings.getF32("AbuseReportScreenshotDelay")); + +} + void LLFloaterReporter::onLoadScreenshotDialog(const LLSD& notification, const LLSD& response) { S32 option = LLNotificationsUtil::getSelectedOption(notification, response); diff --git a/indra/newview/llfloaterreporter.h b/indra/newview/llfloaterreporter.h index e5232268c0..decc01be98 100644 --- a/indra/newview/llfloaterreporter.h +++ b/indra/newview/llfloaterreporter.h @@ -107,6 +107,8 @@ public: void onLoadScreenshotDialog(const LLSD& notification, const LLSD& response); + void takeNewSnapshot(); + private: static void show(const LLUUID& object_id, const std::string& avatar_name = LLStringUtil::null, const LLUUID& experience_id = LLUUID::null); diff --git a/indra/newview/llfloaterscriptdebug.cpp b/indra/newview/llfloaterscriptdebug.cpp index 6c17f62c1e..468537e659 100644 --- a/indra/newview/llfloaterscriptdebug.cpp +++ b/indra/newview/llfloaterscriptdebug.cpp @@ -34,6 +34,7 @@ #include "llrect.h" #include "llerror.h" #include "llstring.h" +#include "llvoavatarself.h" #include "message.h" // project include @@ -80,6 +81,36 @@ BOOL LLFloaterScriptDebug::postBuild() return FALSE; } +void LLFloaterScriptDebug::setVisible(BOOL visible) +{ + if(visible) + { + LLFloaterScriptDebugOutput* floater_output = LLFloaterReg::findTypedInstance<LLFloaterScriptDebugOutput>("script_debug_output", LLUUID::null); + if (floater_output == NULL) + { + floater_output = dynamic_cast<LLFloaterScriptDebugOutput*>(LLFloaterReg::showInstance("script_debug_output", LLUUID::null, FALSE)); + if (floater_output) + { + addFloater(floater_output, false); + } + } + + } + LLMultiFloater::setVisible(visible); +} + +void LLFloaterScriptDebug::closeFloater(bool app_quitting/* = false*/) +{ + if(app_quitting) + { + LLMultiFloater::closeFloater(app_quitting); + } + else + { + setVisible(false); + } +} + LLFloater* LLFloaterScriptDebug::addOutputWindow(const LLUUID &object_id) { LLMultiFloater* host = LLFloaterReg::showTypedInstance<LLMultiFloater>("script_debug", LLSD()); @@ -105,7 +136,14 @@ void LLFloaterScriptDebug::addScriptLine(const std::string &utf8mesg, const std: if (objectp) { - objectp->setIcon(LLViewerTextureManager::getFetchedTextureFromFile("script_error.j2c", FTT_LOCAL_FILE, TRUE, LLGLTexture::BOOST_UI)); + if(objectp->isHUDAttachment()) + { + ((LLViewerObject*)gAgentAvatarp)->setIcon(LLViewerTextureManager::getFetchedTextureFromFile("script_error.j2c", FTT_LOCAL_FILE, TRUE, LLGLTexture::BOOST_UI)); + } + else + { + objectp->setIcon(LLViewerTextureManager::getFetchedTextureFromFile("script_error.j2c", FTT_LOCAL_FILE, TRUE, LLGLTexture::BOOST_UI)); + } floater_label = llformat("%s(%.0f, %.0f, %.0f)", user_name.c_str(), objectp->getPositionRegion().mV[VX], @@ -117,7 +155,6 @@ void LLFloaterScriptDebug::addScriptLine(const std::string &utf8mesg, const std: floater_label = user_name; } - addOutputWindow(LLUUID::null); addOutputWindow(source_id); // add to "All" floater diff --git a/indra/newview/llfloaterscriptdebug.h b/indra/newview/llfloaterscriptdebug.h index 6d9d1eb500..8c08b234f3 100644 --- a/indra/newview/llfloaterscriptdebug.h +++ b/indra/newview/llfloaterscriptdebug.h @@ -38,7 +38,10 @@ public: LLFloaterScriptDebug(const LLSD& key); virtual ~LLFloaterScriptDebug(); virtual BOOL postBuild(); + virtual void setVisible(BOOL visible); static void show(const LLUUID& object_id); + + /*virtual*/ void closeFloater(bool app_quitting = false); static void addScriptLine(const std::string &utf8mesg, const std::string &user_name, const LLColor4& color, const LLUUID& source_id); protected: diff --git a/indra/newview/llfloaterscriptlimits.cpp b/indra/newview/llfloaterscriptlimits.cpp index c14bb4e7ae..5f0587a286 100644 --- a/indra/newview/llfloaterscriptlimits.cpp +++ b/indra/newview/llfloaterscriptlimits.cpp @@ -391,6 +391,14 @@ void LLPanelScriptLimitsRegionMemory::setErrorStatus(S32 status, const std::stri } // callback from the name cache with an owner name to add to the list +void LLPanelScriptLimitsRegionMemory::onAvatarNameCache( + const LLUUID& id, + const LLAvatarName& av_name) +{ + onNameCache(id, av_name.getUserName()); +} + +// callback from the name cache with an owner name to add to the list void LLPanelScriptLimitsRegionMemory::onNameCache( const LLUUID& id, const std::string& full_name) @@ -503,7 +511,9 @@ void LLPanelScriptLimitsRegionMemory::setRegionDetails(LLSD content) } else { - name_is_cached = gCacheName->getFullName(owner_id, owner_buf); // username + LLAvatarName av_name; + name_is_cached = LLAvatarNameCache::get(owner_id, &av_name); + owner_buf = av_name.getUserName(); owner_buf = LLCacheName::buildUsername(owner_buf); } if(!name_is_cached) @@ -511,9 +521,18 @@ void LLPanelScriptLimitsRegionMemory::setRegionDetails(LLSD content) if(std::find(names_requested.begin(), names_requested.end(), owner_id) == names_requested.end()) { names_requested.push_back(owner_id); - gCacheName->get(owner_id, is_group_owned, // username - boost::bind(&LLPanelScriptLimitsRegionMemory::onNameCache, - this, _1, _2)); + if (is_group_owned) + { + gCacheName->getGroup(owner_id, + boost::bind(&LLPanelScriptLimitsRegionMemory::onNameCache, + this, _1, _2)); + } + else + { + LLAvatarNameCache::get(owner_id, + boost::bind(&LLPanelScriptLimitsRegionMemory::onAvatarNameCache, + this, _1, _2)); + } } } } diff --git a/indra/newview/llfloaterscriptlimits.h b/indra/newview/llfloaterscriptlimits.h index 2ac3862b4f..16450c6527 100644 --- a/indra/newview/llfloaterscriptlimits.h +++ b/indra/newview/llfloaterscriptlimits.h @@ -38,6 +38,7 @@ class LLPanelScriptLimitsInfo; class LLTabContainer; +class LLAvatarName; class LLPanelScriptLimitsRegionMemory; @@ -116,6 +117,8 @@ public: void checkButtonsEnabled(); private: + void onAvatarNameCache(const LLUUID& id, + const LLAvatarName& av_name); void onNameCache(const LLUUID& id, const std::string& name); diff --git a/indra/newview/llfloatersnapshot.cpp b/indra/newview/llfloatersnapshot.cpp index c0980719bb..ba3106913c 100644 --- a/indra/newview/llfloatersnapshot.cpp +++ b/indra/newview/llfloatersnapshot.cpp @@ -653,10 +653,6 @@ void LLFloaterSnapshot::Impl::setFinished(bool finished, bool ok, const std::str LLUICtrl* finished_lbl = mFloater->getChild<LLUICtrl>(ok ? "succeeded_lbl" : "failed_lbl"); std::string result_text = mFloater->getString(msg + "_" + (ok ? "succeeded_str" : "failed_str")); finished_lbl->setValue(result_text); - - LLSideTrayPanelContainer* panel_container = mFloater->getChild<LLSideTrayPanelContainer>("panel_container"); - panel_container->openPreviousPanel(); - panel_container->getCurrentPanel()->onOpen(LLSD()); } } diff --git a/indra/newview/llfloaterworldmap.cpp b/indra/newview/llfloaterworldmap.cpp index d89fa03c1a..83f268818e 100644 --- a/indra/newview/llfloaterworldmap.cpp +++ b/indra/newview/llfloaterworldmap.cpp @@ -546,7 +546,7 @@ void LLFloaterWorldMap::trackAvatar( const LLUUID& avatar_id, const std::string& // convenience. if(gAgent.isGodlike()) { - getChild<LLUICtrl>("spin z")->setValue(LLSD(200.f)); + getChild<LLUICtrl>("teleport_coordinate_z")->setValue(LLSD(200.f)); } // Don't re-request info if we already have it or we won't have it in time to teleport if (mTrackedStatus != LLTracker::TRACKING_AVATAR || name != mTrackedAvatarName) @@ -1375,7 +1375,7 @@ void LLFloaterWorldMap::teleport() && av_tracker.haveTrackingInfo() ) { pos_global = av_tracker.getGlobalPos(); - pos_global.mdV[VZ] = getChild<LLUICtrl>("spin z")->getValue(); + pos_global.mdV[VZ] = getChild<LLUICtrl>("teleport_coordinate_z")->getValue(); } else if ( LLTracker::TRACKING_LANDMARK == tracking_status) { diff --git a/indra/newview/llgiveinventory.cpp b/indra/newview/llgiveinventory.cpp index a9bf8a9a50..3ab8fed2c6 100644 --- a/indra/newview/llgiveinventory.cpp +++ b/indra/newview/llgiveinventory.cpp @@ -36,6 +36,7 @@ #include "llagentdata.h" #include "llagentui.h" #include "llagentwearables.h" +#include "llavatarnamecache.h" #include "llfloatertools.h" // for gFloaterTool #include "llhudeffecttrail.h" #include "llhudmanager.h" @@ -306,32 +307,36 @@ bool LLGiveInventory::doGiveInventoryCategory(const LLUUID& to_agent, ////////////////////////////////////////////////////////////////////////// //static -void LLGiveInventory::logInventoryOffer(const LLUUID& to_agent, const LLUUID &im_session_id) +void LLGiveInventory::logInventoryOffer(const LLUUID& to_agent, const LLUUID &im_session_id, const std::string& item_name, bool is_folder) { // compute id of possible IM session with agent that has "to_agent" id LLUUID session_id = LLIMMgr::computeSessionID(IM_NOTHING_SPECIAL, to_agent); // If this item was given by drag-and-drop into an IM panel, log this action in the IM panel chat. LLSD args; args["user_id"] = to_agent; + args["ITEM_NAME"] = item_name; + std::string message_name = is_folder ? "inventory_folder_offered" : "inventory_item_offered"; if (im_session_id.notNull()) { - gIMMgr->addSystemMessage(im_session_id, "inventory_item_offered", args); + gIMMgr->addSystemMessage(im_session_id, message_name, args); } // If this item was given by drag-and-drop on avatar while IM panel was open, log this action in the IM panel chat. else if (LLIMModel::getInstance()->findIMSession(session_id)) { - gIMMgr->addSystemMessage(session_id, "inventory_item_offered", args); + gIMMgr->addSystemMessage(session_id, message_name, args); } // If this item was given by drag-and-drop on avatar while IM panel wasn't open, log this action to IM history. else { - std::string full_name; - if (gCacheName->getFullName(to_agent, full_name)) + LLAvatarName av_name; + if (LLAvatarNameCache::get(to_agent, &av_name)) { // Build a new format username or firstname_lastname for legacy names // to use it for a history log filename. - full_name = LLCacheName::buildUsername(full_name); - LLIMModel::instance().logToFile(full_name, LLTrans::getString("SECOND_LIFE"), im_session_id, LLTrans::getString("inventory_item_offered-im")); + std::string full_name = LLCacheName::buildUsername(av_name.getUserName()); + LLUIString message = LLTrans::getString(message_name + "-im"); + message.setArgs(args); + LLIMModel::instance().logToFile(full_name, LLTrans::getString("SECOND_LIFE"), im_session_id, message.getString()); } } } @@ -385,6 +390,7 @@ void LLGiveInventory::commitGiveInventoryItem(const LLUUID& to_agent, { if (!item) return; std::string name; + std::string item_name = item->getName(); LLAgentUI::buildFullname(name); LLUUID transaction_id; transaction_id.generate(); @@ -399,7 +405,7 @@ void LLGiveInventory::commitGiveInventoryItem(const LLUUID& to_agent, gAgentSessionID, to_agent, name, - item->getName(), + item_name, IM_ONLINE, IM_INVENTORY_OFFERED, transaction_id, @@ -421,7 +427,7 @@ void LLGiveInventory::commitGiveInventoryItem(const LLUUID& to_agent, LLMuteList::getInstance()->autoRemove(to_agent, LLMuteList::AR_INVENTORY); - logInventoryOffer(to_agent, im_session_id); + logInventoryOffer(to_agent, im_session_id, item_name); // add buddy to recent people list LLRecentPeople::instance().add(to_agent); @@ -501,7 +507,7 @@ bool LLGiveInventory::commitGiveInventoryCategory(const LLUUID& to_agent, items, LLInventoryModel::EXCLUDE_TRASH, giveable); - + std::string cat_name = cat->getName(); bool give_successful = true; // MAX ITEMS is based on (sizeof(uuid)+2) * count must be < // MTUBYTES or 18 * count < 1200 => count < 1200/18 => @@ -556,7 +562,7 @@ bool LLGiveInventory::commitGiveInventoryCategory(const LLUUID& to_agent, gAgent.getSessionID(), to_agent, name, - cat->getName(), + cat_name, IM_ONLINE, IM_INVENTORY_OFFERED, transaction_id, @@ -579,7 +585,7 @@ bool LLGiveInventory::commitGiveInventoryCategory(const LLUUID& to_agent, LLMuteList::getInstance()->autoRemove(to_agent, LLMuteList::AR_INVENTORY); - logInventoryOffer(to_agent, im_session_id); + logInventoryOffer(to_agent, im_session_id, cat_name, true); } return give_successful; diff --git a/indra/newview/llgiveinventory.h b/indra/newview/llgiveinventory.h index 85bc1ed49c..20e6df76e5 100644 --- a/indra/newview/llgiveinventory.h +++ b/indra/newview/llgiveinventory.h @@ -78,7 +78,9 @@ private: * logs "Inventory item offered" to IM */ static void logInventoryOffer(const LLUUID& to_agent, - const LLUUID &im_session_id = LLUUID::null); + const LLUUID &im_session_id = LLUUID::null, + const std::string& item_name = std::string(), + bool is_folder = false); static void commitGiveInventoryItem(const LLUUID& to_agent, const LLInventoryItem* item, diff --git a/indra/newview/llgroupmgr.cpp b/indra/newview/llgroupmgr.cpp index 7545112ab9..152d0eddcd 100644 --- a/indra/newview/llgroupmgr.cpp +++ b/indra/newview/llgroupmgr.cpp @@ -38,6 +38,7 @@ #include "llappviewer.h" #include "llagent.h" +#include "llavatarnamecache.h" #include "llui.h" #include "message.h" #include "roles_constants.h" @@ -54,6 +55,7 @@ #include <boost/regex.hpp> #include "llcorehttputil.h" + #if LL_MSVC #pragma warning(push) // disable boost::lexical_cast warning @@ -819,9 +821,9 @@ void LLGroupMgrGroupData::banMemberById(const LLUUID& participant_uuid) LLGroupMgr::getInstance()->sendGroupMemberEjects(mID, ids); LLGroupMgr::getInstance()->sendGroupMembersRequest(mID); LLSD args; - std::string name; - gCacheName->getFullName(participant_uuid, name); - args["AVATAR_NAME"] = name; + LLAvatarName av_name; + LLAvatarNameCache::get(participant_uuid, &av_name); + args["AVATAR_NAME"] = av_name.getUserName(); args["GROUP_NAME"] = mName; LLNotifications::instance().add(LLNotification::Params("EjectAvatarFromGroup").substitutions(args)); } diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp index 2405c3a1a3..ff8b8b0403 100644 --- a/indra/newview/llimview.cpp +++ b/indra/newview/llimview.cpp @@ -646,6 +646,7 @@ void LLIMModel::LLIMSession::onVoiceChannelStateChanged(const LLVoiceChannel::ES std::string you_joined_call = LLTrans::getString("you_joined_call"); std::string you_started_call = LLTrans::getString("you_started_call"); std::string other_avatar_name = ""; + LLAvatarName av_name; std::string message; @@ -655,7 +656,8 @@ void LLIMModel::LLIMSession::onVoiceChannelStateChanged(const LLVoiceChannel::ES // no text notifications break; case P2P_SESSION: - gCacheName->getFullName(mOtherParticipantID, other_avatar_name); // voice + LLAvatarNameCache::get(mOtherParticipantID, &av_name); + other_avatar_name = av_name.getUserName(); if(direction == LLVoiceChannel::INCOMING_CALL) { @@ -806,7 +808,7 @@ void LLIMModel::LLIMSession::addMessagesFromHistory(const std::list<LLSD>& histo { // convert it to a legacy name if we have a complete name std::string legacy_name = gCacheName->buildLegacyName(from); - gCacheName->getUUID(legacy_name, from_id); + from_id = LLAvatarNameCache::findIdByName(legacy_name); } std::string timestamp = msg[LL_IM_TIME]; @@ -2703,7 +2705,7 @@ void LLIMMgr::addMessage( // Logically it would make more sense to reject the session sooner, in another area of the // code, but the session has to be established inside the server before it can be left. - if (LLMuteList::getInstance()->isMuted(other_participant_id) && !from_linden) + if (LLMuteList::getInstance()->isMuted(other_participant_id, LLMute::flagTextChat) && !from_linden) { LL_WARNS() << "Leaving IM session from initiating muted resident " << from << LL_ENDL; if(!gIMMgr->leaveSession(new_session_id)) @@ -2765,10 +2767,10 @@ void LLIMMgr::addSystemMessage(const LLUUID& session_id, const std::string& mess else { - std::string session_name; + LLAvatarName av_name; // since we select user to share item with - his name is already in cache - gCacheName->getFullName(args["user_id"], session_name); - session_name = LLCacheName::buildUsername(session_name); + LLAvatarNameCache::get(args["user_id"], &av_name); + std::string session_name = LLCacheName::buildUsername(av_name.getUserName()); LLIMModel::instance().logToFile(session_name, SYSTEM_FROM, LLUUID::null, message.getString()); } } @@ -3011,14 +3013,20 @@ void LLIMMgr::inviteToSession( payload["question_type"] = question_type; //ignore invites from muted residents - if (LLMuteList::getInstance()->isMuted(caller_id) && !is_linden) + if (!is_linden) { - if (voice_invite && "VoiceInviteQuestionDefault" == question_type) + if (LLMuteList::getInstance()->isMuted(caller_id, LLMute::flagVoiceChat) + && voice_invite && "VoiceInviteQuestionDefault" == question_type) { LL_INFOS() << "Rejecting voice call from initiating muted resident " << caller_name << LL_ENDL; LLIncomingCallDialog::processCallResponse(1, payload); + return; + } + else if (LLMuteList::getInstance()->isMuted(caller_id, LLMute::flagAll & ~LLMute::flagVoiceChat)) + { + LL_INFOS() << "Rejecting session invite from initiating muted resident " << caller_name << LL_ENDL; + return; } - return; } LLVoiceChannel* channelp = LLVoiceChannel::getChannelByID(session_id); @@ -3069,8 +3077,8 @@ void LLIMMgr::inviteToSession( { if (caller_name.empty()) { - gCacheName->get(caller_id, false, // voice - boost::bind(&LLIMMgr::onInviteNameLookup, payload, _1, _2, _3)); + LLAvatarNameCache::get(caller_id, + boost::bind(&LLIMMgr::onInviteNameLookup, payload, _1, _2)); } else { @@ -3089,9 +3097,9 @@ void LLIMMgr::inviteToSession( } } -void LLIMMgr::onInviteNameLookup(LLSD payload, const LLUUID& id, const std::string& name, bool is_group) +void LLIMMgr::onInviteNameLookup(LLSD payload, const LLUUID& id, const LLAvatarName& av_name) { - payload["caller_name"] = name; + payload["caller_name"] = av_name.getUserName(); payload["session_name"] = payload["caller_name"].asString(); std::string notify_box_type = payload["notify_box_type"].asString(); diff --git a/indra/newview/llimview.h b/indra/newview/llimview.h index da40ac8393..e3851a56e0 100644 --- a/indra/newview/llimview.h +++ b/indra/newview/llimview.h @@ -473,7 +473,7 @@ private: void processIMTypingCore(const LLIMInfo* im_info, BOOL typing); - static void onInviteNameLookup(LLSD payload, const LLUUID& id, const std::string& name, bool is_group); + static void onInviteNameLookup(LLSD payload, const LLUUID& id, const LLAvatarName& name); void notifyObserverSessionAdded(const LLUUID& session_id, const std::string& name, const LLUUID& other_participant_id, bool has_offline_msg); //Triggers when a session has already been added diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp index 1de579d4c3..555c19baac 100644 --- a/indra/newview/llinventorybridge.cpp +++ b/indra/newview/llinventorybridge.cpp @@ -275,8 +275,10 @@ BOOL LLInvFVBridge::cutToClipboard() if (cut_from_marketplacelistings && (LLMarketplaceData::instance().isInActiveFolder(mUUID) || LLMarketplaceData::instance().isListedAndActive(mUUID))) { - // Prompt the user if cutting from a marketplace active listing - LLNotificationsUtil::add("ConfirmMerchantActiveChange", LLSD(), LLSD(), boost::bind(&LLInvFVBridge::callback_cutToClipboard, this, _1, _2)); + LLUUID parent_uuid = obj->getParentUUID(); + BOOL result = perform_cutToClipboard(); + gInventory.addChangedMask(LLInventoryObserver::STRUCTURE, parent_uuid); + return result; } else { @@ -303,11 +305,7 @@ BOOL LLInvFVBridge::callback_cutToClipboard(const LLSD& notification, const LLSD S32 option = LLNotificationsUtil::getSelectedOption(notification, response); if (option == 0) // YES { - const LLInventoryObject* obj = gInventory.getObject(mUUID); - LLUUID parent_uuid = obj->getParentUUID(); - BOOL result = perform_cutToClipboard(); - gInventory.addChangedMask(LLInventoryObserver::STRUCTURE, parent_uuid); - return result; + return perform_cutToClipboard(); } return FALSE; } @@ -3471,7 +3469,24 @@ void LLFolderBridge::pasteFromClipboard() const LLUUID &marketplacelistings_id = model->findCategoryUUIDForType(LLFolderType::FT_MARKETPLACE_LISTINGS, false); const BOOL paste_into_marketplacelistings = model->isObjectDescendentOf(mUUID, marketplacelistings_id); - if (paste_into_marketplacelistings && !LLMarketplaceData::instance().isListed(mUUID) && LLMarketplaceData::instance().isInActiveFolder(mUUID)) + BOOL cut_from_marketplacelistings = FALSE; + if (LLClipboard::instance().isCutMode()) + { + //Items are not removed from folder on "cut", so we need update listing folder on "paste" operation + std::vector<LLUUID> objects; + LLClipboard::instance().pasteFromClipboard(objects); + for (std::vector<LLUUID>::const_iterator iter = objects.begin(); iter != objects.end(); ++iter) + { + const LLUUID& item_id = (*iter); + if(gInventory.isObjectDescendentOf(item_id, marketplacelistings_id) && (LLMarketplaceData::instance().isInActiveFolder(item_id) || + LLMarketplaceData::instance().isListedAndActive(item_id))) + { + cut_from_marketplacelistings = TRUE; + break; + } + } + } + if (cut_from_marketplacelistings || (paste_into_marketplacelistings && !LLMarketplaceData::instance().isListed(mUUID) && LLMarketplaceData::instance().isInActiveFolder(mUUID))) { // Prompt the user if pasting in a marketplace active version listing (note that pasting right under the listing folder root doesn't need a prompt) LLNotificationsUtil::add("ConfirmMerchantActiveChange", LLSD(), LLSD(), boost::bind(&LLFolderBridge::callback_pasteFromClipboard, this, _1, _2)); @@ -3490,7 +3505,20 @@ void LLFolderBridge::callback_pasteFromClipboard(const LLSD& notification, const S32 option = LLNotificationsUtil::getSelectedOption(notification, response); if (option == 0) // YES { + std::vector<LLUUID> objects; + std::set<LLUUID> parent_folders; + LLClipboard::instance().pasteFromClipboard(objects); + for (std::vector<LLUUID>::const_iterator iter = objects.begin(); iter != objects.end(); ++iter) + { + const LLInventoryObject* obj = gInventory.getObject(*iter); + parent_folders.insert(obj->getParentUUID()); + } perform_pasteFromClipboard(); + for (std::set<LLUUID>::const_iterator iter = parent_folders.begin(); iter != parent_folders.end(); ++iter) + { + gInventory.addChangedMask(LLInventoryObserver::STRUCTURE, *iter); + } + } } @@ -3789,6 +3817,7 @@ void LLFolderBridge::buildContextMenuOptions(U32 flags, menuentry_vec_t& items disabled_items.push_back(std::string("New Gesture")); disabled_items.push_back(std::string("New Clothes")); disabled_items.push_back(std::string("New Body Parts")); + disabled_items.push_back(std::string("upload_def")); } if (favorites == mUUID) { @@ -3815,6 +3844,7 @@ void LLFolderBridge::buildContextMenuOptions(U32 flags, menuentry_vec_t& items disabled_items.push_back(std::string("New Gesture")); disabled_items.push_back(std::string("New Clothes")); disabled_items.push_back(std::string("New Body Parts")); + disabled_items.push_back(std::string("upload_def")); } if (marketplace_listings_id == mUUID) { @@ -3864,6 +3894,7 @@ void LLFolderBridge::buildContextMenuOptions(U32 flags, menuentry_vec_t& items items.push_back(std::string("New Gesture")); items.push_back(std::string("New Clothes")); items.push_back(std::string("New Body Parts")); + items.push_back(std::string("upload_def")); } } getClipboardEntries(false, items, disabled_items, flags); @@ -3910,6 +3941,37 @@ void LLFolderBridge::buildContextMenuOptions(U32 flags, menuentry_vec_t& items mWearables=TRUE; } } + else + { + // Mark wearables and allow copy from library + LLInventoryModel* model = getInventoryModel(); + if(!model) return; + const LLInventoryCategory* category = model->getCategory(mUUID); + if (!category) return; + LLFolderType::EType type = category->getPreferredType(); + const bool is_system_folder = LLFolderType::lookupIsProtectedType(type); + + LLFindWearables is_wearable; + LLIsType is_object(LLAssetType::AT_OBJECT); + LLIsType is_gesture(LLAssetType::AT_GESTURE); + + if (checkFolderForContentsOfType(model, is_wearable) || + checkFolderForContentsOfType(model, is_object) || + checkFolderForContentsOfType(model, is_gesture)) + { + mWearables = TRUE; + } + + if (!is_system_folder) + { + items.push_back(std::string("Copy")); + if (!isItemCopyable()) + { + // For some reason there are items in library that can't be copied directly + disabled_items.push_back(std::string("Copy")); + } + } + } // Preemptively disable system folder removal if more than one item selected. if ((flags & FIRST_SELECTED_ITEM) == 0) @@ -3917,7 +3979,7 @@ void LLFolderBridge::buildContextMenuOptions(U32 flags, menuentry_vec_t& items disabled_items.push_back(std::string("Delete System Folder")); } - if (!isMarketplaceListingsFolder()) + if (isAgentInventory() && !isMarketplaceListingsFolder()) { items.push_back(std::string("Share")); if (!canShare()) @@ -3925,6 +3987,9 @@ void LLFolderBridge::buildContextMenuOptions(U32 flags, menuentry_vec_t& items disabled_items.push_back(std::string("Share")); } } + + + // Add menu items that are dependent on the contents of the folder. LLViewerInventoryCategory* category = (LLViewerInventoryCategory *) model->getCategory(mUUID); if (category && (marketplace_listings_id != mUUID)) @@ -3962,7 +4027,6 @@ void LLFolderBridge::buildContextMenuFolderOptions(U32 flags, menuentry_vec_t& const LLUUID trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH); if (trash_id == mUUID) return; if (isItemInTrash()) return; - if (!isAgentInventory()) return; if (!isItemRemovable()) { @@ -3975,9 +4039,10 @@ void LLFolderBridge::buildContextMenuFolderOptions(U32 flags, menuentry_vec_t& // BAP change once we're no longer treating regular categories as ensembles. const bool is_ensemble = (type == LLFolderType::FT_NONE || LLFolderType::lookupIsEnsembleType(type)); + const bool is_agent_inventory = isAgentInventory(); // Only enable calling-card related options for non-system folders. - if (!is_system_folder) + if (!is_system_folder && is_agent_inventory) { LLIsType is_callingcard(LLAssetType::AT_CALLINGCARD); if (mCallingCards || checkFolderForContentsOfType(model, is_callingcard)) @@ -3989,7 +4054,7 @@ void LLFolderBridge::buildContextMenuFolderOptions(U32 flags, menuentry_vec_t& } #ifndef LL_RELEASE_FOR_DOWNLOAD - if (LLFolderType::lookupIsProtectedType(type)) + if (LLFolderType::lookupIsProtectedType(type) && is_agent_inventory) { items.push_back(std::string("Delete System Folder")); } @@ -4006,8 +4071,6 @@ void LLFolderBridge::buildContextMenuFolderOptions(U32 flags, menuentry_vec_t& checkFolderForContentsOfType(model, is_object) || checkFolderForContentsOfType(model, is_gesture) ) { - items.push_back(std::string("Folder Wearables Separator")); - // Only enable add/replace outfit for non-system folders. if (!is_system_folder) { @@ -4018,25 +4081,30 @@ void LLFolderBridge::buildContextMenuFolderOptions(U32 flags, menuentry_vec_t& } items.push_back(std::string("Replace Outfit")); + + if (is_agent_inventory) + { + items.push_back(std::string("Folder Wearables Separator")); + if (is_ensemble) + { + items.push_back(std::string("Wear As Ensemble")); + } + items.push_back(std::string("Remove From Outfit")); + if (!LLAppearanceMgr::getCanRemoveFromCOF(mUUID)) + { + disabled_items.push_back(std::string("Remove From Outfit")); + } + } + if (!LLAppearanceMgr::instance().getCanReplaceCOF(mUUID)) + { + disabled_items.push_back(std::string("Replace Outfit")); + } + if (!LLAppearanceMgr::instance().getCanAddToCOF(mUUID)) + { + disabled_items.push_back(std::string("Add To Outfit")); + } + items.push_back(std::string("Outfit Separator")); } - if (is_ensemble) - { - items.push_back(std::string("Wear As Ensemble")); - } - items.push_back(std::string("Remove From Outfit")); - if (!LLAppearanceMgr::getCanRemoveFromCOF(mUUID)) - { - disabled_items.push_back(std::string("Remove From Outfit")); - } - if (!LLAppearanceMgr::instance().getCanReplaceCOF(mUUID)) - { - disabled_items.push_back(std::string("Replace Outfit")); - } - if (!LLAppearanceMgr::instance().getCanAddToCOF(mUUID)) - { - disabled_items.push_back(std::string("Add To Outfit")); - } - items.push_back(std::string("Outfit Separator")); } } @@ -4273,9 +4341,18 @@ void LLFolderBridge::modifyOutfit(BOOL append) return; } - LLAppearanceMgr::instance().wearInventoryCategory( cat, FALSE, append ); + if (isAgentInventory()) + { + LLAppearanceMgr::instance().wearInventoryCategory(cat, FALSE, append); + } + else + { + // Library, we need to copy content first + LLAppearanceMgr::instance().wearInventoryCategory(cat, TRUE, append); + } } + // +=================================================+ // | LLMarketplaceFolderBridge | // +=================================================+ diff --git a/indra/newview/llinventoryfilter.cpp b/indra/newview/llinventoryfilter.cpp index e995c138b4..1433ea36bf 100644 --- a/indra/newview/llinventoryfilter.cpp +++ b/indra/newview/llinventoryfilter.cpp @@ -40,6 +40,7 @@ #include "llinventorybridge.h" #include "llviewerfoldertype.h" #include "llradiogroup.h" +#include "llstartup.h" // linden library includes #include "llclipboard.h" @@ -132,8 +133,10 @@ bool LLInventoryFilter::checkFolder(const LLUUID& folder_id) const } // when applying a filter, matching folders get their contents downloaded first + // but make sure we are not interfering with pre-download if (isNotDefault() - && !gInventory.isCategoryComplete(folder_id)) + && !gInventory.isCategoryComplete(folder_id) + && LLStartUp::getStartupState() > STATE_WEARABLES_WAIT) { LLInventoryModelBackgroundFetch::instance().start(folder_id); } @@ -307,7 +310,11 @@ bool LLInventoryFilter::checkAgainstFilterType(const LLFolderViewModelItemInvent if (is_hidden_if_empty) { // Force the fetching of those folders so they are hidden if they really are empty... - gInventory.fetchDescendentsOf(object_id); + // But don't interfere with startup download + if (LLStartUp::getStartupState() > STATE_WEARABLES_WAIT) + { + gInventory.fetchDescendentsOf(object_id); + } LLInventoryModel::cat_array_t* cat_array = NULL; LLInventoryModel::item_array_t* item_array = NULL; diff --git a/indra/newview/llinventoryitemslist.h b/indra/newview/llinventoryitemslist.h index fe05c2ed7c..ce41105f98 100644 --- a/indra/newview/llinventoryitemslist.h +++ b/indra/newview/llinventoryitemslist.h @@ -61,6 +61,11 @@ public: */ void setForceRefresh(bool force_refresh){ mForceRefresh = force_refresh; } + /** + * If refreshes when invisible. + */ + bool getForceRefresh(){ return mForceRefresh; } + virtual bool selectItemByValue(const LLSD& value, bool select = true); void updateSelection(); diff --git a/indra/newview/llinventorylistitem.cpp b/indra/newview/llinventorylistitem.cpp index 0601796436..12bb609df8 100644 --- a/indra/newview/llinventorylistitem.cpp +++ b/indra/newview/llinventorylistitem.cpp @@ -182,10 +182,10 @@ void LLPanelInventoryListItemBase::setValue(const LLSD& value) mSelected = value["selected"]; } -void LLPanelInventoryListItemBase::onMouseEnter(S32 x, S32 y, MASK mask) +BOOL LLPanelInventoryListItemBase::handleHover(S32 x, S32 y, MASK mask) { mHovered = true; - LLPanel::onMouseEnter(x, y, mask); + return LLPanel::handleHover(x, y, mask); } void LLPanelInventoryListItemBase::onMouseLeave(S32 x, S32 y, MASK mask) diff --git a/indra/newview/llinventorylistitem.h b/indra/newview/llinventorylistitem.h index b1ef6c74ee..d4dd212cc3 100644 --- a/indra/newview/llinventorylistitem.h +++ b/indra/newview/llinventorylistitem.h @@ -129,8 +129,8 @@ public: */ /*virtual*/ S32 notify(const LLSD& info); - /* Highlights item */ - /*virtual*/ void onMouseEnter(S32 x, S32 y, MASK mask); + /* Highlights item */ + /*virtual*/ BOOL handleHover(S32 x, S32 y, MASK mask); /* Removes item highlight */ /*virtual*/ void onMouseLeave(S32 x, S32 y, MASK mask); @@ -153,6 +153,7 @@ public: LLViewerInventoryItem* getItem() const; void setSeparatorVisible(bool visible) { mSeparatorVisible = visible; } + void resetHighlight() { mHovered = FALSE; } virtual ~LLPanelInventoryListItemBase(){} diff --git a/indra/newview/llinventorymodel.cpp b/indra/newview/llinventorymodel.cpp index 503fa28a33..855f7c750e 100644 --- a/indra/newview/llinventorymodel.cpp +++ b/indra/newview/llinventorymodel.cpp @@ -34,6 +34,7 @@ #include "llagent.h" #include "llagentwearables.h" #include "llappearancemgr.h" +#include "llavatarnamecache.h" #include "llclipboard.h" #include "llinventorypanel.h" #include "llinventorybridge.h" @@ -515,6 +516,42 @@ const LLUUID LLInventoryModel::findCategoryUUIDForType(LLFolderType::EType prefe return findCategoryUUIDForTypeInRoot(preferred_type, create_folder, gInventory.getRootFolderID()); } +const LLUUID LLInventoryModel::findUserDefinedCategoryUUIDForType(LLFolderType::EType preferred_type) +{ + LLUUID cat_id; + switch (preferred_type) + { + case LLFolderType::FT_OBJECT: + { + cat_id = LLUUID(gSavedPerAccountSettings.getString("ModelUploadFolder")); + break; + } + case LLFolderType::FT_TEXTURE: + { + cat_id = LLUUID(gSavedPerAccountSettings.getString("TextureUploadFolder")); + break; + } + case LLFolderType::FT_SOUND: + { + cat_id = LLUUID(gSavedPerAccountSettings.getString("SoundUploadFolder")); + break; + } + case LLFolderType::FT_ANIMATION: + { + cat_id = LLUUID(gSavedPerAccountSettings.getString("AnimationUploadFolder")); + break; + } + default: + break; + } + + if (cat_id.isNull() || !getCategory(cat_id)) + { + cat_id = findCategoryUUIDForTypeInRoot(preferred_type, true, getRootFolderID()); + } + return cat_id; +} + const LLUUID LLInventoryModel::findLibraryCategoryUUIDForType(LLFolderType::EType preferred_type, bool create_folder) { return findCategoryUUIDForTypeInRoot(preferred_type, create_folder, gInventory.getLibraryRootFolderID()); @@ -986,19 +1023,19 @@ U32 LLInventoryModel::updateItem(const LLViewerInventoryItem* item, U32 mask) { // Valid UUID; set the item UUID and rename it new_item->setCreator(id); - std::string avatar_name; + LLAvatarName av_name; - if (gCacheName->getFullName(id, avatar_name)) + if (LLAvatarNameCache::get(id, &av_name)) { - new_item->rename(avatar_name); + new_item->rename(av_name.getUserName()); mask |= LLInventoryObserver::LABEL; } else { // Fetch the current name - gCacheName->get(id, FALSE, + LLAvatarNameCache::get(id, boost::bind(&LLViewerInventoryItem::onCallingCardNameLookup, new_item.get(), - _1, _2, _3)); + _1, _2)); } } diff --git a/indra/newview/llinventorymodel.h b/indra/newview/llinventorymodel.h index 826d1f880d..dee1769172 100644 --- a/indra/newview/llinventorymodel.h +++ b/indra/newview/llinventorymodel.h @@ -287,6 +287,9 @@ public: // will search in the user's library folder instead of "My Inventory" const LLUUID findLibraryCategoryUUIDForType(LLFolderType::EType preferred_type, bool create_folder = true); + // Returns user specified category for uploads, returns default id if there are no + // user specified one or it does not exist, creates default category if it is missing. + const LLUUID findUserDefinedCategoryUUIDForType(LLFolderType::EType preferred_type); // Get whatever special folder this object is a child of, if any. const LLViewerInventoryCategory *getFirstNondefaultParent(const LLUUID& obj_id) const; diff --git a/indra/newview/llinventorymodelbackgroundfetch.cpp b/indra/newview/llinventorymodelbackgroundfetch.cpp index 4a77edc565..a8919db828 100644 --- a/indra/newview/llinventorymodelbackgroundfetch.cpp +++ b/indra/newview/llinventorymodelbackgroundfetch.cpp @@ -360,9 +360,12 @@ void LLInventoryModelBackgroundFetch::incrFetchCount(S32 fetching) } } +static LLTrace::BlockTimerStatHandle FTM_BULK_FETCH("Bulk Fetch"); + // Bundle up a bunch of requests to send all at once. void LLInventoryModelBackgroundFetch::bulkFetch() { + LL_RECORD_BLOCK_TIME(FTM_BULK_FETCH); //Background fetch is called from gIdleCallbacks in a loop until background fetch is stopped. //If there are items in mFetchQueue, we want to check the time since the last bulkFetch was //sent. If it exceeds our retry time, go ahead and fire off another batch. diff --git a/indra/newview/llinventorypanel.cpp b/indra/newview/llinventorypanel.cpp index 6a27c0fe21..bd15ba4975 100644 --- a/indra/newview/llinventorypanel.cpp +++ b/indra/newview/llinventorypanel.cpp @@ -167,7 +167,7 @@ LLInventoryPanel::LLInventoryPanel(const LLInventoryPanel::Params& p) : mCommitCallbackRegistrar.add("Inventory.AttachObject", boost::bind(&LLInventoryPanel::attachObject, this, _2)); mCommitCallbackRegistrar.add("Inventory.BeginIMSession", boost::bind(&LLInventoryPanel::beginIMSession, this)); mCommitCallbackRegistrar.add("Inventory.Share", boost::bind(&LLAvatarActions::shareWithAvatars, this)); - + mCommitCallbackRegistrar.add("Inventory.FileUploadLocation", boost::bind(&LLInventoryPanel::fileUploadLocation, this, _2)); } LLFolderView * LLInventoryPanel::createFolderRoot(LLUUID root_id ) @@ -1190,6 +1190,27 @@ bool LLInventoryPanel::beginIMSession() return true; } +void LLInventoryPanel::fileUploadLocation(const LLSD& userdata) +{ + const std::string param = userdata.asString(); + if (param == "model") + { + gSavedPerAccountSettings.setString("ModelUploadFolder", LLFolderBridge::sSelf.get()->getUUID().asString()); + } + else if (param == "texture") + { + gSavedPerAccountSettings.setString("TextureUploadFolder", LLFolderBridge::sSelf.get()->getUUID().asString()); + } + else if (param == "sound") + { + gSavedPerAccountSettings.setString("SoundUploadFolder", LLFolderBridge::sSelf.get()->getUUID().asString()); + } + else if (param == "animation") + { + gSavedPerAccountSettings.setString("AnimationUploadFolder", LLFolderBridge::sSelf.get()->getUUID().asString()); + } +} + bool LLInventoryPanel::attachObject(const LLSD& userdata) { // Copy selected item UUIDs to a vector. diff --git a/indra/newview/llinventorypanel.h b/indra/newview/llinventorypanel.h index b69edd8b93..5cb9dde47a 100644 --- a/indra/newview/llinventorypanel.h +++ b/indra/newview/llinventorypanel.h @@ -201,6 +201,7 @@ public: void doToSelected(const LLSD& userdata); void doCreate(const LLSD& userdata); bool beginIMSession(); + void fileUploadLocation(const LLSD& userdata); bool attachObject(const LLSD& userdata); static void idle(void* user_data); diff --git a/indra/newview/llloginhandler.cpp b/indra/newview/llloginhandler.cpp index 39f3c0f113..eca34c0d4d 100644 --- a/indra/newview/llloginhandler.cpp +++ b/indra/newview/llloginhandler.cpp @@ -168,7 +168,6 @@ LLPointer<LLCredential> LLLoginHandler::loadSavedUserLoginInfo() authenticator["algorithm"] = "md5"; authenticator["secret"] = md5pass; // yuck, we'll fix this with mani's changes. - gSavedSettings.setBOOL("AutoLogin", TRUE); return gSecAPIHandler->createCredential(LLGridManager::getInstance()->getGrid(), identifier, authenticator); } diff --git a/indra/newview/lllogininstance.cpp b/indra/newview/lllogininstance.cpp index b4d0bb6823..a49a9ca840 100644 --- a/indra/newview/lllogininstance.cpp +++ b/indra/newview/lllogininstance.cpp @@ -606,6 +606,7 @@ void LLLoginInstance::constructAuthParams(LLPointer<LLCredential> user_credentia request_params["channel"] = LLVersionInfo::getChannel(); request_params["platform"] = mPlatform; request_params["platform_version"] = mPlatformVersion; + request_params["address_size"] = ADDRESS_SIZE; request_params["id0"] = mSerialNumber; request_params["host_id"] = gSavedSettings.getString("HostID"); request_params["extended_errors"] = true; // request message_id and message_args diff --git a/indra/newview/llmarketplacefunctions.cpp b/indra/newview/llmarketplacefunctions.cpp index 54f95520db..a0e19f2d19 100644 --- a/indra/newview/llmarketplacefunctions.cpp +++ b/indra/newview/llmarketplacefunctions.cpp @@ -121,7 +121,6 @@ namespace { { // Prompt the user with the warning (so they know why things are failing) LLSD subs; - subs["[ERROR_REASON]"] = reason; // We do show long descriptions in the alert (unlikely to be readable). The description string will be in the log though. std::string description; if (result.has(LLCoreHttpUtil::HttpCoroutineAdapter::HTTP_RESULTS_CONTENT)) @@ -145,6 +144,16 @@ namespace { { description = result.asString(); } + std::string reason_lc = reason; + LLStringUtil::toLower(reason_lc); + if (!description.empty() && reason_lc.find("unknown") != std::string::npos) + { + subs["[ERROR_REASON]"] = ""; + } + else + { + subs["[ERROR_REASON]"] = "'" + reason +"'\n"; + } subs["[ERROR_DESCRIPTION]"] = description; LLNotificationsUtil::add("MerchantTransactionFailed", subs); } diff --git a/indra/newview/llmeshrepository.cpp b/indra/newview/llmeshrepository.cpp index 9dacae2c4e..1a533dace7 100644 --- a/indra/newview/llmeshrepository.cpp +++ b/indra/newview/llmeshrepository.cpp @@ -2030,8 +2030,8 @@ void LLMeshUploadThread::wholeModelToLLSD(LLSD& dest, bool include_textures) LLSD result; LLSD res; - result["folder_id"] = gInventory.findCategoryUUIDForType(LLFolderType::FT_OBJECT); - result["texture_folder_id"] = gInventory.findCategoryUUIDForType(LLFolderType::FT_TEXTURE); + result["folder_id"] = gInventory.findUserDefinedCategoryUUIDForType(LLFolderType::FT_OBJECT); + result["texture_folder_id"] = gInventory.findUserDefinedCategoryUUIDForType(LLFolderType::FT_TEXTURE); result["asset_type"] = "mesh"; result["inventory_type"] = "object"; result["description"] = "(No Description)"; @@ -3536,11 +3536,11 @@ void LLMeshRepository::notifyLoadedMeshes() // Handle addition of texture, if any. if ( data.mResponse.has("new_texture_folder_id") ) { - const LLUUID& folder_id = data.mResponse["new_texture_folder_id"].asUUID(); + const LLUUID& new_folder_id = data.mResponse["new_texture_folder_id"].asUUID(); - if ( folder_id.notNull() ) + if ( new_folder_id.notNull() ) { - LLUUID parent_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TEXTURE); + LLUUID parent_id = gInventory.findUserDefinedCategoryUUIDForType(LLFolderType::FT_TEXTURE); std::string name; // Check if the server built a different name for the texture folder @@ -3555,7 +3555,7 @@ void LLMeshRepository::notifyLoadedMeshes() // Add the category to the internal representation LLPointer<LLViewerInventoryCategory> cat = - new LLViewerInventoryCategory(folder_id, parent_id, + new LLViewerInventoryCategory(new_folder_id, parent_id, LLFolderType::FT_NONE, name, gAgent.getID()); cat->setVersion(LLViewerInventoryCategory::VERSION_UNKNOWN); diff --git a/indra/newview/llmoveview.cpp b/indra/newview/llmoveview.cpp index c3dd08c327..4999318973 100644 --- a/indra/newview/llmoveview.cpp +++ b/indra/newview/llmoveview.cpp @@ -730,9 +730,16 @@ void LLPanelStandStopFlying::updatePosition() panel_ssf_container->setOrigin(0, y_pos); } - S32 x_pos = bottom_tb_center-getRect().getWidth()/2 - left_tb_width; - - setOrigin( x_pos, 0); + if (gToolBarView != NULL && gToolBarView->getToolbar(LLToolBarEnums::TOOLBAR_LEFT)->hasButtons()) + { + S32 x_pos = bottom_tb_center - getRect().getWidth() / 2 - left_tb_width; + setOrigin( x_pos, 0); + } + else + { + S32 x_pos = bottom_tb_center - getRect().getWidth() / 2; + setOrigin( x_pos, 0); + } } // EOF diff --git a/indra/newview/llmutelist.cpp b/indra/newview/llmutelist.cpp index 0f70c9d13f..02b28a2bf8 100644 --- a/indra/newview/llmutelist.cpp +++ b/indra/newview/llmutelist.cpp @@ -53,6 +53,7 @@ #include "llxfermanager.h" #include "llagent.h" +#include "llavatarnamecache.h" #include "llviewergenericmessage.h" // for gGenericDispatcher #include "llworld.h" //for particle system banning #include "llimview.h" @@ -456,7 +457,7 @@ void LLMuteList::updateRemove(const LLMute& mute) gAgent.sendReliableMessage(); } -void notify_automute_callback(const LLUUID& agent_id, const std::string& full_name, bool is_group, LLMuteList::EAutoReason reason) +void notify_automute_callback(const LLUUID& agent_id, const LLAvatarName& full_name, LLMuteList::EAutoReason reason) { std::string notif_name; switch (reason) @@ -474,7 +475,7 @@ void notify_automute_callback(const LLUUID& agent_id, const std::string& full_na } LLSD args; - args["NAME"] = full_name; + args["NAME"] = full_name.getUserName(); LLNotificationPtr notif_ptr = LLNotifications::instance().add(notif_name, args, LLSD()); if (notif_ptr) @@ -499,17 +500,17 @@ BOOL LLMuteList::autoRemove(const LLUUID& agent_id, const EAutoReason reason) removed = TRUE; remove(automute); - std::string full_name; - if (gCacheName->getFullName(agent_id, full_name)) - { - // name in cache, call callback directly - notify_automute_callback(agent_id, full_name, false, reason); - } - else - { - // not in cache, lookup name from cache - gCacheName->get(agent_id, false, - boost::bind(¬ify_automute_callback, _1, _2, _3, reason)); + LLAvatarName av_name; + if (LLAvatarNameCache::get(agent_id, &av_name)) + { + // name in cache, call callback directly + notify_automute_callback(agent_id, av_name, reason); + } + else + { + // not in cache, lookup name from cache + LLAvatarNameCache::get(agent_id, + boost::bind(¬ify_automute_callback, _1, _2, reason)); } } @@ -811,3 +812,99 @@ void LLMuteList::notifyObserversDetailed(const LLMute& mute) it = mObservers.upper_bound(observer); } } + +LLRenderMuteList::LLRenderMuteList() +{} + +bool LLRenderMuteList::saveToFile() +{ + std::string filename = gDirUtilp->getExpandedFilename(LL_PATH_PER_SL_ACCOUNT, "render_mute_settings.txt"); + LLFILE* fp = LLFile::fopen(filename, "wb"); + if (!fp) + { + LL_WARNS() << "Couldn't open render mute list file: " << filename << LL_ENDL; + return false; + } + for (std::map<LLUUID, S32>::iterator it = sVisuallyMuteSettingsMap.begin(); it != sVisuallyMuteSettingsMap.end(); ++it) + { + if (it->second != 0) + { + std::string id_string; + it->first.toString(id_string); + fprintf(fp, "%d %s\n", (S32)it->second, id_string.c_str()); + } + } + fclose(fp); + return true; +} + +bool LLRenderMuteList::loadFromFile() +{ + std::string filename = gDirUtilp->getExpandedFilename(LL_PATH_PER_SL_ACCOUNT, "render_mute_settings.txt"); + LLFILE* fp = LLFile::fopen(filename, "rb"); + if (!fp) + { + LL_WARNS() << "Couldn't open render mute list file: " << filename << LL_ENDL; + return false; + } + + char id_buffer[MAX_STRING]; + char buffer[MAX_STRING]; + while (!feof(fp) && fgets(buffer, MAX_STRING, fp)) + { + id_buffer[0] = '\0'; + S32 setting = 0; + sscanf(buffer, " %d %254s\n", &setting, id_buffer); + sVisuallyMuteSettingsMap[LLUUID(id_buffer)] = setting; + } + fclose(fp); + return true; +} + +void LLRenderMuteList::saveVisualMuteSetting(const LLUUID& agent_id, S32 setting) +{ + if(setting == 0) + { + sVisuallyMuteSettingsMap.erase(agent_id); + } + else + { + sVisuallyMuteSettingsMap[agent_id] = setting; + } + saveToFile(); + notifyObservers(); +} + +S32 LLRenderMuteList::getSavedVisualMuteSetting(const LLUUID& agent_id) +{ + std::map<LLUUID, S32>::iterator iter = sVisuallyMuteSettingsMap.find(agent_id); + if (iter != sVisuallyMuteSettingsMap.end()) + { + return iter->second; + } + + return 0; +} + +void LLRenderMuteList::addObserver(LLMuteListObserver* observer) +{ + mObservers.insert(observer); +} + +void LLRenderMuteList::removeObserver(LLMuteListObserver* observer) +{ + mObservers.erase(observer); +} + +void LLRenderMuteList::notifyObservers() +{ + for (observer_set_t::iterator it = mObservers.begin(); + it != mObservers.end(); + ) + { + LLMuteListObserver* observer = *it; + observer->onChange(); + // In case onChange() deleted an entry. + it = mObservers.upper_bound(observer); + } +} diff --git a/indra/newview/llmutelist.h b/indra/newview/llmutelist.h index 4ceddc97fd..9ab978353b 100644 --- a/indra/newview/llmutelist.h +++ b/indra/newview/llmutelist.h @@ -175,5 +175,25 @@ public: virtual void onChangeDetailed(const LLMute& ) { } }; +class LLRenderMuteList : public LLSingleton<LLRenderMuteList> +{ + LLSINGLETON(LLRenderMuteList); +public: + bool loadFromFile(); + bool saveToFile(); + S32 getSavedVisualMuteSetting(const LLUUID& agent_id); + void saveVisualMuteSetting(const LLUUID& agent_id, S32 setting); + + void addObserver(LLMuteListObserver* observer); + void removeObserver(LLMuteListObserver* observer); + + std::map<LLUUID, S32> sVisuallyMuteSettingsMap; + +private: + void notifyObservers(); + typedef std::set<LLMuteListObserver*> observer_set_t; + observer_set_t mObservers; +}; + #endif //LL_MUTELIST_H diff --git a/indra/newview/llnamebox.cpp b/indra/newview/llnamebox.cpp index 1099316a19..8d32fb1d5c 100644 --- a/indra/newview/llnamebox.cpp +++ b/indra/newview/llnamebox.cpp @@ -35,6 +35,7 @@ #include "lluuid.h" #include "llcachename.h" +#include "llavatarnamecache.h" // statics std::set<LLNameBox*> LLNameBox::sInstances; @@ -67,7 +68,9 @@ void LLNameBox::setNameID(const LLUUID& name_id, BOOL is_group) if (!is_group) { - got_name = gCacheName->getFullName(name_id, name); + LLAvatarName av_name; + got_name = LLAvatarNameCache::get(name_id, &av_name); + name = av_name.getUserName(); } else { diff --git a/indra/newview/llnameeditor.cpp b/indra/newview/llnameeditor.cpp index b3b1ff7c06..055754f270 100644 --- a/indra/newview/llnameeditor.cpp +++ b/indra/newview/llnameeditor.cpp @@ -28,6 +28,7 @@ #include "llnameeditor.h" #include "llcachename.h" +#include "llavatarnamecache.h" #include "llfontgl.h" @@ -65,7 +66,9 @@ void LLNameEditor::setNameID(const LLUUID& name_id, BOOL is_group) if (!is_group) { - gCacheName->getFullName(name_id, name); + LLAvatarName av_name; + LLAvatarNameCache::get(name_id, &av_name); + name = av_name.getUserName(); } else { diff --git a/indra/newview/llnotificationhandlerutil.cpp b/indra/newview/llnotificationhandlerutil.cpp index a078889d46..4a3923ef6e 100644 --- a/indra/newview/llnotificationhandlerutil.cpp +++ b/indra/newview/llnotificationhandlerutil.cpp @@ -114,11 +114,11 @@ void LLHandlerUtil::logToIM(const EInstantMessage& session_type, } } -void log_name_callback(const std::string& full_name, const std::string& from_name, +void log_name_callback(const LLAvatarName& av_name, const std::string& from_name, const std::string& message, const LLUUID& from_id) { - LLHandlerUtil::logToIM(IM_NOTHING_SPECIAL, full_name, from_name, message, + LLHandlerUtil::logToIM(IM_NOTHING_SPECIAL, av_name.getUserName(), from_name, message, from_id, LLUUID()); } @@ -141,11 +141,11 @@ void LLHandlerUtil::logToIMP2P(const LLNotificationPtr& notification, bool to_fi if(to_file_only) { - gCacheName->get(from_id, false, boost::bind(&log_name_callback, _2, "", notification->getMessage(), LLUUID())); + LLAvatarNameCache::get(from_id, boost::bind(&log_name_callback, _2, "", notification->getMessage(), LLUUID())); } else { - gCacheName->get(from_id, false, boost::bind(&log_name_callback, _2, INTERACTIVE_SYSTEM_FROM, notification->getMessage(), from_id)); + LLAvatarNameCache::get(from_id, boost::bind(&log_name_callback, _2, INTERACTIVE_SYSTEM_FROM, notification->getMessage(), from_id)); } } @@ -167,9 +167,18 @@ void LLHandlerUtil::logGroupNoticeToIMGroup( const std::string group_name = groupData.mName; const std::string sender_name = payload["sender_name"].asString(); - // we can't retrieve sender id from group notice system message, so try to lookup it from cache LLUUID sender_id; - gCacheName->getUUID(sender_name, sender_id); + if (payload.has("sender_id")) + { + sender_id = payload["sender_id"].asUUID(); + } + + if (sender_id.notNull()) + { + // Legacy support and fallback method + // if we can't retrieve sender id from group notice system message, try to lookup it from cache + sender_id = LLAvatarNameCache::findIdByName(sender_name); + } logToIM(IM_SESSION_GROUP_START, group_name, sender_name, payload["message"], payload["group_id"], sender_id); @@ -219,7 +228,12 @@ std::string LLHandlerUtil::getSubstitutionName(const LLNotificationPtr& notifica { from_id = notification->getPayload()["from_id"]; } - if(!gCacheName->getFullName(from_id, res)) + LLAvatarName av_name; + if(LLAvatarNameCache::get(from_id, &av_name)) + { + res = av_name.getUserName(); + } + else { res = ""; } diff --git a/indra/newview/llpanelblockedlist.cpp b/indra/newview/llpanelblockedlist.cpp index 81ed2963e6..25ae4774fc 100644 --- a/indra/newview/llpanelblockedlist.cpp +++ b/indra/newview/llpanelblockedlist.cpp @@ -141,6 +141,9 @@ void LLPanelBlockedList::updateButtons() bool hasSelected = NULL != mBlockedList->getSelectedItem(); getChildView("unblock_btn")->setEnabled(hasSelected); getChildView("blocked_gear_btn")->setEnabled(hasSelected); + + getChild<LLUICtrl>("block_limit")->setTextArg("[COUNT]", llformat("%d", mBlockedList->getMuteListSize())); + getChild<LLUICtrl>("block_limit")->setTextArg("[LIMIT]", llformat("%d", gSavedSettings.getS32("MuteListLimit"))); } void LLPanelBlockedList::unblockItem() diff --git a/indra/newview/llpanelface.cpp b/indra/newview/llpanelface.cpp index ec2d37c30d..ad600358dd 100644 --- a/indra/newview/llpanelface.cpp +++ b/indra/newview/llpanelface.cpp @@ -649,7 +649,7 @@ void LLPanelFace::getState() updateUI(); } -void LLPanelFace::updateUI() +void LLPanelFace::updateUI(bool force_set_values /*false*/) { //set state of UI to match state of texture entry(ies) (calls setEnabled, setValue, etc, but NOT setVisible) LLViewerObject* objectp = LLSelectMgr::getInstance()->getSelection()->getFirstObject(); @@ -1025,7 +1025,14 @@ void LLPanelFace::updateUI() getChildView("shinyScaleV")->setEnabled(editable && specmap_id.notNull()); getChildView("bumpyScaleV")->setEnabled(editable && normmap_id.notNull()); - getChild<LLUICtrl>("TexScaleV")->setValue(diff_scale_t); + if (force_set_values) + { + getChild<LLSpinCtrl>("TexScaleV")->forceSetValue(diff_scale_t); + } + else + { + getChild<LLSpinCtrl>("TexScaleV")->setValue(diff_scale_t); + } getChild<LLUICtrl>("shinyScaleV")->setValue(norm_scale_t); getChild<LLUICtrl>("bumpyScaleV")->setValue(spec_scale_t); @@ -1235,8 +1242,17 @@ void LLPanelFace::updateUI() BOOL repeats_tentative = !identical_repeats; getChildView("rptctrl")->setEnabled(identical_planar_texgen ? FALSE : enabled); - getChild<LLUICtrl>("rptctrl")->setValue(editable ? repeats : 1.0f); - getChild<LLUICtrl>("rptctrl")->setTentative(LLSD(repeats_tentative)); + LLSpinCtrl* rpt_ctrl = getChild<LLSpinCtrl>("rptctrl"); + if (force_set_values) + { + //onCommit, previosly edited element updates related ones + rpt_ctrl->forceSetValue(editable ? repeats : 1.0f); + } + else + { + rpt_ctrl->setValue(editable ? repeats : 1.0f); + } + rpt_ctrl->setTentative(LLSD(repeats_tentative)); } } @@ -1974,6 +1990,8 @@ void LLPanelFace::onCommitTextureInfo( LLUICtrl* ctrl, void* userdata ) { LLPanelFace* self = (LLPanelFace*) userdata; self->sendTextureInfo(); + // vertical scale and repeats per meter depends on each other, so force set on changes + self->updateUI(true); } // Commit the number of repeats per meter @@ -2038,6 +2056,8 @@ void LLPanelFace::onCommitRepeatsPerMeter(LLUICtrl* ctrl, void* userdata) llassert(false); break; } + // vertical scale and repeats per meter depends on each other, so force set on changes + self->updateUI(true); } struct LLPanelFaceSetMediaFunctor : public LLSelectedTEFunctor diff --git a/indra/newview/llpanelface.h b/indra/newview/llpanelface.h index 9823e84cd9..078995e787 100644 --- a/indra/newview/llpanelface.h +++ b/indra/newview/llpanelface.h @@ -152,7 +152,8 @@ protected: // Make UI reflect state of currently selected material (refresh) // and UI mode (e.g. editing normal map v diffuse map) // - void updateUI(); + // @param force_set_values forces spinners to set value even if they are focused + void updateUI(bool force_set_values = false); // Convenience func to determine if all faces in selection have // identical planar texgen settings during edits diff --git a/indra/newview/llpanelgrouproles.cpp b/indra/newview/llpanelgrouproles.cpp index 00c204e702..8440e9ee50 100644 --- a/indra/newview/llpanelgrouproles.cpp +++ b/indra/newview/llpanelgrouproles.cpp @@ -1168,9 +1168,9 @@ void LLPanelGroupMembersSubTab::confirmEjectMembers() if (selection_count == 1) { LLSD args; - std::string fullname; - gCacheName->getFullName(mMembersList->getValue(), fullname); - args["AVATAR_NAME"] = fullname; + LLAvatarName av_name; + LLAvatarNameCache::get(mMembersList->getValue(), &av_name); + args["AVATAR_NAME"] = av_name.getUserName(); LLSD payload; LLNotificationsUtil::add("EjectGroupMemberWarning", args, @@ -1231,7 +1231,7 @@ void LLPanelGroupMembersSubTab::sendEjectNotifications(const LLUUID& group_id, c for (uuid_vec_t::const_iterator i = selected_members.begin(); i != selected_members.end(); ++i) { LLSD args; - args["AVATAR_NAME"] = LLSLURL("agent", *i, "displayname").getSLURLString(); + args["AVATAR_NAME"] = LLSLURL("agent", *i, "completename").getSLURLString(); args["GROUP_NAME"] = group_data->mName; LLNotifications::instance().add(LLNotification::Params("EjectAvatarFromGroup").substitutions(args)); @@ -1862,9 +1862,9 @@ void LLPanelGroupMembersSubTab::confirmBanMembers() if (selection_count == 1) { LLSD args; - std::string fullname; - gCacheName->getFullName(mMembersList->getValue(), fullname); - args["AVATAR_NAME"] = fullname; + LLAvatarName av_name; + LLAvatarNameCache::get(mMembersList->getValue(), &av_name); + args["AVATAR_NAME"] = av_name.getUserName(); LLSD payload; LLNotificationsUtil::add("BanGroupMemberWarning", args, diff --git a/indra/newview/llpanelobjectinventory.cpp b/indra/newview/llpanelobjectinventory.cpp index c4211d5508..6409620336 100644 --- a/indra/newview/llpanelobjectinventory.cpp +++ b/indra/newview/llpanelobjectinventory.cpp @@ -1519,6 +1519,7 @@ LLPanelObjectInventory::LLPanelObjectInventory(const LLPanelObjectInventory::Par mCommitCallbackRegistrar.add("Inventory.AttachObject", boost::bind(&do_nothing)); mCommitCallbackRegistrar.add("Inventory.BeginIMSession", boost::bind(&do_nothing)); mCommitCallbackRegistrar.add("Inventory.Share", boost::bind(&LLAvatarActions::shareWithAvatars, this)); + mCommitCallbackRegistrar.add("Inventory.FileUploadLocation", boost::bind(&do_nothing)); } // Destroys the object @@ -1849,6 +1850,7 @@ void LLPanelObjectInventory::refresh() if(mTaskUUID != object->mID) { mTaskUUID = object->mID; + mAttachmentUUID = object->getAttachmentItemID(); make_request = TRUE; // This is a new object so pre-emptively clear the contents @@ -1858,6 +1860,16 @@ void LLPanelObjectInventory::refresh() // Register for updates from this object, registerVOInventoryListener(object,NULL); } + else if (mAttachmentUUID != object->getAttachmentItemID()) + { + mAttachmentUUID = object->getAttachmentItemID(); + if (mAttachmentUUID.notNull()) + { + // Server unsubsribes viewer (deselects object) from property + // updates after "ObjectAttach" so we need to resubscribe + LLSelectMgr::getInstance()->sendSelect(); + } + } // Based on the node information, we may need to dirty the // object inventory and get it again. @@ -1888,6 +1900,7 @@ void LLPanelObjectInventory::refresh() void LLPanelObjectInventory::clearInventoryTask() { mTaskUUID = LLUUID::null; + mAttachmentUUID = LLUUID::null; removeVOInventoryListener(); clearContents(); } diff --git a/indra/newview/llpanelobjectinventory.h b/indra/newview/llpanelobjectinventory.h index 3de49242ac..d700c8f4cf 100644 --- a/indra/newview/llpanelobjectinventory.h +++ b/indra/newview/llpanelobjectinventory.h @@ -105,6 +105,7 @@ private: LLFolderView* mFolders; LLUUID mTaskUUID; + LLUUID mAttachmentUUID; BOOL mHaveInventory; BOOL mIsInventoryEmpty; BOOL mInventoryNeedsUpdate; diff --git a/indra/newview/llpaneloutfitedit.cpp b/indra/newview/llpaneloutfitedit.cpp index 208ee77f2d..3f6bdde127 100644 --- a/indra/newview/llpaneloutfitedit.cpp +++ b/indra/newview/llpaneloutfitedit.cpp @@ -578,7 +578,6 @@ void LLPanelOutfitEdit::onOpen(const LLSD& key) // *TODO: this method is called even panel is not visible to user because its parent layout panel is hidden. // So, we can defer initializing a bit. mWearableListManager = new LLFilteredWearableListManager(mWearableItemsList, mListViewItemTypes[LVIT_ALL]->collector); - mWearableListManager->populateList(); displayCurrentOutfit(); mInitialized = true; } @@ -632,6 +631,10 @@ void LLPanelOutfitEdit::showAddWearablesPanel(bool show_add_wearables) // Reset mWearableItemsList position to top. See EXT-8180. mWearableItemsList->goToTop(); } + else + { + mWearableListManager->populateIfNeeded(); + } //switching button bars getChildView("no_add_wearables_button_bar")->setVisible( !show_add_wearables); @@ -661,6 +664,7 @@ void LLPanelOutfitEdit::showWearablesListView() { updateWearablesPanelVerbButtons(); updateFiltersVisibility(); + mWearableListManager->populateIfNeeded(); } mListViewBtn->setToggleState(TRUE); } diff --git a/indra/newview/llpanelpicks.cpp b/indra/newview/llpanelpicks.cpp index 55c09d85ea..77bc99da83 100644 --- a/indra/newview/llpanelpicks.cpp +++ b/indra/newview/llpanelpicks.cpp @@ -384,9 +384,9 @@ void LLPanelPicks::processProperties(void* data, EAvatarProcessorType type) LLAvatarPicks* avatar_picks = static_cast<LLAvatarPicks*>(data); if(avatar_picks && getAvatarId() == avatar_picks->target_id) { - std::string full_name; - gCacheName->getFullName(getAvatarId(), full_name); - getChild<LLUICtrl>("pick_title")->setTextArg("[NAME]", full_name); + LLAvatarName av_name; + LLAvatarNameCache::get(getAvatarId(), &av_name); + getChild<LLUICtrl>("pick_title")->setTextArg("[NAME]", av_name.getUserName()); // Save selection, to be able to edit same item after saving changes. See EXT-3023. LLUUID selected_id = mPicksList->getSelectedValue()[PICK_ID]; diff --git a/indra/newview/llpanelplaces.cpp b/indra/newview/llpanelplaces.cpp index 5d43c38612..ed942fc7fc 100644 --- a/indra/newview/llpanelplaces.cpp +++ b/indra/newview/llpanelplaces.cpp @@ -304,7 +304,11 @@ BOOL LLPanelPlaces::postBuild() enable_registrar.add("Places.OverflowMenu.Enable", boost::bind(&LLPanelPlaces::onOverflowMenuItemEnable, this, _2)); mPlaceMenu = LLUICtrlFactory::getInstance()->createFromFile<LLToggleableMenu>("menu_place.xml", gMenuHolder, LLViewerMenuHolderGL::child_registry_t::instance()); - if (!mPlaceMenu) + if (mPlaceMenu) + { + mPlaceMenu->setAlwaysShowMenu(TRUE); + } + else { LL_WARNS() << "Error loading Place menu" << LL_ENDL; } @@ -1006,7 +1010,7 @@ void LLPanelPlaces::togglePlaceInfoPanel(BOOL visible) mPlaceInfoType == LANDMARK_TAB_INFO_TYPE) { mLandmarkInfo->setVisible(visible); - + mPlaceProfile->setVisible(FALSE); if (visible) { mLandmarkInfo->resetLocation(); @@ -1014,8 +1018,6 @@ void LLPanelPlaces::togglePlaceInfoPanel(BOOL visible) LLRect rect = getRect(); LLRect new_rect = LLRect(rect.mLeft, rect.mTop, rect.mRight, mTabContainer->getRect().mBottom); mLandmarkInfo->reshape(new_rect.getWidth(), new_rect.getHeight()); - - mPlaceProfile->setVisible(FALSE); } else { diff --git a/indra/newview/llpanelprimmediacontrols.cpp b/indra/newview/llpanelprimmediacontrols.cpp index 0bcd8a9e63..5f413fc3c0 100644 --- a/indra/newview/llpanelprimmediacontrols.cpp +++ b/indra/newview/llpanelprimmediacontrols.cpp @@ -566,11 +566,16 @@ void LLPanelPrimMediaControls::updateShape() } } - // MAINT-1392 If this is a HUD always set it visible, but hide each control if user has no perms. - // When setting it invisible it won't receive any mouse messages anymore + // Web plugins and HUD may have media controls invisible for user, but still need scroll mouse events. + // LLView checks for visibleEnabledAndContains() and won't pass events to invisible panel, so instead + // of hiding whole panel hide each control instead (if user has no perms). + // Note: It might be beneficial to keep panel visible for all plugins to make behavior consistent, but + // for now limiting change to cases that need events. - if( !is_hud ) + if (!is_hud && (!media_plugin || media_plugin->pluginSupportsMediaTime())) + { setVisible(enabled); + } else { if( !hasPermsControl ) diff --git a/indra/newview/llpanelsnapshotlocal.cpp b/indra/newview/llpanelsnapshotlocal.cpp index 3652c10586..51ec964ace 100644 --- a/indra/newview/llpanelsnapshotlocal.cpp +++ b/indra/newview/llpanelsnapshotlocal.cpp @@ -168,12 +168,11 @@ void LLPanelSnapshotLocal::onSaveFlyoutCommit(LLUICtrl* ctrl) if (saved) { mSnapshotFloater->postSave(); - goBack(); floater->notify(LLSD().with("set-finished", LLSD().with("ok", true).with("msg", "local"))); } else { - cancel(); + floater->notify(LLSD().with("set-finished", LLSD().with("ok", false).with("msg", "local"))); } } diff --git a/indra/newview/llpanelsnapshotpostcard.cpp b/indra/newview/llpanelsnapshotpostcard.cpp index be8bde09f8..3d18e837af 100644 --- a/indra/newview/llpanelsnapshotpostcard.cpp +++ b/indra/newview/llpanelsnapshotpostcard.cpp @@ -57,7 +57,6 @@ public: LLPanelSnapshotPostcard(); /*virtual*/ BOOL postBuild(); /*virtual*/ void onOpen(const LLSD& key); - /*virtual*/ S32 notify(const LLSD& info); private: /*virtual*/ std::string getWidthSpinnerName() const { return "postcard_snapshot_width"; } @@ -79,7 +78,6 @@ private: void onSend(); bool mHasFirstMsgFocus; - std::string mAgentEmail; }; static LLPanelInjector<LLPanelSnapshotPostcard> panel_class("llpanelsnapshotpostcard"); @@ -108,11 +106,9 @@ BOOL LLPanelSnapshotPostcard::postBuild() // virtual void LLPanelSnapshotPostcard::onOpen(const LLSD& key) { - // pick up the user's up-to-date email address - if (mAgentEmail.empty()) + LLUICtrl* name_form = getChild<LLUICtrl>("name_form"); + if (name_form && name_form->getValue().asString().empty()) { - gAgent.sendAgentUserInfoRequest(); - std::string name_string; LLAgentUI::buildFullname(name_string); getChild<LLUICtrl>("name_form")->setValue(LLSD(name_string)); @@ -122,23 +118,6 @@ void LLPanelSnapshotPostcard::onOpen(const LLSD& key) } // virtual -S32 LLPanelSnapshotPostcard::notify(const LLSD& info) -{ - if (!info.has("agent-email")) - { - llassert(info.has("agent-email")); - return 0; - } - - if (mAgentEmail.empty()) - { - mAgentEmail = info["agent-email"].asString(); - } - - return 1; -} - -// virtual void LLPanelSnapshotPostcard::updateControls(const LLSD& info) { getChild<LLUICtrl>("image_quality_slider")->setValue(gSavedSettings.getS32("SnapshotQuality")); @@ -190,7 +169,6 @@ void LLPanelSnapshotPostcard::sendPostcard() if (!url.empty()) { LLResourceUploadInfo::ptr_t uploadInfo(new LLPostcardUploadInfo( - mAgentEmail, getChild<LLUICtrl>("name_form")->getValue().asString(), getChild<LLUICtrl>("to_form")->getValue().asString(), getChild<LLUICtrl>("subject_form")->getValue().asString(), @@ -253,12 +231,6 @@ void LLPanelSnapshotPostcard::onSend() return; } - if (mAgentEmail.empty() || !boost::regex_match(mAgentEmail, email_format)) - { - LLNotificationsUtil::add("PromptSelfEmail"); - return; - } - std::string subject(getChild<LLUICtrl>("subject_form")->getValue().asString()); if(subject.empty() || !mHasFirstMsgFocus) { diff --git a/indra/newview/llparcelselection.cpp b/indra/newview/llparcelselection.cpp index 4d1901adc9..5c62159b93 100644 --- a/indra/newview/llparcelselection.cpp +++ b/indra/newview/llparcelselection.cpp @@ -31,13 +31,6 @@ #include "llparcel.h" -// static -LLPointer<LLParcelSelection> LLParcelSelection::sNullSelection; - -template<> - const LLSafeHandle<LLParcelSelection>::NullFunc - LLSafeHandle<LLParcelSelection>::sNullFunc = LLParcelSelection::getNullParcelSelection; - // // LLParcelSelection // @@ -87,14 +80,3 @@ bool LLParcelSelection::hasOthersSelected() const { return mSelectedOtherCount != 0; } - -// static -LLParcelSelection* LLParcelSelection::getNullParcelSelection() -{ - if (sNullSelection.isNull()) - { - sNullSelection = new LLParcelSelection; - } - - return sNullSelection; -} diff --git a/indra/newview/llparcelselection.h b/indra/newview/llparcelselection.h index 1cbdfc6f74..06d9141efb 100644 --- a/indra/newview/llparcelselection.h +++ b/indra/newview/llparcelselection.h @@ -35,6 +35,7 @@ class LLParcel; class LLParcelSelection : public LLRefCount { friend class LLViewerParcelMgr; + friend class LLSafeHandle<LLParcelSelection>; protected: ~LLParcelSelection(); @@ -61,8 +62,6 @@ public: // Is the entire parcel selected, or just a part? BOOL getWholeParcelSelected() const; - static LLParcelSelection* getNullParcelSelection(); - private: void setParcel(LLParcel* parcel) { mParcel = parcel; } @@ -73,8 +72,6 @@ private: S32 mSelectedSelfCount; S32 mSelectedOtherCount; S32 mSelectedPublicCount; - - static LLPointer<LLParcelSelection> sNullSelection; }; typedef LLSafeHandle<LLParcelSelection> LLParcelSelectionHandle; diff --git a/indra/newview/llpostcard.cpp b/indra/newview/llpostcard.cpp index 2e639b56eb..d5775042c1 100644 --- a/indra/newview/llpostcard.cpp +++ b/indra/newview/llpostcard.cpp @@ -40,11 +40,10 @@ /////////////////////////////////////////////////////////////////////////////// -LLPostcardUploadInfo::LLPostcardUploadInfo(std::string emailFrom, std::string nameFrom, std::string emailTo, +LLPostcardUploadInfo::LLPostcardUploadInfo(std::string nameFrom, std::string emailTo, std::string subject, std::string message, LLVector3d globalPosition, LLPointer<LLImageFormatted> image, invnUploadFinish_f finish) : LLBufferedAssetUploadInfo(LLUUID::null, image, finish), - mEmailFrom(emailFrom), mNameFrom(nameFrom), mEmailTo(emailTo), mSubject(subject), @@ -58,7 +57,6 @@ LLSD LLPostcardUploadInfo::generatePostBody() LLSD postcard = LLSD::emptyMap(); postcard["pos-global"] = mGlobalPosition.getValue(); postcard["to"] = mEmailTo; - postcard["from"] = mEmailFrom; postcard["name"] = mNameFrom; postcard["subject"] = mSubject; postcard["msg"] = mMessage; diff --git a/indra/newview/llpostcard.h b/indra/newview/llpostcard.h index 24157be636..1e932ae03f 100644 --- a/indra/newview/llpostcard.h +++ b/indra/newview/llpostcard.h @@ -53,13 +53,12 @@ private: class LLPostcardUploadInfo : public LLBufferedAssetUploadInfo { public: - LLPostcardUploadInfo(std::string emailFrom, std::string nameFrom, std::string emailTo, + LLPostcardUploadInfo(std::string nameFrom, std::string emailTo, std::string subject, std::string message, LLVector3d globalPosition, LLPointer<LLImageFormatted> image, invnUploadFinish_f finish); virtual LLSD generatePostBody(); private: - std::string mEmailFrom; std::string mNameFrom; std::string mEmailTo; std::string mSubject; diff --git a/indra/newview/llpreviewscript.cpp b/indra/newview/llpreviewscript.cpp index f28ffce602..5cdc5dfd38 100644 --- a/indra/newview/llpreviewscript.cpp +++ b/indra/newview/llpreviewscript.cpp @@ -1870,8 +1870,14 @@ void LLLiveLSLEditor::loadAsset() if(item) { - LLExperienceCache::instance().fetchAssociatedExperience(item->getParentUUID(), item->getUUID(), - boost::bind(&LLLiveLSLEditor::setAssociatedExperience, getDerivedHandle<LLLiveLSLEditor>(), _1)); + LLViewerRegion* region = object->getRegion(); + std::string url = std::string(); + if(region) + { + url = region->getCapability("GetMetadata"); + } + LLExperienceCache::instance().fetchAssociatedExperience(item->getParentUUID(), item->getUUID(), url, + boost::bind(&LLLiveLSLEditor::setAssociatedExperience, getDerivedHandle<LLLiveLSLEditor>(), _1)); bool isGodlike = gAgent.isGodlike(); bool copyManipulate = gAgent.allowOperation(PERM_COPY, item->getPermissions(), GP_OBJECT_MANIPULATE); diff --git a/indra/newview/llregioninfomodel.cpp b/indra/newview/llregioninfomodel.cpp index 25c576468b..25d7be831f 100644 --- a/indra/newview/llregioninfomodel.cpp +++ b/indra/newview/llregioninfomodel.cpp @@ -40,6 +40,7 @@ void LLRegionInfoModel::reset() { mSimAccess = 0; mAgentLimit = 0; + mHardAgentLimit = 100; mRegionFlags = 0; mEstateID = 0; @@ -143,6 +144,7 @@ void LLRegionInfoModel::update(LLMessageSystem* msg) msg->getU32Fast(_PREHASH_RegionInfo, _PREHASH_ParentEstateID, mParentEstateID); msg->getU8Fast(_PREHASH_RegionInfo, _PREHASH_SimAccess, mSimAccess); msg->getU8Fast(_PREHASH_RegionInfo, _PREHASH_MaxAgents, mAgentLimit); + msg->getF32Fast(_PREHASH_RegionInfo, _PREHASH_ObjectBonusFactor, mObjectBonusFactor); msg->getF32Fast(_PREHASH_RegionInfo, _PREHASH_BillableFactor, mBillableFactor); msg->getF32Fast(_PREHASH_RegionInfo, _PREHASH_WaterHeight, mWaterHeight); @@ -158,6 +160,8 @@ void LLRegionInfoModel::update(LLMessageSystem* msg) msg->getF32(_PREHASH_RegionInfo, _PREHASH_SunHour, mSunHour); LL_DEBUGS("Windlight Sync") << "Got region sun hour: " << mSunHour << LL_ENDL; + msg->getS32Fast(_PREHASH_RegionInfo2, _PREHASH_HardMaxAgents, mHardAgentLimit); + if (msg->has(_PREHASH_RegionInfo3)) { msg->getU64Fast(_PREHASH_RegionInfo3, _PREHASH_RegionFlagsExtended, mRegionFlags); diff --git a/indra/newview/llregioninfomodel.h b/indra/newview/llregioninfomodel.h index ea9640efda..baeff82fef 100644 --- a/indra/newview/llregioninfomodel.h +++ b/indra/newview/llregioninfomodel.h @@ -53,6 +53,8 @@ public: U8 mSimAccess; U8 mAgentLimit; + S32 mHardAgentLimit; + U64 mRegionFlags; U32 mEstateID; U32 mParentEstateID; diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp index dd934ce6b8..c44aca6fa5 100644 --- a/indra/newview/llselectmgr.cpp +++ b/indra/newview/llselectmgr.cpp @@ -33,6 +33,7 @@ // library includes #include "llcachename.h" +#include "llavatarnamecache.h" #include "lldbstrings.h" #include "lleconomy.h" #include "llgl.h" @@ -132,11 +133,6 @@ LLColor4 LLSelectMgr::sHighlightParentColor; LLColor4 LLSelectMgr::sHighlightChildColor; LLColor4 LLSelectMgr::sContextSilhouetteColor; -static LLObjectSelection *get_null_object_selection(); -template<> - const LLSafeHandle<LLObjectSelection>::NullFunc - LLSafeHandle<LLObjectSelection>::sNullFunc = get_null_object_selection; - //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // struct LLDeRezInfo // @@ -156,27 +152,15 @@ struct LLDeRezInfo // -static LLPointer<LLObjectSelection> sNullSelection; - // // Functions // void LLSelectMgr::cleanupGlobals() { - sNullSelection = NULL; LLSelectMgr::getInstance()->clearSelections(); } -LLObjectSelection *get_null_object_selection() -{ - if (sNullSelection.isNull()) - { - sNullSelection = new LLObjectSelection; - } - return sNullSelection; -} - // Build time optimization, generate this function once here template class LLSelectMgr* LLSingleton<class LLSelectMgr>::getInstance(); //----------------------------------------------------------------------------- @@ -613,6 +597,12 @@ bool LLSelectMgr::linkObjects() return true; } + if (!LLSelectMgr::getInstance()->selectGetSameRegion()) + { + LLNotificationsUtil::add("CannotLinkAcrossRegions"); + return true; + } + LLSelectMgr::getInstance()->sendLink(); return true; @@ -2777,6 +2767,35 @@ BOOL LLSelectMgr::selectGetRootsModify() return TRUE; } +//----------------------------------------------------------------------------- +// selectGetSameRegion() - return TRUE if all objects are in same region +//----------------------------------------------------------------------------- +BOOL LLSelectMgr::selectGetSameRegion() +{ + if (getSelection()->isEmpty()) + { + return TRUE; + } + LLViewerObject* object = getSelection()->getFirstObject(); + if (!object) + { + return FALSE; + } + LLViewerRegion* current_region = object->getRegion(); + + for (LLObjectSelection::root_iterator iter = getSelection()->root_begin(); + iter != getSelection()->root_end(); iter++) + { + LLSelectNode* node = *iter; + object = node->getObject(); + if (!node->mValid || !object || current_region != object->getRegion()) + { + return FALSE; + } + } + + return TRUE; +} //----------------------------------------------------------------------------- // selectGetNonPermanentEnforced() - return TRUE if all objects are not @@ -4416,6 +4435,9 @@ void LLSelectMgr::sendAttach(U8 attachment_point, bool replace) SEND_ONLY_ROOTS ); if (!build_mode) { + // After "ObjectAttach" server will unsubscribe us from properties updates + // so either deselect objects or resend selection after attach packet reaches server + // In case of build_mode LLPanelObjectInventory::refresh() will deal with selection deselectAll(); } } @@ -5382,9 +5404,9 @@ void LLSelectMgr::processObjectPropertiesFamily(LLMessageSystem* msg, void** use LLFloaterReporter *reporterp = LLFloaterReg::findTypedInstance<LLFloaterReporter>("reporter"); if (reporterp) { - std::string fullname; - gCacheName->getFullName(owner_id, fullname); - reporterp->setPickedObjectProperties(name, fullname, owner_id); + LLAvatarName av_name; + LLAvatarNameCache::get(owner_id, &av_name); + reporterp->setPickedObjectProperties(name, av_name.getUserName(), owner_id); } } else if (request_flags & OBJECT_PAY_REQUEST) @@ -6615,7 +6637,7 @@ void LLSelectMgr::updateSelectionCenter() { mSelectedObjects->mSelectType = getSelectTypeForObject(object); - if (mSelectedObjects->mSelectType == SELECT_TYPE_ATTACHMENT && isAgentAvatarValid()) + if (mSelectedObjects->mSelectType == SELECT_TYPE_ATTACHMENT && isAgentAvatarValid() && object->getParent() != NULL) { mPauseRequest = gAgentAvatarp->requestPause(); } @@ -7101,7 +7123,7 @@ F32 LLObjectSelection::getSelectedLinksetCost() LLSelectNode* node = *iter; LLViewerObject* object = node->getObject(); - if (object) + if (object && !object->isAttachment()) { LLViewerObject* root = static_cast<LLViewerObject*>(object->getRoot()); if (root) diff --git a/indra/newview/llselectmgr.h b/indra/newview/llselectmgr.h index 2a893af266..e965dd80d5 100644 --- a/indra/newview/llselectmgr.h +++ b/indra/newview/llselectmgr.h @@ -233,6 +233,7 @@ protected: class LLObjectSelection : public LLRefCount { friend class LLSelectMgr; + friend class LLSafeHandle<LLObjectSelection>; protected: ~LLObjectSelection(); @@ -624,6 +625,9 @@ public: BOOL selectGetRootsModify(); BOOL selectGetModify(); + // returns TRUE if all objects are in same region + BOOL selectGetSameRegion(); + // returns TRUE if is all objects are non-permanent-enforced BOOL selectGetRootsNonPermanentEnforced(); BOOL selectGetNonPermanentEnforced(); diff --git a/indra/newview/llsidepanelappearance.cpp b/indra/newview/llsidepanelappearance.cpp index a32ed258f8..d6bf2164a0 100644 --- a/indra/newview/llsidepanelappearance.cpp +++ b/indra/newview/llsidepanelappearance.cpp @@ -388,7 +388,7 @@ void LLSidepanelAppearance::toggleWearableEditPanel(BOOL visible, LLViewerWearab return; } - if (mEditWearable->getVisible() == visible && (!visible || mEditWearable->getWearable() != wearable)) + if (mEditWearable->getVisible() == visible && (!visible || mEditWearable->getWearable() == wearable)) { // visibility isn't changing and panel doesn't need an update, hence nothing to do return; @@ -421,6 +421,7 @@ void LLSidepanelAppearance::toggleWearableEditPanel(BOOL visible, LLViewerWearab { // Save changes if closing. mEditWearable->saveChanges(); + mEditWearable->setWearable(NULL); LLAppearanceMgr::getInstance()->updateIsDirty(); if (change_state) { diff --git a/indra/newview/llsidepaneliteminfo.cpp b/indra/newview/llsidepaneliteminfo.cpp index 12cbff888d..3c58dd7194 100644 --- a/indra/newview/llsidepaneliteminfo.cpp +++ b/indra/newview/llsidepaneliteminfo.cpp @@ -46,6 +46,7 @@ #include "llviewerobjectlist.h" #include "llexperiencecache.h" #include "lltrans.h" +#include "llviewerregion.h" //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -327,9 +328,13 @@ void LLSidepanelItemInfo::refreshFromItem(LLViewerInventoryItem* item) LLTextBox* tb = getChild<LLTextBox>("LabelItemExperience"); tb->setText(getString("loading_experience")); tb->setVisible(TRUE); - - LLExperienceCache::instance().fetchAssociatedExperience(item->getParentUUID(), item->getUUID(), - boost::bind(&LLSidepanelItemInfo::setAssociatedExperience, getDerivedHandle<LLSidepanelItemInfo>(), _1)); + std::string url = std::string(); + if(object && object->getRegion()) + { + url = object->getRegion()->getCapability("GetMetadata"); + } + LLExperienceCache::instance().fetchAssociatedExperience(item->getParentUUID(), item->getUUID(), url, + boost::bind(&LLSidepanelItemInfo::setAssociatedExperience, getDerivedHandle<LLSidepanelItemInfo>(), _1)); } ////////////////////// @@ -779,23 +784,7 @@ void LLSidepanelItemInfo::onCommitName() { LLPointer<LLViewerInventoryItem> new_item = new LLViewerInventoryItem(item); new_item->rename(labelItemName->getText()); - if(mObjectID.isNull()) - { - new_item->updateServer(FALSE); - gInventory.updateItem(new_item); - gInventory.notifyObservers(); - } - else - { - LLViewerObject* object = gObjectList.findObject(mObjectID); - if(object) - { - object->updateInventory( - new_item, - TASK_INVENTORY_ITEM_KEY, - false); - } - } + onCommitChanges(new_item); } } @@ -816,23 +805,7 @@ void LLSidepanelItemInfo::onCommitDescription() LLPointer<LLViewerInventoryItem> new_item = new LLViewerInventoryItem(item); new_item->setDescription(labelItemDesc->getText()); - if(mObjectID.isNull()) - { - new_item->updateServer(FALSE); - gInventory.updateItem(new_item); - gInventory.notifyObservers(); - } - else - { - LLViewerObject* object = gObjectList.findObject(mObjectID); - if(object) - { - object->updateInventory( - new_item, - TASK_INVENTORY_ITEM_KEY, - false); - } - } + onCommitChanges(new_item); } } @@ -908,23 +881,7 @@ void LLSidepanelItemInfo::onCommitPermissions() flags |= LLInventoryItemFlags::II_FLAGS_OBJECT_PERM_OVERWRITE_GROUP; } new_item->setFlags(flags); - if(mObjectID.isNull()) - { - new_item->updateServer(FALSE); - gInventory.updateItem(new_item); - gInventory.notifyObservers(); - } - else - { - LLViewerObject* object = gObjectList.findObject(mObjectID); - if(object) - { - object->updateInventory( - new_item, - TASK_INVENTORY_ITEM_KEY, - false); - } - } + onCommitChanges(new_item); } else { @@ -1008,25 +965,7 @@ void LLSidepanelItemInfo::updateSaleInfo() } new_item->setSaleInfo(sale_info); - if(mObjectID.isNull()) - { - // This is in the agent's inventory. - new_item->updateServer(FALSE); - gInventory.updateItem(new_item); - gInventory.notifyObservers(); - } - else - { - // This is in an object's contents. - LLViewerObject* object = gObjectList.findObject(mObjectID); - if(object) - { - object->updateInventory( - new_item, - TASK_INVENTORY_ITEM_KEY, - false); - } - } + onCommitChanges(new_item); } else { @@ -1035,6 +974,45 @@ void LLSidepanelItemInfo::updateSaleInfo() } } +void LLSidepanelItemInfo::onCommitChanges(LLPointer<LLViewerInventoryItem> item) +{ + if (item.isNull()) + { + return; + } + + if (mObjectID.isNull()) + { + // This is in the agent's inventory. + item->updateServer(FALSE); + gInventory.updateItem(item); + gInventory.notifyObservers(); + } + else + { + // This is in an object's contents. + LLViewerObject* object = gObjectList.findObject(mObjectID); + if (object) + { + object->updateInventory( + item, + TASK_INVENTORY_ITEM_KEY, + false); + + if (object->isSelected()) + { + // Since object is selected (build floater is open) object will + // receive properties update, detect serial mismatch, dirty and + // reload inventory, meanwhile some other updates will refresh it. + // So mark dirty early, this will prevent unnecessary changes + // and download will be triggered by LLPanelObjectInventory - it + // prevents flashing in content tab and some duplicated request. + object->dirtyInventory(); + } + } + } +} + LLViewerInventoryItem* LLSidepanelItemInfo::findItem() const { LLViewerInventoryItem* item = NULL; diff --git a/indra/newview/llsidepaneliteminfo.h b/indra/newview/llsidepaneliteminfo.h index 2e24e58a2a..74cf7afe35 100644 --- a/indra/newview/llsidepaneliteminfo.h +++ b/indra/newview/llsidepaneliteminfo.h @@ -89,6 +89,7 @@ protected: void onCommitSaleInfo(); void onCommitSaleType(); void updateSaleInfo(); + void onCommitChanges(LLPointer<LLViewerInventoryItem> item); }; #endif // LL_LLSIDEPANELITEMINFO_H diff --git a/indra/newview/llspeakers.cpp b/indra/newview/llspeakers.cpp index e7971028bf..19d1af34f9 100644 --- a/indra/newview/llspeakers.cpp +++ b/indra/newview/llspeakers.cpp @@ -29,6 +29,7 @@ #include "llspeakers.h" #include "llagent.h" +#include "llavatarnamecache.h" #include "llappviewer.h" #include "llimview.h" #include "llgroupmgr.h" @@ -75,13 +76,13 @@ void LLSpeaker::lookupName() { if (mDisplayName.empty()) { - gCacheName->get(mID, false, boost::bind(&LLSpeaker::onNameCache, this, _1, _2, _3)); + LLAvatarNameCache::get(mID, boost::bind(&LLSpeaker::onNameCache, this, _1, _2)); // todo: can be group??? } } -void LLSpeaker::onNameCache(const LLUUID& id, const std::string& full_name, bool is_group) +void LLSpeaker::onNameCache(const LLUUID& id, const LLAvatarName& av_name) { - mDisplayName = full_name; + mDisplayName = av_name.getUserName(); } bool LLSpeaker::isInVoiceChannel() diff --git a/indra/newview/llspeakers.h b/indra/newview/llspeakers.h index 617bae3984..d1dbf72fe9 100644 --- a/indra/newview/llspeakers.h +++ b/indra/newview/llspeakers.h @@ -34,6 +34,7 @@ #include "llcoros.h" class LLSpeakerMgr; +class LLAvatarName; // data for a given participant in a voice channel class LLSpeaker : public LLRefCount, public LLOldEvents::LLObservable, public LLHandleProvider<LLSpeaker>, public boost::signals2::trackable @@ -61,7 +62,7 @@ public: ~LLSpeaker() {}; void lookupName(); - void onNameCache(const LLUUID& id, const std::string& full_name, bool is_group); + void onNameCache(const LLUUID& id, const LLAvatarName& full_name); bool isInVoiceChannel(); diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp index 1bb3d65e05..0a85344025 100644 --- a/indra/newview/llstartup.cpp +++ b/indra/newview/llstartup.cpp @@ -56,6 +56,7 @@ #include "llerrorcontrol.h" #include "llfloaterreg.h" #include "llfocusmgr.h" +#include "llfloatergridstatus.h" #include "llfloaterimsession.h" #include "lllocationhistory.h" #include "llimageworker.h" @@ -256,6 +257,7 @@ boost::scoped_ptr<LLViewerStats::PhaseMap> LLStartUp::sPhases(new LLViewerStats: void login_show(); void login_callback(S32 option, void* userdata); +void show_release_notes_if_required(); void show_first_run_dialog(); bool first_run_dialog_callback(const LLSD& notification, const LLSD& response); void set_startup_status(const F32 frac, const std::string& string, const std::string& msg); @@ -682,10 +684,17 @@ bool idle_startup() } else if (gSavedSettings.getBOOL("AutoLogin")) { + // Log into last account gRememberPassword = TRUE; gSavedSettings.setBOOL("RememberPassword", TRUE); show_connect_box = false; } + else if (gSavedSettings.getLLSD("UserLoginInfo").size() == 3) + { + // Console provided login&password + gRememberPassword = gSavedSettings.getBOOL("RememberPassword"); + show_connect_box = false; + } else { gRememberPassword = gSavedSettings.getBOOL("RememberPassword"); @@ -709,6 +718,7 @@ bool idle_startup() set_startup_status(0.03f, msg.c_str(), gAgent.mMOTD.c_str()); display_startup(); // LLViewerMedia::initBrowser(); + show_release_notes_if_required(); LLStartUp::setStartupState( STATE_LOGIN_SHOW ); return FALSE; } @@ -957,6 +967,8 @@ bool idle_startup() // Load media plugin cookies LLViewerMedia::loadCookieFile(); + LLRenderMuteList::getInstance()->loadFromFile(); + //------------------------------------------------- // Handle startup progress screen //------------------------------------------------- @@ -1866,6 +1878,8 @@ bool idle_startup() LLFloaterReg::showInitialVisibleInstances(); + LLFloaterGridStatus::getInstance()->startGridStatusTimer(); + display_startup(); display_startup(); @@ -2247,6 +2261,22 @@ void login_callback(S32 option, void *userdata) } } +/** +* Check if user is running a new version of the viewer. +* Display the Release Notes if it's not overriden by the "UpdaterShowReleaseNotes" setting. +*/ +void show_release_notes_if_required() +{ + if (LLVersionInfo::getChannelAndVersion() != gLastRunVersion + && LLVersionInfo::getViewerMaturity() != LLVersionInfo::TEST_VIEWER // don't show Release Notes for the test builds + && gSavedSettings.getBOOL("UpdaterShowReleaseNotes") + && !gSavedSettings.getBOOL("FirstLoginThisInstall")) + { + LLSD info(LLAppViewer::instance()->getViewerInfo()); + LLWeb::loadURLInternal(info["VIEWER_RELEASE_NOTES_URL"]); + } +} + void show_first_run_dialog() { LLNotificationsUtil::add("FirstRun", LLSD(), LLSD(), first_run_dialog_callback); diff --git a/indra/newview/llsyntaxid.cpp b/indra/newview/llsyntaxid.cpp index 9e54c521b5..10a9dee415 100644 --- a/indra/newview/llsyntaxid.cpp +++ b/indra/newview/llsyntaxid.cpp @@ -50,6 +50,7 @@ LLSyntaxIdLSL::LLSyntaxIdLSL() , mCapabilityURL(std::string()) , mFilePath(LL_PATH_APP_SETTINGS) , mSyntaxId(LLUUID()) +, mInitialized(false) { loadDefaultKeywordsIntoLLSD(); mRegionChangedCallback = gAgent.addRegionChangedCallback(boost::bind(&LLSyntaxIdLSL::handleRegionChanged, this)); @@ -179,6 +180,7 @@ void LLSyntaxIdLSL::cacheFile(const std::string &fileSpec, const LLSD& content_r //----------------------------------------------------------------------------- void LLSyntaxIdLSL::initialize() { + if(mInitialized) return; if (mSyntaxId.isNull()) { loadDefaultKeywordsIntoLLSD(); @@ -213,6 +215,7 @@ void LLSyntaxIdLSL::initialize() LL_DEBUGS("SyntaxLSL") << "LSLSyntaxId capability URL is empty." << LL_ENDL; loadDefaultKeywordsIntoLLSD(); } + mInitialized = true; } //----------------------------------------------------------------------------- @@ -303,6 +306,7 @@ void LLSyntaxIdLSL::handleRegionChanged() { buildFullFileSpec(); fetchKeywordsFile(mFullFileSpec); + mInitialized = false; } } diff --git a/indra/newview/llsyntaxid.h b/indra/newview/llsyntaxid.h index 1360b3e042..caddba5527 100644 --- a/indra/newview/llsyntaxid.h +++ b/indra/newview/llsyntaxid.h @@ -65,6 +65,7 @@ private: ELLPath mFilePath; LLUUID mSyntaxId; LLSD mKeywordsXml; + bool mInitialized; public: void initialize(); diff --git a/indra/newview/lltoastscripttextbox.cpp b/indra/newview/lltoastscripttextbox.cpp index 78d9e92b5c..776ae2ece9 100644 --- a/indra/newview/lltoastscripttextbox.cpp +++ b/indra/newview/lltoastscripttextbox.cpp @@ -28,31 +28,21 @@ #include "lltoastscripttextbox.h" -#include "llfocusmgr.h" - -#include "llbutton.h" +#include "lllslconstants.h" #include "llnotifications.h" -#include "llviewertexteditor.h" - -#include "llavatarnamecache.h" -#include "lluiconstants.h" -#include "llui.h" -#include "llviewercontrol.h" -#include "lltrans.h" #include "llstyle.h" +#include "lluiconstants.h" +#include "llviewertexteditor.h" -#include "llglheaders.h" -#include "llagent.h" - -const S32 LLToastScriptTextbox::DEFAULT_MESSAGE_MAX_LINE_COUNT= 7; +const S32 LLToastScriptTextbox::DEFAULT_MESSAGE_MAX_LINE_COUNT= 14; LLToastScriptTextbox::LLToastScriptTextbox(const LLNotificationPtr& notification) : LLToastPanel(notification) { buildFromFile( "panel_notify_textbox.xml"); - LLTextEditor* text_editorp = getChild<LLTextEditor>("text_editor_box"); - text_editorp->setValue(notification->getMessage()); + mInfoText = getChild<LLTextBox>("text_editor_box"); + mInfoText->setValue(notification->getMessage()); getChild<LLButton>("ignore_btn")->setClickedCallback(boost::bind(&LLToastScriptTextbox::onClickIgnore, this)); @@ -73,13 +63,7 @@ LLToastScriptTextbox::LLToastScriptTextbox(const LLNotificationPtr& notification pSubmitBtn->setClickedCallback((boost::bind(&LLToastScriptTextbox::onClickSubmit, this))); setDefaultBtn(pSubmitBtn); - S32 maxLinesCount; - std::istringstream ss( getString("message_max_lines_count") ); - if (!(ss >> maxLinesCount)) - { - maxLinesCount = DEFAULT_MESSAGE_MAX_LINE_COUNT; - } - //snapToMessageHeight(pMessageText, maxLinesCount); + snapToMessageHeight(); } // virtual @@ -92,7 +76,6 @@ void LLToastScriptTextbox::close() die(); } -#include "lllslconstants.h" void LLToastScriptTextbox::onClickSubmit() { LLViewerTextEditor* pMessageText = getChild<LLViewerTextEditor>("message"); @@ -119,3 +102,29 @@ void LLToastScriptTextbox::onClickIgnore() mNotification->respond(response); close(); } + +void LLToastScriptTextbox::snapToMessageHeight() +{ + LLPanel* info_pan = getChild<LLPanel>("info_panel"); + if (!info_pan) + { + return; + } + + S32 maxLinesCount; + std::istringstream ss( getString("message_max_lines_count") ); + if (!(ss >> maxLinesCount)) + { + maxLinesCount = DEFAULT_MESSAGE_MAX_LINE_COUNT; + } + + + S32 maxTextHeight = (mInfoText->getFont()->getLineHeight() * maxLinesCount); + S32 oldTextHeight = mInfoText->getRect().getHeight(); + S32 newTextHeight = llmin(mInfoText->getTextBoundingRect().getHeight(), maxTextHeight); + + S32 heightDelta = newTextHeight - oldTextHeight; + + reshape( getRect().getWidth(), llmax(getRect().getHeight() + heightDelta, MIN_PANEL_HEIGHT)); + info_pan->reshape(info_pan->getRect().getWidth(),newTextHeight); +} diff --git a/indra/newview/lltoastscripttextbox.h b/indra/newview/lltoastscripttextbox.h index 7d33446248..7aee02dd00 100644 --- a/indra/newview/lltoastscripttextbox.h +++ b/indra/newview/lltoastscripttextbox.h @@ -48,9 +48,12 @@ public: private: + LLTextBox* mInfoText; + void onClickSubmit(); void onClickIgnore(); + void snapToMessageHeight(); static const S32 DEFAULT_MESSAGE_MAX_LINE_COUNT; }; diff --git a/indra/newview/lltooldraganddrop.cpp b/indra/newview/lltooldraganddrop.cpp index 27c4c90857..49436ee406 100644 --- a/indra/newview/lltooldraganddrop.cpp +++ b/indra/newview/lltooldraganddrop.cpp @@ -1584,12 +1584,12 @@ static void show_object_sharing_confirmation(const std::string name, } static void get_name_cb(const LLUUID& id, - const std::string& full_name, + const LLAvatarName& av_name, LLInventoryObject* inv_obj, const LLSD& dest, const LLUUID& dest_agent) { - show_object_sharing_confirmation(full_name, + show_object_sharing_confirmation(av_name.getUserName(), inv_obj, dest, id, @@ -1634,17 +1634,17 @@ bool LLToolDragAndDrop::handleGiveDragAndDrop(LLUUID dest_agent, LLUUID session_ // If no IM session found get the destination agent's name by id. if (NULL == session) { - std::string fullname; + LLAvatarName av_name; // If destination agent's name is found in cash proceed to showing the confirmation dialog. // Otherwise set up a callback to show the dialog when the name arrives. - if (gCacheName->getFullName(dest_agent, fullname)) + if (LLAvatarNameCache::get(dest_agent, &av_name)) { - show_object_sharing_confirmation(fullname, inv_obj, dest, dest_agent, LLUUID::null); + show_object_sharing_confirmation(av_name.getUserName(), inv_obj, dest, dest_agent, LLUUID::null); } else { - gCacheName->get(dest_agent, false, boost::bind(&get_name_cb, _1, _2, inv_obj, dest, dest_agent)); + LLAvatarNameCache::get(dest_agent, boost::bind(&get_name_cb, _1, _2, inv_obj, dest, dest_agent)); } return true; diff --git a/indra/newview/lltoolpie.cpp b/indra/newview/lltoolpie.cpp index e17651dc91..fc052ae3aa 100644 --- a/indra/newview/lltoolpie.cpp +++ b/indra/newview/lltoolpie.cpp @@ -338,56 +338,41 @@ BOOL LLToolPie::handleLeftClickPick() // If left-click never selects or spawns a menu // Eat the event. - if (!gSavedSettings.getBOOL("LeftClickShowMenu")) + + // mouse already released + if (!mMouseButtonDown) { - // mouse already released - if (!mMouseButtonDown) - { - return true; - } + return true; + } - while( object && object->isAttachment() && !object->flagHandleTouch()) + while (object && object->isAttachment() && !object->flagHandleTouch()) + { + // don't pick avatar through hud attachment + if (object->isHUDAttachment()) { - // don't pick avatar through hud attachment - if (object->isHUDAttachment()) - { - break; - } - object = (LLViewerObject*)object->getParent(); + break; } - if (object && object == gAgentAvatarp && !gSavedSettings.getBOOL("ClickToWalk")) - { - // we left clicked on avatar, switch to focus mode - mMouseButtonDown = false; - LLToolMgr::getInstance()->setTransientTool(LLToolCamera::getInstance()); - gViewerWindow->hideCursor(); - LLToolCamera::getInstance()->setMouseCapture(TRUE); - LLToolCamera::getInstance()->pickCallback(mPick); - gAgentCamera.setFocusOnAvatar(TRUE, TRUE); + object = (LLViewerObject*)object->getParent(); + } + if (object && object == gAgentAvatarp && !gSavedSettings.getBOOL("ClickToWalk")) + { + // we left clicked on avatar, switch to focus mode + mMouseButtonDown = false; + LLToolMgr::getInstance()->setTransientTool(LLToolCamera::getInstance()); + gViewerWindow->hideCursor(); + LLToolCamera::getInstance()->setMouseCapture(TRUE); + LLToolCamera::getInstance()->pickCallback(mPick); + gAgentCamera.setFocusOnAvatar(TRUE, TRUE); - return TRUE; - } + return TRUE; + } ////////// // // Could be first left-click on nothing // LLFirstUse::useLeftClickNoHit(); ///////// - - // Eat the event - return LLTool::handleMouseDown(x, y, mask); - } - if (gAgent.leftButtonGrabbed()) - { - // if the left button is grabbed, don't put up the pie menu - return LLTool::handleMouseDown(x, y, mask); - } - - // Can't ignore children here. - LLToolSelect::handleObjectSelection(mPick, FALSE, TRUE); - - // Spawn pie menu - LLTool::handleRightMouseDown(x, y, mask); - return TRUE; + // Eat the event + return LLTool::handleMouseDown(x, y, mask); } BOOL LLToolPie::useClickAction(MASK mask, @@ -908,14 +893,19 @@ BOOL LLToolPie::handleTooltipLand(std::string line, std::string tooltip_msg) line.append(LLTrans::getString("RetrievingData")); } } - else if(gCacheName->getFullName(owner, name)) - { - line.append(name); - } - else - { - line.append(LLTrans::getString("RetrievingData")); - } + else + { + LLAvatarName av_name; + if (LLAvatarNameCache::get(owner, &av_name)) + { + name = av_name.getUserName(); + line.append(name); + } + else + { + line.append(LLTrans::getString("RetrievingData")); + } + } } else { diff --git a/indra/newview/llviewerassetupload.cpp b/indra/newview/llviewerassetupload.cpp index cafaf8645a..49d29c0e4e 100644 --- a/indra/newview/llviewerassetupload.cpp +++ b/indra/newview/llviewerassetupload.cpp @@ -307,10 +307,9 @@ void LLResourceUploadInfo::assignDefaults() mDescription = "(No Description)"; } - mFolderId = gInventory.findCategoryUUIDForType( + mFolderId = gInventory.findUserDefinedCategoryUUIDForType( (mDestinationFolderType == LLFolderType::FT_NONE) ? (LLFolderType::EType)mAssetType : mDestinationFolderType); - } std::string LLResourceUploadInfo::getDisplayName() const diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index db71849659..7c1921b143 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -507,7 +507,7 @@ bool handleVelocityInterpolate(const LLSD& newvalue) bool handleForceShowGrid(const LLSD& newvalue) { - LLPanelLogin::updateServer( ); + LLPanelLogin::updateLocationSelectorsVisibility(); return true; } diff --git a/indra/newview/llviewerdisplay.cpp b/indra/newview/llviewerdisplay.cpp index 13eccaefc1..960a36a251 100644 --- a/indra/newview/llviewerdisplay.cpp +++ b/indra/newview/llviewerdisplay.cpp @@ -220,9 +220,9 @@ void display_stats() F32 mem_log_freq = gSavedSettings.getF32("MemoryLogFrequency"); if (mem_log_freq > 0.f && gRecentMemoryTime.getElapsedTimeF32() >= mem_log_freq) { - gMemoryAllocated = (U64Bytes)LLMemory::getCurrentRSS(); + gMemoryAllocated = U64Bytes(LLMemory::getCurrentRSS()); U32Megabytes memory = gMemoryAllocated; - LL_INFOS() << llformat("MEMORY: %d MB", memory.value()) << LL_ENDL; + LL_INFOS() << "MEMORY: " << memory << LL_ENDL; LLMemory::logMemoryInfo(TRUE) ; gRecentMemoryTime.reset(); } diff --git a/indra/newview/llviewerfloaterreg.cpp b/indra/newview/llviewerfloaterreg.cpp index ec7a81584a..cf18299b0b 100644 --- a/indra/newview/llviewerfloaterreg.cpp +++ b/indra/newview/llviewerfloaterreg.cpp @@ -38,6 +38,7 @@ #include "llfloaterautoreplacesettings.h" #include "llfloateravatar.h" #include "llfloateravatarpicker.h" +#include "llfloateravatarrendersettings.h" #include "llfloateravatartextures.h" #include "llfloaterbigpreview.h" #include "llfloaterbeacons.h" @@ -70,6 +71,7 @@ #include "llfloaterfonttest.h" #include "llfloatergesture.h" #include "llfloatergodtools.h" +#include "llfloatergridstatus.h" #include "llfloatergroups.h" #include "llfloaterhelpbrowser.h" #include "llfloaterhoverheight.h" @@ -193,6 +195,7 @@ void LLViewerFloaterReg::registerFloaters() LLFloaterReg::add("auction", "floater_auction.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterAuction>); LLFloaterReg::add("avatar", "floater_avatar.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterAvatar>); LLFloaterReg::add("avatar_picker", "floater_avatar_picker.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterAvatarPicker>); + LLFloaterReg::add("avatar_render_settings", "floater_avatar_render_settings.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterAvatarRenderSettings>); LLFloaterReg::add("avatar_textures", "floater_avatar_textures.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterAvatarTextures>); LLFloaterReg::add("beacons", "floater_beacons.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterBeacons>); @@ -231,6 +234,7 @@ void LLViewerFloaterReg::registerFloaters() LLFloaterReg::add("gestures", "floater_gesture.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterGesture>); LLFloaterReg::add("god_tools", "floater_god_tools.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterGodTools>); + LLFloaterReg::add("grid_status", "floater_grid_status.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterGridStatus>); LLFloaterReg::add("group_picker", "floater_choose_group.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterGroupPicker>); LLFloaterReg::add("help_browser", "floater_help_browser.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterHelpBrowser>); diff --git a/indra/newview/llviewerinventory.cpp b/indra/newview/llviewerinventory.cpp index caffeadb73..bf79a0595c 100644 --- a/indra/newview/llviewerinventory.cpp +++ b/indra/newview/llviewerinventory.cpp @@ -1126,10 +1126,10 @@ void create_inventory_item(const LLUUID& agent_id, const LLUUID& session_id, void create_inventory_callingcard(const LLUUID& avatar_id, const LLUUID& parent /*= LLUUID::null*/, LLPointer<LLInventoryCallback> cb/*=NULL*/) { std::string item_desc = avatar_id.asString(); - std::string item_name; - gCacheName->getFullName(avatar_id, item_name); + LLAvatarName av_name; + LLAvatarNameCache::get(avatar_id, &av_name); create_inventory_item(gAgent.getID(), gAgent.getSessionID(), - parent, LLTransactionID::tnull, item_name, item_desc, LLAssetType::AT_CALLINGCARD, + parent, LLTransactionID::tnull, av_name.getUserName(), item_desc, LLAssetType::AT_CALLINGCARD, LLInventoryType::IT_CALLINGCARD, NOT_WEARABLE, PERM_MOVE | PERM_TRANSFER, cb); } @@ -2071,9 +2071,9 @@ PermissionMask LLViewerInventoryItem::getPermissionMask() const //---------- -void LLViewerInventoryItem::onCallingCardNameLookup(const LLUUID& id, const std::string& name, bool is_group) +void LLViewerInventoryItem::onCallingCardNameLookup(const LLUUID& id, const LLAvatarName& name) { - rename(name); + rename(name.getUserName()); gInventory.addChangedMask(LLInventoryObserver::LABEL, getUUID()); gInventory.notifyObservers(); } diff --git a/indra/newview/llviewerinventory.h b/indra/newview/llviewerinventory.h index 074d51b8b3..b3053e365b 100644 --- a/indra/newview/llviewerinventory.h +++ b/indra/newview/llviewerinventory.h @@ -39,6 +39,7 @@ class LLFolderView; class LLFolderBridge; class LLViewerInventoryCategory; class LLInventoryCallback; +class LLAvatarName; //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // Class LLViewerInventoryItem @@ -158,7 +159,7 @@ public: PermissionMask getPermissionMask() const; // callback - void onCallingCardNameLookup(const LLUUID& id, const std::string& name, bool is_group); + void onCallingCardNameLookup(const LLUUID& id, const LLAvatarName& name); // If this is a broken link, try to fix it and any other identical link. BOOL regenerateLink(); diff --git a/indra/newview/llviewermedia.cpp b/indra/newview/llviewermedia.cpp index 9f05ee61bd..900075488f 100644 --- a/indra/newview/llviewermedia.cpp +++ b/indra/newview/llviewermedia.cpp @@ -604,7 +604,9 @@ void LLViewerMedia::updateMedia(void *dummy_arg) LLPluginProcessParent::setUseReadThread(gSavedSettings.getBOOL("PluginUseReadThread")); // HACK: we always try to keep a spare running webkit plugin around to improve launch times. - createSpareBrowserMediaSource(); + // 2017-04-19 Removed CP - this doesn't appear to buy us much and consumes a lot of resources so + // removing it for now. + //createSpareBrowserMediaSource(); sAnyMediaShowing = false; sAnyMediaPlaying = false; diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp index 9bd4e12761..bae619c66d 100644 --- a/indra/newview/llviewermenu.cpp +++ b/indra/newview/llviewermenu.cpp @@ -4177,27 +4177,6 @@ class LLViewToggleUI : public view_listener_t } }; -class LLEditDuplicate : public view_listener_t -{ - bool handleEvent(const LLSD& userdata) - { - if(LLEditMenuHandler::gEditMenuHandler) - { - LLEditMenuHandler::gEditMenuHandler->duplicate(); - } - return true; - } -}; - -class LLEditEnableDuplicate : public view_listener_t -{ - bool handleEvent(const LLSD& userdata) - { - bool new_value = LLEditMenuHandler::gEditMenuHandler && LLEditMenuHandler::gEditMenuHandler->canDuplicate(); - return new_value; - } -}; - void handle_duplicate_in_place(void*) { LL_INFOS() << "handle_duplicate_in_place" << LL_ENDL; @@ -6560,10 +6539,10 @@ class LLMuteParticle : public view_listener_t if (id.notNull()) { - std::string name; - gCacheName->getFullName(id, name); + LLAvatarName av_name; + LLAvatarNameCache::get(id, &av_name); - LLMute mute(id, name, LLMute::AGENT); + LLMute mute(id, av_name.getUserName(), LLMute::AGENT); if (LLMuteList::getInstance()->isMuted(mute.mID)) { LLMuteList::getInstance()->remove(mute); @@ -8402,6 +8381,15 @@ class LLToolsSelectTool : public view_listener_t { LLToolMgr::getInstance()->getCurrentToolset()->selectToolByIndex(5); } + + // Note: if floater is not visible LLViewerWindow::updateLayout() will + // attempt to open it, but it won't bring it to front or de-minimize. + if (gFloaterTools && (gFloaterTools->isMinimized() || !gFloaterTools->isShown() || !gFloaterTools->isFrontmost())) + { + gFloaterTools->setMinimized(FALSE); + gFloaterTools->openFloater(); + gFloaterTools->setVisibleAndFrontmost(TRUE); + } return true; } }; @@ -8618,7 +8606,12 @@ public: void handle_voice_morphing_subscribe() { - LLWeb::loadURLExternal(LLTrans::getString("voice_morphing_url")); + LLWeb::loadURL(LLTrans::getString("voice_morphing_url")); +} + +void handle_premium_voice_morphing_subscribe() +{ + LLWeb::loadURL(LLTrans::getString("premium_voice_morphing_url")); } class LLToggleUIHints : public view_listener_t @@ -8696,7 +8689,6 @@ void initialize_edit_menu() view_listener_t::addMenu(new LLEditDelete(), "Edit.Delete"); view_listener_t::addMenu(new LLEditSelectAll(), "Edit.SelectAll"); view_listener_t::addMenu(new LLEditDeselect(), "Edit.Deselect"); - view_listener_t::addMenu(new LLEditDuplicate(), "Edit.Duplicate"); view_listener_t::addMenu(new LLEditTakeOff(), "Edit.TakeOff"); view_listener_t::addMenu(new LLEditEnableUndo(), "Edit.EnableUndo"); view_listener_t::addMenu(new LLEditEnableRedo(), "Edit.EnableRedo"); @@ -8706,7 +8698,6 @@ void initialize_edit_menu() view_listener_t::addMenu(new LLEditEnableDelete(), "Edit.EnableDelete"); view_listener_t::addMenu(new LLEditEnableSelectAll(), "Edit.EnableSelectAll"); view_listener_t::addMenu(new LLEditEnableDeselect(), "Edit.EnableDeselect"); - view_listener_t::addMenu(new LLEditEnableDuplicate(), "Edit.EnableDuplicate"); } @@ -8814,6 +8805,8 @@ void initialize_menus() // Communicate > Voice morphing > Subscribe... commit.add("Communicate.VoiceMorphing.Subscribe", boost::bind(&handle_voice_morphing_subscribe)); + // Communicate > Voice morphing > Premium perk... + commit.add("Communicate.VoiceMorphing.PremiumPerk", boost::bind(&handle_premium_voice_morphing_subscribe)); LLVivoxVoiceClient * voice_clientp = LLVivoxVoiceClient::getInstance(); enable.add("Communicate.VoiceMorphing.NoVoiceMorphing.Check" , boost::bind(&LLVivoxVoiceClient::onCheckVoiceEffect, voice_clientp, "NoVoiceMorphing")); @@ -9115,6 +9108,7 @@ void initialize_menus() view_listener_t::addMenu(new LLObjectAttachToAvatar(true), "Object.AttachToAvatar"); view_listener_t::addMenu(new LLObjectAttachToAvatar(false), "Object.AttachAddToAvatar"); view_listener_t::addMenu(new LLObjectReturn(), "Object.Return"); + commit.add("Object.Duplicate", boost::bind(&LLSelectMgr::duplicate, LLSelectMgr::getInstance())); view_listener_t::addMenu(new LLObjectReportAbuse(), "Object.ReportAbuse"); view_listener_t::addMenu(new LLObjectMute(), "Object.Mute"); @@ -9136,6 +9130,7 @@ void initialize_menus() enable.add("Object.EnableSit", boost::bind(&enable_object_sit, _1)); view_listener_t::addMenu(new LLObjectEnableReturn(), "Object.EnableReturn"); + enable.add("Object.EnableDuplicate", boost::bind(&LLSelectMgr::canDuplicate, LLSelectMgr::getInstance())); view_listener_t::addMenu(new LLObjectEnableReportAbuse(), "Object.EnableReportAbuse"); enable.add("Avatar.EnableMute", boost::bind(&enable_object_mute)); diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp index 2ab59037e1..992470cb3a 100644 --- a/indra/newview/llviewermessage.cpp +++ b/indra/newview/llviewermessage.cpp @@ -1390,6 +1390,14 @@ void inventory_offer_mute_callback(const LLUUID& blocked_id, gSavedSettings.getString("NotificationChannelUUID")), OfferMatcher(blocked_id)); } + +void inventory_offer_mute_avatar_callback(const LLUUID& blocked_id, + const LLAvatarName& av_name) +{ + inventory_offer_mute_callback(blocked_id, av_name.getUserName(), false); +} + + std::string LLOfferInfo::mResponderType = "offer_info"; LLOfferInfo::LLOfferInfo() @@ -1538,7 +1546,14 @@ bool LLOfferInfo::inventory_offer_callback(const LLSD& notification, const LLSD& { if (notification_ptr != NULL) { - gCacheName->get(mFromID, mFromGroup, boost::bind(&inventory_offer_mute_callback, _1, _2, _3)); + if (mFromGroup) + { + gCacheName->getGroup(mFromID, boost::bind(&inventory_offer_mute_callback, _1, _2, _3)); + } + else + { + LLAvatarNameCache::get(mFromID, boost::bind(&inventory_offer_mute_avatar_callback, _1, _2)); + } } } @@ -1695,7 +1710,14 @@ bool LLOfferInfo::inventory_task_offer_callback(const LLSD& notification, const llassert(notification_ptr != NULL); if (notification_ptr != NULL) { - gCacheName->get(mFromID, mFromGroup, boost::bind(&inventory_offer_mute_callback, _1, _2, _3)); + if (mFromGroup) + { + gCacheName->getGroup(mFromID, boost::bind(&inventory_offer_mute_callback, _1, _2, _3)); + } + else + { + LLAvatarNameCache::get(mFromID, boost::bind(&inventory_offer_mute_avatar_callback, _1, _2)); + } } } @@ -1744,12 +1766,12 @@ bool LLOfferInfo::inventory_task_offer_callback(const LLSD& notification, const } else { - std::string full_name; - if (gCacheName->getFullName(mFromID, full_name)) + LLAvatarName av_name; + if (LLAvatarNameCache::get(mFromID, &av_name)) { from_string = LLTrans::getString("InvOfferAnObjectNamed") + " "+ LLTrans::getString("'") + mFromName - + LLTrans::getString("'")+" " + LLTrans::getString("InvOfferOwnedBy") + full_name; - chatHistory_string = mFromName + " " + LLTrans::getString("InvOfferOwnedBy") + " " + full_name; + + LLTrans::getString("'")+" " + LLTrans::getString("InvOfferOwnedBy") + av_name.getUserName(); + chatHistory_string = mFromName + " " + LLTrans::getString("InvOfferOwnedBy") + " " + av_name.getUserName(); } else { @@ -2601,9 +2623,9 @@ void process_improved_im(LLMessageSystem *msg, void **user_data) { original_name = original_name.substr(0, index); } + std::string legacy_name = gCacheName->buildLegacyName(original_name); - LLUUID agent_id; - gCacheName->getUUID(legacy_name, agent_id); + LLUUID agent_id = LLAvatarNameCache::findIdByName(legacy_name); if (agent_id.isNull()) { @@ -2662,6 +2684,7 @@ void process_improved_im(LLMessageSystem *msg, void **user_data) payload["subject"] = subj; payload["message"] = mes; payload["sender_name"] = name; + payload["sender_id"] = agent_id; payload["group_id"] = group_id; payload["inventory_name"] = item_name; payload["received_time"] = LLDate::now(); @@ -3038,16 +3061,17 @@ void process_improved_im(LLMessageSystem *msg, void **user_data) { return; } - else if (is_do_not_disturb) - { - send_do_not_disturb_message(msg, from_id); - } else if (gSavedSettings.getBOOL("VoiceCallsFriendsOnly") && (LLAvatarTracker::instance().getBuddyInfo(from_id) == NULL)) { return; } else { + if (is_do_not_disturb) + { + send_do_not_disturb_message(msg, from_id); + } + LLVector3 pos, look_at; U64 region_handle(0); U8 region_access(SIM_ACCESS_MIN); @@ -6182,7 +6206,7 @@ void handle_show_mean_events(void *) //LLFloaterBump::showInstance(); } -void mean_name_callback(const LLUUID &id, const std::string& full_name, bool is_group) +void mean_name_callback(const LLUUID &id, const LLAvatarName& av_name) { static const U32 max_collision_list_size = 20; if (gMeanCollisionList.size() > max_collision_list_size) @@ -6199,7 +6223,7 @@ void mean_name_callback(const LLUUID &id, const std::string& full_name, bool is_ LLMeanCollisionData *mcd = *iter; if (mcd->mPerp == id) { - mcd->mFullName = full_name; + mcd->mFullName = av_name.getUserName(); } } } @@ -6253,7 +6277,7 @@ void process_mean_collision_alert_message(LLMessageSystem *msgsystem, void **use { LLMeanCollisionData *mcd = new LLMeanCollisionData(gAgentID, perp, time, type, mag); gMeanCollisionList.push_front(mcd); - gCacheName->get(perp, false, boost::bind(&mean_name_callback, _1, _2, _3)); + LLAvatarNameCache::get(perp, boost::bind(&mean_name_callback, _1, _2)); } } LLFloaterBump* bumps_floater = LLFloaterBump::getInstance(); @@ -7030,10 +7054,10 @@ void send_lures(const LLSD& notification, const LLSD& response) // Record the offer. { - std::string target_name; - gCacheName->getFullName(target_id, target_name); // for im log filenames + LLAvatarName av_name; + LLAvatarNameCache::get(target_id, &av_name); // for im log filenames LLSD args; - args["TO_NAME"] = LLSLURL("agent", target_id, "displayname").getSLURLString();; + args["TO_NAME"] = LLSLURL("agent", target_id, "completename").getSLURLString();; LLSD payload; @@ -7116,10 +7140,10 @@ bool teleport_request_callback(const LLSD& notification, const LLSD& response) return false; } - std::string from_name; - gCacheName->getFullName(from_id, from_name); + LLAvatarName av_name; + LLAvatarNameCache::get(from_id, &av_name); - if(LLMuteList::getInstance()->isMuted(from_id) && !LLMuteList::getInstance()->isLinden(from_name)) + if(LLMuteList::getInstance()->isMuted(from_id) && !LLMuteList::getInstance()->isLinden(av_name.getUserName())) { return false; } @@ -7394,8 +7418,7 @@ bool callback_load_url(const LLSD& notification, const LLSD& response) } static LLNotificationFunctorRegistration callback_load_url_reg("LoadWebPage", callback_load_url); - -// We've got the name of the person who owns the object hurling the url. +// We've got the name of the person or group that owns the object hurling the url. // Display confirmation dialog. void callback_load_url_name(const LLUUID& id, const std::string& full_name, bool is_group) { @@ -7437,6 +7460,12 @@ void callback_load_url_name(const LLUUID& id, const std::string& full_name, bool } } +// We've got the name of the person who owns the object hurling the url. +void callback_load_url_avatar_name(const LLUUID& id, const LLAvatarName& av_name) +{ + callback_load_url_name(id, av_name.getUserName(), false); +} + void process_load_url(LLMessageSystem* msg, void**) { LLUUID object_id; @@ -7474,8 +7503,14 @@ void process_load_url(LLMessageSystem* msg, void**) // Add to list of pending name lookups gLoadUrlList.push_back(payload); - gCacheName->get(owner_id, owner_is_group, - boost::bind(&callback_load_url_name, _1, _2, _3)); + if (owner_is_group) + { + gCacheName->getGroup(owner_id, boost::bind(&callback_load_url_name, _1, _2, _3)); + } + else + { + LLAvatarNameCache::get(owner_id, boost::bind(&callback_load_url_avatar_name, _1, _2)); + } } diff --git a/indra/newview/llviewerparcelmgr.cpp b/indra/newview/llviewerparcelmgr.cpp index dddfb6745e..325d523992 100644 --- a/indra/newview/llviewerparcelmgr.cpp +++ b/indra/newview/llviewerparcelmgr.cpp @@ -706,7 +706,7 @@ bool LLViewerParcelMgr::allowAgentScripts(const LLViewerRegion* region, const LL bool LLViewerParcelMgr::allowAgentDamage(const LLViewerRegion* region, const LLParcel* parcel) const { return (region && region->getAllowDamage()) - && (parcel && parcel->getAllowDamage()); + || (parcel && parcel->getAllowDamage()); } BOOL LLViewerParcelMgr::isOwnedAt(const LLVector3d& pos_global) const @@ -2456,7 +2456,6 @@ void sanitize_corners(const LLVector3d &corner1, void LLViewerParcelMgr::cleanupGlobals() { - LLParcelSelection::sNullSelection = NULL; } LLViewerTexture* LLViewerParcelMgr::getBlockedImage() const diff --git a/indra/newview/llviewerstats.cpp b/indra/newview/llviewerstats.cpp index e918c7352c..8ff735a8c1 100644 --- a/indra/newview/llviewerstats.cpp +++ b/indra/newview/llviewerstats.cpp @@ -492,6 +492,7 @@ void send_stats() system["ram"] = (S32) gSysMemory.getPhysicalMemoryKB().value(); system["os"] = LLAppViewer::instance()->getOSInfo().getOSStringSimple(); system["cpu"] = gSysCPU.getCPUString(); + system["address_size"] = ADDRESS_SIZE; unsigned char MACAddress[MAC_ADDRESS_BYTES]; LLUUID::getNodeID(MACAddress); std::string macAddressString = llformat("%02x-%02x-%02x-%02x-%02x-%02x", diff --git a/indra/newview/llviewertexteditor.cpp b/indra/newview/llviewertexteditor.cpp index 09cdfe1309..9e09971ced 100644 --- a/indra/newview/llviewertexteditor.cpp +++ b/indra/newview/llviewertexteditor.cpp @@ -191,7 +191,7 @@ public: return false; } - /*virtual*/ S32 getNumChars(S32 num_pixels, S32 segment_offset, S32 line_offset, S32 max_chars) const + /*virtual*/ S32 getNumChars(S32 num_pixels, S32 segment_offset, S32 line_offset, S32 max_chars, S32 line_ind) const { // always draw at beginning of line if (line_offset == 0) @@ -1105,10 +1105,6 @@ BOOL LLViewerTextEditor::openEmbeddedItem(LLPointer<LLInventoryItem> item, llwch openEmbeddedSound( item, wc ); return TRUE; - case LLAssetType::AT_NOTECARD: - openEmbeddedNotecard( item, wc ); - return TRUE; - case LLAssetType::AT_LANDMARK: openEmbeddedLandmark( item, wc ); return TRUE; @@ -1117,6 +1113,7 @@ BOOL LLViewerTextEditor::openEmbeddedItem(LLPointer<LLInventoryItem> item, llwch openEmbeddedCallingcard( item, wc ); return TRUE; + case LLAssetType::AT_NOTECARD: case LLAssetType::AT_LSL_TEXT: case LLAssetType::AT_CLOTHING: case LLAssetType::AT_OBJECT: @@ -1182,11 +1179,6 @@ void LLViewerTextEditor::openEmbeddedLandmark( LLPointer<LLInventoryItem> item_p } } -void LLViewerTextEditor::openEmbeddedNotecard( LLInventoryItem* item, llwchar wc ) -{ - copyInventory(item, gInventoryCallbacks.registerCB(mInventoryCallback)); -} - void LLViewerTextEditor::openEmbeddedCallingcard( LLInventoryItem* item, llwchar wc ) { if(item && !item->getCreatorUUID().isNull()) diff --git a/indra/newview/llviewertexteditor.h b/indra/newview/llviewertexteditor.h index 477119d4f2..33cfca4f90 100644 --- a/indra/newview/llviewertexteditor.h +++ b/indra/newview/llviewertexteditor.h @@ -105,7 +105,6 @@ private: void openEmbeddedTexture( LLInventoryItem* item, llwchar wc ); void openEmbeddedSound( LLInventoryItem* item, llwchar wc ); void openEmbeddedLandmark( LLPointer<LLInventoryItem> item_ptr, llwchar wc ); - void openEmbeddedNotecard( LLInventoryItem* item, llwchar wc); void openEmbeddedCallingcard( LLInventoryItem* item, llwchar wc); void showCopyToInvDialog( LLInventoryItem* item, llwchar wc ); void showUnsavedAlertDialog( LLInventoryItem* item ); diff --git a/indra/newview/llviewertexturelist.cpp b/indra/newview/llviewertexturelist.cpp index d7080051da..0a3012ffef 100644 --- a/indra/newview/llviewertexturelist.cpp +++ b/indra/newview/llviewertexturelist.cpp @@ -1341,9 +1341,9 @@ LLPointer<LLImageJ2C> LLViewerTextureList::convertToUploadFile(LLPointer<LLImage // Returns min setting for TextureMemory (in MB) S32Megabytes LLViewerTextureList::getMinVideoRamSetting() { - S32Megabytes system_ram = gSysMemory.getPhysicalMemoryClamped(); + U32Megabytes system_ram = gSysMemory.getPhysicalMemoryKB(); //min texture mem sets to 64M if total physical mem is more than 1.5GB - return (system_ram > S32Megabytes(1500)) ? S32Megabytes(64) : gMinVideoRam ; + return (system_ram > U32Megabytes(1500)) ? S32Megabytes(64) : gMinVideoRam ; } //static @@ -1386,7 +1386,7 @@ S32Megabytes LLViewerTextureList::getMaxVideoRamSetting(bool get_recommended, fl LL_WARNS() << "VRAM amount not detected, defaulting to " << max_texmem << " MB" << LL_ENDL; } - S32Megabytes system_ram = gSysMemory.getPhysicalMemoryClamped(); // In MB + S32Megabytes system_ram = gSysMemory.getPhysicalMemoryKB(); // In MB //LL_INFOS() << "*** DETECTED " << system_ram << " MB of system memory." << LL_ENDL; if (get_recommended) max_texmem = llmin(max_texmem, system_ram/2); @@ -1439,7 +1439,7 @@ void LLViewerTextureList::updateMaxResidentTexMem(S32Megabytes mem) } //system mem - S32Megabytes system_ram = gSysMemory.getPhysicalMemoryClamped(); + S32Megabytes system_ram = gSysMemory.getPhysicalMemoryKB(); //minimum memory reserved for non-texture use. //if system_raw >= 1GB, reserve at least 512MB for non-texture use; diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index 7a60a8e9ac..feed5ba43d 100644 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -53,6 +53,7 @@ #include "llrender.h" #include "llvoiceclient.h" // for push-to-talk button handling +#include "stringize.h" // // TODO: Many of these includes are unnecessary. Remove them. @@ -394,7 +395,8 @@ public: #if LL_WINDOWS if (gSavedSettings.getBOOL("DebugShowMemory")) { - addText(xpos, ypos, llformat("Memory: %d (KB)", LLMemory::getWorkingSetSize() / 1024)); + addText(xpos, ypos, + STRINGIZE("Memory: " << (LLMemory::getCurrentRSS() / 1024) << " (KB)")); ypos += y_inc; } #endif @@ -2724,8 +2726,16 @@ BOOL LLViewerWindow::handleKey(KEY key, MASK mask) return TRUE; } - if ((gMenuBarView && gMenuBarView->handleAcceleratorKey(key, mask)) - ||(gLoginMenuBarView && gLoginMenuBarView->handleAcceleratorKey(key, mask))) + if (gAgent.isInitialized() + && (gAgent.getTeleportState() == LLAgent::TELEPORT_NONE || gAgent.getTeleportState() == LLAgent::TELEPORT_LOCAL) + && gMenuBarView + && gMenuBarView->handleAcceleratorKey(key, mask)) + { + LLViewerEventRecorder::instance().logKeyEvent(key, mask); + return TRUE; + } + + if (gLoginMenuBarView && gLoginMenuBarView->handleAcceleratorKey(key, mask)) { LLViewerEventRecorder::instance().logKeyEvent(key,mask); return TRUE; @@ -2855,8 +2865,16 @@ BOOL LLViewerWindow::handleKey(KEY key, MASK mask) } // give menus a chance to handle unmodified accelerator keys - if ((gMenuBarView && gMenuBarView->handleAcceleratorKey(key, mask)) - ||(gLoginMenuBarView && gLoginMenuBarView->handleAcceleratorKey(key, mask))) + if (gAgent.isInitialized() + && (gAgent.getTeleportState() == LLAgent::TELEPORT_NONE || gAgent.getTeleportState() == LLAgent::TELEPORT_LOCAL) + && gMenuBarView + && gMenuBarView->handleAcceleratorKey(key, mask)) + { + LLViewerEventRecorder::instance().logKeyEvent(key, mask); + return TRUE; + } + + if (gLoginMenuBarView && gLoginMenuBarView->handleAcceleratorKey(key, mask)) { return TRUE; } diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index 96a1beffbc..f6a16f7da1 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -118,6 +118,9 @@ extern U32 JOINT_COUNT_REQUIRED_FOR_FULLRIG; const F32 MAX_HOVER_Z = 2.0; const F32 MIN_HOVER_Z = -2.0; +const F32 MIN_ATTACHMENT_COMPLEXITY = 0.f; +const F32 MAX_ATTACHMENT_COMPLEXITY = 1.0e6f; + using namespace LLAvatarAppearanceDefines; //----------------------------------------------------------------------------- @@ -724,6 +727,8 @@ LLVOAvatar::LLVOAvatar(const LLUUID& id, { LLSceneMonitor::getInstance()->freezeAvatar((LLCharacter*)this); } + + mVisuallyMuteSetting = LLVOAvatar::VisualMuteSettings(LLRenderMuteList::getInstance()->getSavedVisualMuteSetting(getID())); } std::string LLVOAvatar::avString() const @@ -7071,7 +7076,9 @@ BOOL LLVOAvatar::isFullyLoaded() const bool LLVOAvatar::isTooComplex() const { bool too_complex; - if (isSelf() || mVisuallyMuteSetting == AV_ALWAYS_RENDER) + bool render_friend = (LLAvatarTracker::instance().isBuddy(getID()) && gSavedSettings.getBOOL("AlwaysRenderFriends")); + + if (isSelf() || render_friend || mVisuallyMuteSetting == AV_ALWAYS_RENDER) { too_complex = false; } @@ -9056,10 +9063,10 @@ void LLVOAvatar::calculateUpdateRenderComplexity() const LLVOVolume* volume = drawable->getVOVolume(); if (volume) { - U32 attachment_total_cost = 0; - U32 attachment_volume_cost = 0; - U32 attachment_texture_cost = 0; - U32 attachment_children_cost = 0; + F32 attachment_total_cost = 0; + F32 attachment_volume_cost = 0; + F32 attachment_texture_cost = 0; + F32 attachment_children_cost = 0; attachment_volume_cost += volume->getRenderCost(textures); @@ -9083,7 +9090,6 @@ void LLVOAvatar::calculateUpdateRenderComplexity() // add the cost of each individual texture in the linkset attachment_texture_cost += volume_texture->second; } - attachment_total_cost = attachment_volume_cost + attachment_texture_cost + attachment_children_cost; LL_DEBUGS("ARCdetail") << "Attachment costs " << attached_object->getAttachmentItemID() << " total: " << attachment_total_cost @@ -9092,7 +9098,8 @@ void LLVOAvatar::calculateUpdateRenderComplexity() << ", " << volume->numChildren() << " children: " << attachment_children_cost << LL_ENDL; - cost += attachment_total_cost; + // Limit attachment complexity to avoid signed integer flipping of the wearer's ACI + cost += (U32)llclamp(attachment_total_cost, MIN_ATTACHMENT_COMPLEXITY, MAX_ATTACHMENT_COMPLEXITY); } } } @@ -9229,8 +9236,9 @@ void LLVOAvatar::setVisualMuteSettings(VisualMuteSettings set) { mVisuallyMuteSetting = set; mNeedsImpostorUpdate = TRUE; -} + LLRenderMuteList::getInstance()->saveVisualMuteSetting(getID(), S32(set)); +} void LLVOAvatar::calcMutedAVColor() { diff --git a/indra/newview/llwindebug.cpp b/indra/newview/llwindebug.cpp index eff70ca0b2..92c80ce534 100644 --- a/indra/newview/llwindebug.cpp +++ b/indra/newview/llwindebug.cpp @@ -90,7 +90,7 @@ LONG NTAPI vectoredHandler(PEXCEPTION_POINTERS exception_infop) } // static -void LLWinDebug::init() +void LLWinDebug::initSingleton() { static bool s_first_run = true; // Load the dbghelp dll now, instead of waiting for the crash. @@ -135,7 +135,7 @@ void LLWinDebug::init() } } -void LLWinDebug::cleanup () +void LLWinDebug::cleanupSingleton() { gEmergencyMemoryReserve.release(); } diff --git a/indra/newview/llwindebug.h b/indra/newview/llwindebug.h index 90882cf04a..7e5818ba1c 100644 --- a/indra/newview/llwindebug.h +++ b/indra/newview/llwindebug.h @@ -36,9 +36,9 @@ class LLWinDebug: { LLSINGLETON_EMPTY_CTOR(LLWinDebug); public: - static void init(); + void initSingleton(); static void generateMinidump(struct _EXCEPTION_POINTERS *pExceptionInfo = NULL); - static void cleanup(); + void cleanupSingleton(); private: static void writeDumpToFile(MINIDUMP_TYPE type, MINIDUMP_EXCEPTION_INFORMATION *ExInfop, const std::string& filename); }; diff --git a/indra/newview/llwlanimator.cpp b/indra/newview/llwlanimator.cpp index 2142885767..c8879e73eb 100644 --- a/indra/newview/llwlanimator.cpp +++ b/indra/newview/llwlanimator.cpp @@ -155,17 +155,28 @@ F64 LLWLAnimator::getDayTime() // we're not solving the non-linear equation that determines sun phase // we're just linearly interpolating between the major points - if (phase <= 5.0 / 4.0) { + + if (phase <= 5.0 / 4.0) + { + // mDayTime from 0.33 to 0.75 (6:00 to 21:00) mDayTime = (1.0 / 3.0) * phase + (1.0 / 3.0); } + else if (phase > 7.0 / 4.0) + { + // maximum value for phase is 2 + // mDayTime from 0.25 to 0.33 (3:00 to 6:00) + mDayTime = (1.0 / 3.0) - (1.0 / 3.0) * (2 - phase); + } else { + // phase == 3/2 is where day restarts (24:00) + // mDayTime from 0.75 to 0.999 and 0 to 0.25 (21:00 to 03:00) mDayTime = phase - (1.0 / 2.0); - } - if(mDayTime > 1) - { - mDayTime--; + if(mDayTime > 1) + { + mDayTime--; + } } return mDayTime; diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index 26b71f70bb..c38dafee53 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -7766,12 +7766,10 @@ void LLPipeline::renderBloom(bool for_snapshot, F32 zoom_factor, int subfield) F32 fov = LLViewerCamera::getInstance()->getView(); const F32 default_fov = CameraFieldOfView * F_PI/180.f; - //const F32 default_aspect_ratio = gSavedSettings.getF32("CameraAspectRatio"); //F32 aspect_ratio = (F32) mScreen.getWidth()/(F32)mScreen.getHeight(); F32 dv = 2.f*default_focal_length * tanf(default_fov/2.f); - //F32 dh = 2.f*default_focal_length * tanf(default_fov*default_aspect_ratio/2.f); F32 focal_length = dv/(2*tanf(fov/2.f)); diff --git a/indra/newview/skins/default/textures/textures.xml b/indra/newview/skins/default/textures/textures.xml index 760c294f90..d757e39366 100644 --- a/indra/newview/skins/default/textures/textures.xml +++ b/indra/newview/skins/default/textures/textures.xml @@ -136,6 +136,7 @@ with the same filename but different name <texture name="Command_Facebook_Icon" file_name="toolbar_icons/facebook.png" preload="true" /> <texture name="Command_Flickr_Icon" file_name="toolbar_icons/flickr.png" preload="true" /> <texture name="Command_Gestures_Icon" file_name="toolbar_icons/gestures.png" preload="true" /> + <texture name="Command_Grid_Status_Icon" file_name="toolbar_icons/grid_status.png" preload="true" /> <texture name="Command_HowTo_Icon" file_name="toolbar_icons/howto.png" preload="true" /> <texture name="Command_Inventory_Icon" file_name="toolbar_icons/inventory.png" preload="true" /> <texture name="Command_Map_Icon" file_name="toolbar_icons/map.png" preload="true" /> diff --git a/indra/newview/skins/default/textures/toolbar_icons/grid_status.png b/indra/newview/skins/default/textures/toolbar_icons/grid_status.png Binary files differnew file mode 100644 index 0000000000..b92b93cfb4 --- /dev/null +++ b/indra/newview/skins/default/textures/toolbar_icons/grid_status.png diff --git a/indra/newview/skins/default/xui/da/floater_about.xml b/indra/newview/skins/default/xui/da/floater_about.xml index 779b168ae0..7654f0dcd6 100644 --- a/indra/newview/skins/default/xui/da/floater_about.xml +++ b/indra/newview/skins/default/xui/da/floater_about.xml @@ -24,7 +24,7 @@ Grafik kort: [GRAPHICS_CARD] J2C Decoder Version: [J2C_VERSION] Audio Driver Version: [AUDIO_DRIVER_VERSION] -LLCEFLib/CEF Version: [LLCEFLIB_VERSION] +CEF Version: [LIBCEF_VERSION] LibVLC Version: [LIBVLC_VERSION] Voice Server Version: [VOICE_VERSION] </floater.string> diff --git a/indra/newview/skins/default/xui/de/strings.xml b/indra/newview/skins/default/xui/de/strings.xml index 4a2cbcc81f..de20ed88a3 100644 --- a/indra/newview/skins/default/xui/de/strings.xml +++ b/indra/newview/skins/default/xui/de/strings.xml @@ -38,7 +38,7 @@ Grafikinitialisierung fehlgeschlagen. Bitte aktualisieren Sie Ihren Grafiktreiber. </string> <string name="AboutHeader"> - [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([CHANNEL]) + [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([ADDRESS_SIZE]bit) ([CHANNEL]) [[VIEWER_RELEASE_NOTES_URL] [ReleaseNotes]] </string> <string name="BuildConfig"> @@ -79,7 +79,7 @@ Erstellungszeit VFS (Cache): [VFS_TIME] <string name="AboutLibs"> J2C-Decoderversion: [J2C_VERSION] Audiotreiberversion: [AUDIO_DRIVER_VERSION] -LLCEFLib/CEF-Version: [LLCEFLIB_VERSION] +CEF-Version: [LIBCEF_VERSION] LibVLC-Version: [LIBVLC_VERSION] Voice-Server-Version: [VOICE_VERSION] </string> diff --git a/indra/newview/skins/default/xui/en/floater_about_land.xml b/indra/newview/skins/default/xui/en/floater_about_land.xml index 8391bacf51..a137770e26 100644 --- a/indra/newview/skins/default/xui/en/floater_about_land.xml +++ b/indra/newview/skins/default/xui/en/floater_about_land.xml @@ -2014,7 +2014,7 @@ Only large parcels can be listed in search. name="AllowedText" top="0" width="230"> - Allowed Residents ([COUNT]) + Allowed Residents ([COUNT], max [MAX]) </text> <name_list column_padding="0" @@ -2063,7 +2063,7 @@ Only large parcels can be listed in search. name="BanCheck" top="0" width="200"> - Banned Residents ([COUNT]) + Banned Residents ([COUNT], max [MAX]) </text> <name_list column_padding="0" diff --git a/indra/newview/skins/default/xui/en/floater_avatar_render_settings.xml b/indra/newview/skins/default/xui/en/floater_avatar_render_settings.xml new file mode 100644 index 0000000000..03e812d36d --- /dev/null +++ b/indra/newview/skins/default/xui/en/floater_avatar_render_settings.xml @@ -0,0 +1,66 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> +<floater + can_resize="true" + positioning="cascading" + height="200" + min_height="100" + min_width="230" + layout="topleft" + name="floater_avatar_render_settings" + save_rect="true" + single_instance="true" + reuse_instance="true" + title="AVATAR RENDER SETTINGS" + width="300"> + <string + name="av_never_render" + value="Never"/> + <string + name="av_always_render" + value="Always"/> + <filter_editor + follows="left|top|right" + height="23" + layout="topleft" + left="8" + right="-47" + label="Filter People" + max_length_chars="300" + name="people_filter_input" + text_color="Black" + text_pad_left="10" + top="4" /> + <menu_button + follows="top|right" + height="25" + image_hover_unselected="Toolbar_Middle_Over" + image_overlay="AddItem_Off" + image_selected="Toolbar_Middle_Selected" + image_unselected="Toolbar_Middle_Off" + layout="topleft" + left_pad="7" + menu_filename="menu_avatar_rendering_settings_add.xml" + menu_position="bottomleft" + name="plus_btn" + tool_tip="Actions on selected person" + top="3" + width="31" /> + <name_list + bottom="-8" + draw_heading="true" + follows="all" + left="8" + multi_select="false" + name="render_settings_list" + right="-8" + top="32"> + <name_list.columns + label="Name" + name="name" + relative_width="0.65" /> + <name_list.columns + label="Render setting" + name="setting" + relative_width="0.35" /> + </name_list> +</floater> diff --git a/indra/newview/skins/default/xui/en/floater_flickr.xml b/indra/newview/skins/default/xui/en/floater_flickr.xml index 52ef16c7e8..3b9c4894c1 100644 --- a/indra/newview/skins/default/xui/en/floater_flickr.xml +++ b/indra/newview/skins/default/xui/en/floater_flickr.xml @@ -9,7 +9,7 @@ save_rect="true" single_instance="true" reuse_instance="true" - title="UPLOAD TO FLICKR" + title="SHARE TO FLICKR" height="590" width="272"> <panel diff --git a/indra/newview/skins/default/xui/en/floater_grid_status.xml b/indra/newview/skins/default/xui/en/floater_grid_status.xml new file mode 100644 index 0000000000..b97bd8056d --- /dev/null +++ b/indra/newview/skins/default/xui/en/floater_grid_status.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<floater + positioning="cascading" + legacy_header_height="18" + can_resize="true" + height="775" + layout="topleft" + min_height="485" + min_width="485" + name="floater_grid_status" + help_topic="floater_grid_status" + save_rect="true" + save_visibility="true" + title="" + initial_mime_type="text/html" + width="780" + tab_stop="true" + filename="floater_web_content.xml"/> diff --git a/indra/newview/skins/default/xui/en/floater_inspect.xml b/indra/newview/skins/default/xui/en/floater_inspect.xml index bea35e5fc1..63334e2b24 100644 --- a/indra/newview/skins/default/xui/en/floater_inspect.xml +++ b/indra/newview/skins/default/xui/en/floater_inspect.xml @@ -27,21 +27,21 @@ tool_tip="Select an object from this list to highlight it in-world" top="20"> <scroll_list.columns - dynamic_width="true" + relative_width="0.25" label="Object Name" name="object_name" /> <scroll_list.columns - dynamic_width="true" + relative_width="0.25" label="Owner Name" name="owner_name" /> <scroll_list.columns - dynamic_width="true" + relative_width="0.25" label="Creator Name" name="creator_name" /> <scroll_list.columns + relative_width="0.25" label="Creation Date" - name="creation_date" - width="150" /> + name="creation_date" /> <scroll_list.commit_callback function="Inspect.SelectObject" /> </scroll_list> diff --git a/indra/newview/skins/default/xui/en/floater_pathfinding_linksets.xml b/indra/newview/skins/default/xui/en/floater_pathfinding_linksets.xml index 52d03cc432..00d70556b4 100644 --- a/indra/newview/skins/default/xui/en/floater_pathfinding_linksets.xml +++ b/indra/newview/skins/default/xui/en/floater_pathfinding_linksets.xml @@ -290,7 +290,7 @@ layout="topleft" left="0" height="67" - width="1010"> + width="1070"> <text name="linksets_actions_label" height="13" diff --git a/indra/newview/skins/default/xui/en/floater_preferences.xml b/indra/newview/skins/default/xui/en/floater_preferences.xml index 9a9101e0da..5ca527ad20 100644 --- a/indra/newview/skins/default/xui/en/floater_preferences.xml +++ b/indra/newview/skins/default/xui/en/floater_preferences.xml @@ -120,6 +120,13 @@ layout="topleft" help_topic="preferences_advanced1_tab" name="advanced1" /> + <panel + class="panel_preference" + filename="panel_preferences_uploads.xml" + label="Uploads" + layout="topleft" + help_topic="preferences_uploads_tab" + name="uploads" /> </tab_container> </floater> diff --git a/indra/newview/skins/default/xui/en/floater_scene_load_stats.xml b/indra/newview/skins/default/xui/en/floater_scene_load_stats.xml index b53698a9f2..62cce3a1e3 100644 --- a/indra/newview/skins/default/xui/en/floater_scene_load_stats.xml +++ b/indra/newview/skins/default/xui/en/floater_scene_load_stats.xml @@ -7,6 +7,7 @@ save_rect="true" save_visibility="true" title="SCENE LOAD STATISTICS" + min_width="250" width="400"> <scroll_container follows="top|left|bottom|right" bottom="400" diff --git a/indra/newview/skins/default/xui/en/floater_script_debug.xml b/indra/newview/skins/default/xui/en/floater_script_debug.xml index 53d4925214..cd88048d6b 100644 --- a/indra/newview/skins/default/xui/en/floater_script_debug.xml +++ b/indra/newview/skins/default/xui/en/floater_script_debug.xml @@ -7,6 +7,7 @@ help_topic="script_debug_floater" save_rect="true" title="Script Warning/Error" + reuse_instance="true" width="450"> <tab_container follows="left|top|right|bottom" diff --git a/indra/newview/skins/default/xui/en/floater_stats.xml b/indra/newview/skins/default/xui/en/floater_stats.xml index be9b93837a..e4f735740b 100644 --- a/indra/newview/skins/default/xui/en/floater_stats.xml +++ b/indra/newview/skins/default/xui/en/floater_stats.xml @@ -8,6 +8,7 @@ save_rect="true" save_visibility="true" title="STATISTICS" + min_width="250" width="270"> <scroll_container follows="all" height="380" diff --git a/indra/newview/skins/default/xui/en/floater_tos.xml b/indra/newview/skins/default/xui/en/floater_tos.xml index 590d9d1844..612c894b59 100644 --- a/indra/newview/skins/default/xui/en/floater_tos.xml +++ b/indra/newview/skins/default/xui/en/floater_tos.xml @@ -70,7 +70,7 @@ top="32" word_wrap="true" width="552"> - You will need to go to my.secondlife.com and log in to accept the Terms of Service before you can proceed. Thank you! + You will need to go to https://my.secondlife.com and log in to accept the Terms of Service before you can proceed. Thank you! </text> <web_browser trusted_content="true" diff --git a/indra/newview/skins/default/xui/en/menu_attachment_other.xml b/indra/newview/skins/default/xui/en/menu_attachment_other.xml index 2f60bab0b7..49b9ac273d 100644 --- a/indra/newview/skins/default/xui/en/menu_attachment_other.xml +++ b/indra/newview/skins/default/xui/en/menu_attachment_other.xml @@ -130,10 +130,13 @@ </menu_item_call> <menu_item_separator /> - + <context_menu + label="Render Avatar" + layout="topleft" + name="Render Avatar"> <menu_item_check name="RenderNormally" - label="Render Normally"> + label="Default"> <menu_item_check.on_check function="Avatar.CheckImpostorMode" parameter="0" /> @@ -142,26 +145,26 @@ parameter="0" /> </menu_item_check> <menu_item_check - name="DoNotRender" - label="Do Not Render"> + name="AlwaysRenderFully" + label="Always"> <menu_item_check.on_check function="Avatar.CheckImpostorMode" - parameter="1" /> + parameter="2" /> <menu_item_check.on_click function="Avatar.SetImpostorMode" - parameter="1" /> + parameter="2" /> </menu_item_check> <menu_item_check - name="AlwaysRenderFully" - label="Render Fully"> + name="DoNotRender" + label="Never"> <menu_item_check.on_check function="Avatar.CheckImpostorMode" - parameter="2" /> + parameter="1" /> <menu_item_check.on_click function="Avatar.SetImpostorMode" - parameter="2" /> + parameter="1" /> </menu_item_check> - + </context_menu> <menu_item_separator layout="topleft" name="Impostor seperator"/> diff --git a/indra/newview/skins/default/xui/en/menu_avatar_other.xml b/indra/newview/skins/default/xui/en/menu_avatar_other.xml index ddfff23410..c5426cb232 100644 --- a/indra/newview/skins/default/xui/en/menu_avatar_other.xml +++ b/indra/newview/skins/default/xui/en/menu_avatar_other.xml @@ -121,9 +121,13 @@ <menu_item_separator /> + <context_menu + label="Render Avatar" + layout="topleft" + name="Render Avatar"> <menu_item_check name="RenderNormally" - label="Render Normally"> + label="Default"> <menu_item_check.on_check function="Avatar.CheckImpostorMode" parameter="0" /> @@ -132,25 +136,26 @@ parameter="0" /> </menu_item_check> <menu_item_check - name="DoNotRender" - label="Do Not Render"> + name="AlwaysRenderFully" + label="Always"> <menu_item_check.on_check function="Avatar.CheckImpostorMode" - parameter="1" /> + parameter="2" /> <menu_item_check.on_click function="Avatar.SetImpostorMode" - parameter="1" /> + parameter="2" /> </menu_item_check> <menu_item_check - name="AlwaysRenderFully" - label="Render Fully"> + name="DoNotRender" + label="Never"> <menu_item_check.on_check function="Avatar.CheckImpostorMode" - parameter="2" /> + parameter="1" /> <menu_item_check.on_click function="Avatar.SetImpostorMode" - parameter="2" /> + parameter="1" /> </menu_item_check> + </context_menu> <menu_item_separator layout="topleft" name="Impostor seperator"/> diff --git a/indra/newview/skins/default/xui/en/menu_avatar_rendering_settings.xml b/indra/newview/skins/default/xui/en/menu_avatar_rendering_settings.xml new file mode 100644 index 0000000000..5163cd3115 --- /dev/null +++ b/indra/newview/skins/default/xui/en/menu_avatar_rendering_settings.xml @@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<context_menu + layout="topleft" + name="Settings"> + <menu_item_check + label="Default" + layout="topleft" + name="default"> + <on_click function="Settings.SetRendering" parameter="default"/> + <on_check function="Settings.IsSelected" parameter="default" /> + </menu_item_check> + <menu_item_check + label="Always render" + layout="topleft" + name="always_render"> + <on_click function="Settings.SetRendering" parameter="always"/> + <on_check function="Settings.IsSelected" parameter="always" /> + </menu_item_check> + <menu_item_check + label="Never render" + layout="topleft" + name="never_render"> + <on_click function="Settings.SetRendering" parameter="never"/> + <on_check function="Settings.IsSelected" parameter="never" /> + </menu_item_check> +</context_menu> diff --git a/indra/newview/skins/default/xui/en/menu_avatar_rendering_settings_add.xml b/indra/newview/skins/default/xui/en/menu_avatar_rendering_settings_add.xml new file mode 100644 index 0000000000..c64b24ed70 --- /dev/null +++ b/indra/newview/skins/default/xui/en/menu_avatar_rendering_settings_add.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8" standalone="yes" ?> +<toggleable_menu + name="menu_settings_add.xml" + left="0" bottom="0" visible="false" + mouse_opaque="false"> + <menu_item_call + label="Always Render a Resident..." + name="add_avatar_always_render"> + <on_click + function="Settings.AddNewEntry" parameter="always"/> + </menu_item_call> + <menu_item_call + label="Never Render a Resident..." + name="add_avatar_never_render"> + <on_click + function="Settings.AddNewEntry" parameter="never"/> + </menu_item_call> +</toggleable_menu> diff --git a/indra/newview/skins/default/xui/en/menu_edit.xml b/indra/newview/skins/default/xui/en/menu_edit.xml index 99061e089a..6f83756f83 100644 --- a/indra/newview/skins/default/xui/en/menu_edit.xml +++ b/indra/newview/skins/default/xui/en/menu_edit.xml @@ -62,15 +62,6 @@ <menu_item_call.on_enable function="Edit.EnableDelete" /> </menu_item_call> - <menu_item_call - label="Duplicate" - name="Duplicate" - shortcut="control|D"> - <menu_item_call.on_click - function="Edit.Duplicate" /> - <menu_item_call.on_enable - function="Edit.EnableDuplicate" /> - </menu_item_call> <menu_item_separator/> <menu_item_call label="Select All" diff --git a/indra/newview/skins/default/xui/en/menu_gesture_gear.xml b/indra/newview/skins/default/xui/en/menu_gesture_gear.xml index b08d21e8f4..c1458977ca 100644 --- a/indra/newview/skins/default/xui/en/menu_gesture_gear.xml +++ b/indra/newview/skins/default/xui/en/menu_gesture_gear.xml @@ -5,8 +5,7 @@ name="menu_gesture_gear" visible="false"> <menu_item_call - font="SansSerifBold" - label="Add/Remove from Favorites" + label="Activate/Deactivate selected gesture" layout="topleft" name="activate"> <on_click diff --git a/indra/newview/skins/default/xui/en/menu_inventory.xml b/indra/newview/skins/default/xui/en/menu_inventory.xml index 5b8a9413bf..e1f9269c70 100644 --- a/indra/newview/skins/default/xui/en/menu_inventory.xml +++ b/indra/newview/skins/default/xui/en/menu_inventory.xml @@ -322,6 +322,43 @@ </menu_item_call> </menu> <menu + label="Use as default for" + layout="topleft" + name="upload_def"> + <menu_item_call + label="Image uploads" + layout="topleft" + name="Image uploads"> + <menu_item_call.on_click + function="Inventory.FileUploadLocation" + parameter="texture" /> + </menu_item_call> + <menu_item_call + label="Sound uploads" + layout="topleft" + name="Sound uploads"> + <menu_item_call.on_click + function="Inventory.FileUploadLocation" + parameter="sound" /> + </menu_item_call> + <menu_item_call + label="Animation uploads" + layout="topleft" + name="Animation uploads"> + <menu_item_call.on_click + function="Inventory.FileUploadLocation" + parameter="animation" /> + </menu_item_call> + <menu_item_call + label="Model uploads" + layout="topleft" + name="Model uploads"> + <menu_item_call.on_click + function="Inventory.FileUploadLocation" + parameter="model" /> + </menu_item_call> + </menu> + <menu label="Change Type" layout="topleft" name="Change Type"> diff --git a/indra/newview/skins/default/xui/en/menu_inventory_gear_default.xml b/indra/newview/skins/default/xui/en/menu_inventory_gear_default.xml index 61cc9dfe77..d95541df80 100644 --- a/indra/newview/skins/default/xui/en/menu_inventory_gear_default.xml +++ b/indra/newview/skins/default/xui/en/menu_inventory_gear_default.xml @@ -9,6 +9,7 @@ <menu_item_call label="New Inventory Window" layout="topleft" + shortcut="control|shift|I" name="new_window"> <on_click function="Inventory.GearDefault.Custom.Action" diff --git a/indra/newview/skins/default/xui/en/menu_login.xml b/indra/newview/skins/default/xui/en/menu_login.xml index a39ee5fddd..8cd0c415f4 100644 --- a/indra/newview/skins/default/xui/en/menu_login.xml +++ b/indra/newview/skins/default/xui/en/menu_login.xml @@ -20,6 +20,18 @@ function="Floater.Toggle" parameter="preferences" /> </menu_item_call> + <menu_item_check + label="Show Grid Picker" + name="Show Grid Picker" + visible="false" + shortcut="control|shift|G"> + <on_check + function="CheckControl" + parameter="ForceShowGrid" /> + <on_click + function="ToggleControl" + parameter="ForceShowGrid" /> + </menu_item_check> <menu_item_separator /> <menu_item_call label="Exit [APP_NAME]" @@ -287,18 +299,6 @@ parameter="4" /> </menu_item_check> </menu> - <menu_item_check - label="Show Grid Picker" - name="Show Grid Picker" - visible="false" - shortcut="control|shift|G"> - <on_check - function="CheckControl" - parameter="ForceShowGrid" /> - <on_click - function="ToggleControl" - parameter="ForceShowGrid" /> - </menu_item_check> <menu_item_call label="Show Notifications Console" name="Show Notifications Console" diff --git a/indra/newview/skins/default/xui/en/menu_people_blocked_gear.xml b/indra/newview/skins/default/xui/en/menu_people_blocked_gear.xml index 63295ea27b..01ca38f51a 100644 --- a/indra/newview/skins/default/xui/en/menu_people_blocked_gear.xml +++ b/indra/newview/skins/default/xui/en/menu_people_blocked_gear.xml @@ -13,6 +13,80 @@ function="Block.Enable" parameter="unblock_item" /> </menu_item_call> + + <menu_item_check + label="Block Voice" + layout="topleft" + name="BlockVoice"> + <on_check + function="Block.Check" + parameter="block_voice" /> + <on_click + function="Block.Action" + parameter="block_voice" /> + <on_enable + function="Block.Enable" + parameter="block_voice" /> + <on_visible + function="Block.Visible" + parameter="block_voice" /> + </menu_item_check> + + <menu_item_check + label="Block Text" + layout="topleft" + name="MuteText"> + <on_check + function="Block.Check" + parameter="block_text" /> + <on_click + function="Block.Action" + parameter="block_text" /> + <on_enable + function="Block.Enable" + parameter="block_text" /> + <on_visible + function="Block.Visible" + parameter="block_text" /> + </menu_item_check> + + <menu_item_check + label="Block Particles" + layout="topleft" + name="MuteText"> + <on_check + function="Block.Check" + parameter="block_particles" /> + <on_click + function="Block.Action" + parameter="block_particles" /> + <on_enable + function="Block.Enable" + parameter="block_particles" /> + <on_visible + function="Block.Visible" + parameter="block_particles" /> + </menu_item_check> + + <menu_item_check + label="Block Object Sounds" + layout="topleft" + name="BlockObjectSounds"> + <on_check + function="Block.Check" + parameter="block_obj_sounds" /> + <on_click + function="Block.Action" + parameter="block_obj_sounds" /> + <on_enable + function="Block.Enable" + parameter="block_obj_sounds" /> + <on_visible + function="Block.Visible" + parameter="block_obj_sounds" /> + </menu_item_check> + + <menu_item_separator /> <menu_item_call label="Profile..." name="profile"> diff --git a/indra/newview/skins/default/xui/en/menu_viewer.xml b/indra/newview/skins/default/xui/en/menu_viewer.xml index f911c2da7b..12df3749f6 100644 --- a/indra/newview/skins/default/xui/en/menu_viewer.xml +++ b/indra/newview/skins/default/xui/en/menu_viewer.xml @@ -337,6 +337,12 @@ <menu_item_call.on_click function="Communicate.VoiceMorphing.Subscribe" /> </menu_item_call> + <menu_item_call + label="Premium perk..." + name="PremiumPerk"> + <menu_item_call.on_click + function="Communicate.VoiceMorphing.PremiumPerk" /> + </menu_item_call> </menu> <menu_item_check label="Gestures..." @@ -447,6 +453,13 @@ function="Floater.Toggle" parameter="mini_map" /> </menu_item_check> + <menu_item_call + label="Events" + name="Events"> + <menu_item_call.on_click + function="Advanced.ShowURL" + parameter="http://events.secondlife.com"/> + </menu_item_call> <menu_item_check label="Search..." name="Search" @@ -1012,12 +1025,31 @@ <menu_item_call.on_enable function="Object.EnableReturn" /> </menu_item_call> + <menu_item_call + label="Duplicate" + name="DuplicateObject" + shortcut="control|D"> + <menu_item_call.on_click + function="Object.Duplicate" /> + <menu_item_call.on_enable + function="Object.EnableDuplicate" /> + </menu_item_call> </menu> <menu create_jump_keys="true" label="Scripts" name="Scripts" tear_off="true"> + <menu_item_check + label="Script warnings/errors..." + name="Script debug"> + <menu_item_check.on_check + function="Floater.IsOpen" + parameter="script_debug" /> + <menu_item_check.on_click + function="Floater.ToggleOrBringToFront" + parameter="script_debug" /> + </menu_item_check> <menu_item_call label="Recompile Scripts (Mono)" name="Mono"> diff --git a/indra/newview/skins/default/xui/en/mime_types.xml b/indra/newview/skins/default/xui/en/mime_types.xml index 8d8d546b24..8a810f32a6 100644 --- a/indra/newview/skins/default/xui/en/mime_types.xml +++ b/indra/newview/skins/default/xui/en/mime_types.xml @@ -133,18 +133,29 @@ media_plugin_libvlc </impl> </scheme> - <scheme name="libvlc"> - <label name="libvlc_label"> - LibVLC supported media - </label> - <widgettype> - movie - </widgettype> - <impl> - media_plugin_libvlc - </impl> - </scheme> - <mimetype name="blank"> + <scheme name="example"> + <label name="example_label"> + Example Plugin scheme trigger + </label> + <widgettype> + movie + </widgettype> + <impl> + media_plugin_example + </impl> + </scheme> + <scheme name="libvlc"> + <label name="libvlc_label"> + LibVLC supported media + </label> + <widgettype> + movie + </widgettype> + <impl> + media_plugin_libvlc + </impl> + </scheme> + <mimetype name="blank"> <label name="blank_label"> - None - </label> diff --git a/indra/newview/skins/default/xui/en/notifications.xml b/indra/newview/skins/default/xui/en/notifications.xml index 512deed054..3fcd91f89b 100644 --- a/indra/newview/skins/default/xui/en/notifications.xml +++ b/indra/newview/skins/default/xui/en/notifications.xml @@ -341,8 +341,7 @@ Initialization with the Marketplace failed because of a system or network error. type="alertmodal"> The transaction with the Marketplace failed with the following error : - Reason : '[ERROR_REASON]' - [ERROR_DESCRIPTION] + [ERROR_REASON][ERROR_DESCRIPTION] <usetemplate name="okbutton" @@ -1940,6 +1939,14 @@ Please make sure none are locked, and that you own all of them. <notification icon="alertmodal.tga" + name="CannotLinkAcrossRegions" + type="alertmodal"> +Objects cannot be linked across region boundaries. + <tag>fail</tag> + </notification> + + <notification + icon="alertmodal.tga" name="CannotLinkDifferentOwners" type="alertmodal"> Unable to link because not all of the objects have the same owner. @@ -4031,7 +4038,7 @@ An update was downloaded. It will be installed during restart. icon="alertmodal.tga" name="UpdateCheckError" type="alertmodal"> -An error occured while checking for update. +An error occurred while checking for update. Please try again later. <tag>confirm</tag> <usetemplate @@ -4326,7 +4333,6 @@ Cannot offer friendship at this time. Please try again in a moment. Do Not Disturb is on. You will not be notified of incoming communications. - Other residents will receive your Do Not Disturb response (set in Preferences > General). -- Teleportation offers will be declined. - Voice calls will be rejected. <usetemplate ignoretext="I change my status to Do Not Disturb mode" @@ -9849,29 +9855,29 @@ Eject failed because you don't have admin permission for that parcel. <notification icon="alertmodal.tga" - name="CantMoveObjectParcelFull" + name="CMOParcelFull" type="notify"> <tag>fail</tag> -Can't move object '[OBJECT_NAME]' to -[OBJ_POSITION] in region [REGION_NAME] because the parcel is full. +Can't move object '[O]' to +[P] in region [R] because the parcel is full. </notification> <notification icon="alertmodal.tga" - name="CantMoveObjectParcelPerms" + name="CMOParcelPerms" type="notify"> <tag>fail</tag> -Can't move object '[OBJECT_NAME]' to -[OBJ_POSITION] in region [REGION_NAME] because your objects are not allowed on this parcel. +Can't move object '[O]' to +[P] in region [R] because your objects are not allowed on this parcel. </notification> <notification icon="alertmodal.tga" - name="CantMoveObjectParcelResources" + name="CMOParcelResources" type="notify"> <tag>fail</tag> -Can't move object '[OBJECT_NAME]' to -[OBJ_POSITION] in region [REGION_NAME] because there are not enough resources for this object on this parcel. +Can't move object '[O]' to +[P] in region [R] because there are not enough resources for this object on this parcel. </notification> <notification @@ -9884,29 +9890,29 @@ Copy failed because you lack access to that parcel. <notification icon="alertmodal.tga" - name="CantMoveObjectRegionVersion" + name="CMORegionVersion" type="notify"> - <tag>fail</tag> -Can't move object '[OBJECT_NAME]' to -[OBJ_POSITION] in region [REGION_NAME] because the other region is running an older version which does not support receiving this object via region crossing. + <tag>fail</tag> + Can't move object '[O]' to + [P] in region [R] because the other region is running an older version which does not support receiving this object via region crossing. </notification> <notification icon="alertmodal.tga" - name="CantMoveObjectNavMesh" + name="CMONavMesh" type="notify"> <tag>fail</tag> -Can't move object '[OBJECT_NAME]' to -[OBJ_POSITION] in region [REGION_NAME] because you cannot modify the navmesh across region boundaries. +Can't move object '[O]' to +[P] in region [R] because you cannot modify the navmesh across region boundaries. </notification> <notification icon="alertmodal.tga" - name="CantMoveObjectWTF" + name="CMOWTF" type="notify"> <tag>fail</tag> -Can't move object '[OBJECT_NAME]' to -[OBJ_POSITION] in region [REGION_NAME] because of an unknown reason. ([FAILURE_TYPE]) +Can't move object '[O]' to +[P] in region [R] because of an unknown reason. ([F]) </notification> <notification diff --git a/indra/newview/skins/default/xui/en/panel_block_list_sidetray.xml b/indra/newview/skins/default/xui/en/panel_block_list_sidetray.xml index 53d0252215..574e5f3cbc 100644 --- a/indra/newview/skins/default/xui/en/panel_block_list_sidetray.xml +++ b/indra/newview/skins/default/xui/en/panel_block_list_sidetray.xml @@ -90,13 +90,26 @@ top_delta="0" width="31"/> </panel> + <text + type="string" + length="1" + follows="left|top|right" + height="14" + layout="topleft" + right="-10" + top_pad="4" + left="3" + use_ellipses="true" + name="block_limit"> + [COUNT] entries in your block list, and the limit is [LIMIT]. + </text> <block_list follows="all" - height="273" + height="255" layout="topleft" left="3" name="blocked" tool_tip="List of currently blocked Residents" - top="31" + top_pad="4" right="-1"/> </panel> diff --git a/indra/newview/skins/default/xui/en/panel_flickr_photo.xml b/indra/newview/skins/default/xui/en/panel_flickr_photo.xml index e31695645d..6074ab9ef6 100644 --- a/indra/newview/skins/default/xui/en/panel_flickr_photo.xml +++ b/indra/newview/skins/default/xui/en/panel_flickr_photo.xml @@ -237,7 +237,7 @@ Use "" for multi-word tags top_pad="7" left="10" height="23" - label="Upload" + label="Share" name="post_photo_btn" width="100"> <button.commit_callback diff --git a/indra/newview/skins/default/xui/en/panel_notify_textbox.xml b/indra/newview/skins/default/xui/en/panel_notify_textbox.xml index d5b6057233..a679ca7f8c 100644 --- a/indra/newview/skins/default/xui/en/panel_notify_textbox.xml +++ b/indra/newview/skins/default/xui/en/panel_notify_textbox.xml @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="utf-8" standalone="yes" ?> <panel background_visible="true" - height="220" + height="215" label="instant_message" layout="topleft" left="0" @@ -10,21 +10,19 @@ width="305"> <string name="message_max_lines_count" - value="7" /> + value="14" /> <panel - bevel_style="none" - follows="left|right|top" - height="185" - label="info_panel" - layout="topleft" - left="0" - name="info_panel" - top="0" - width="305"> - <text_editor - bg_readonly_color="0.0 0.0 0.0 0" - enabled="false" - follows="left|right|top|bottom" + bevel_style="none" + follows="all" + height="120" + label="info_panel" + layout="topleft" + left="0" + name="info_panel" + top="0" + width="305"> + <text + follows="all" font="SansSerif" height="110" layout="topleft" @@ -34,30 +32,40 @@ read_only="true" text_color="white" text_readonly_color="white" - top="10" + top="0" width="285" wrap="true" parse_highlights="true" parse_urls="true"/> - <text_editor - parse_urls="true" - enabled="true" - follows="all" - height="50" + </panel> + <panel + bevel_style="none" + follows="left|right|bottom" + height="55" + label="info_panel" layout="topleft" - left="10" - max_length="250" - name="message" - parse_highlights="true" - read_only="false" - top_pad="10" - type="string" - use_ellipses="true" - value="message" - width="285" - word_wrap="true" - parse_url="false" > - </text_editor> + left="0" + name="textbox_panel" + top_pad="5" + width="305"> + <text_editor + parse_urls="true" + enabled="true" + follows="all" + height="50" + layout="topleft" + left="10" + max_length="250" + name="message" + parse_highlights="true" + read_only="false" + top ="0" + type="string" + use_ellipses="true" + value="message" + width="285" + word_wrap="true"> + </text_editor> </panel> <panel background_visible="false" @@ -68,7 +76,7 @@ layout="topleft" left="10" name="control_panel" - top_pad="0"> + top_pad="5"> <!-- Notes: This panel holds the Ignore button and possibly other buttons of notification. diff --git a/indra/newview/skins/default/xui/en/panel_outfits_inventory.xml b/indra/newview/skins/default/xui/en/panel_outfits_inventory.xml index ff0714adbb..eeb930485e 100644 --- a/indra/newview/skins/default/xui/en/panel_outfits_inventory.xml +++ b/indra/newview/skins/default/xui/en/panel_outfits_inventory.xml @@ -26,10 +26,11 @@ layout="topleft" left="5" name="appearance_tabs" - tab_min_width="150" + tab_min_width="100" tab_height="30" tab_position="top" halign="center" + hide_scroll_arrows="true" top="8" width="315"> <panel diff --git a/indra/newview/skins/default/xui/en/panel_preferences_chat.xml b/indra/newview/skins/default/xui/en/panel_preferences_chat.xml index 8d55e311f6..440c6613d5 100644 --- a/indra/newview/skins/default/xui/en/panel_preferences_chat.xml +++ b/indra/newview/skins/default/xui/en/panel_preferences_chat.xml @@ -432,18 +432,16 @@ top_pad="6" name="inventory_offer" width="150" /> - + <view_border + bevel_style="none" + height="0" + layout="topleft" + left="0" + name="cost_text_border" + top_pad="7" + width="492"/> </panel> - <view_border - bevel_style="none" - height="0" - layout="topleft" - left="13" - name="cost_text_border" - top_pad="5" - width="495"/> - <panel height="50" layout="topleft" diff --git a/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml b/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml index 32cbbff8b7..4692a226d9 100644 --- a/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml +++ b/indra/newview/skins/default/xui/en/panel_preferences_graphics1.xml @@ -231,6 +231,34 @@ m </text> + <check_box + control_name="WindLightUseAtmosShaders" + height="16" + initial_value="true" + label="Atmospheric shaders" + layout="topleft" + left="30" + name="WindLightUseAtmosShaders" + top_delta="24" + width="280"> + <check_box.commit_callback + function="Pref.VertexShaderEnable" /> + </check_box> + + <check_box + control_name="RenderDeferred" + height="16" + initial_value="true" + label="Advanced Lighting Model" + layout="topleft" + left="30" + name="UseLightShaders" + top_delta="24" + width="256"> + <check_box.commit_callback + function="Pref.VertexShaderEnable" /> + </check_box> + <slider control_name="IndirectMaxComplexity" tool_tip="Controls at what point a visually complex avatar is drawn as a JellyDoll" @@ -246,7 +274,7 @@ max_val="101" name="IndirectMaxComplexity" show_text="false" - top_delta="24" + top_delta="60" width="300"> <slider.commit_callback function="Pref.UpdateIndirectMaxComplexity" @@ -265,34 +293,28 @@ width="65"> 0 </text> - <check_box - control_name="WindLightUseAtmosShaders" + control_name="AlwaysRenderFriends" height="16" initial_value="true" - label="Atmospheric shaders" + label="Always Render Friends" layout="topleft" left="30" - name="WindLightUseAtmosShaders" + name="AlwaysRenderFriends" top_delta="24" - width="280"> - <check_box.commit_callback - function="Pref.VertexShaderEnable" /> + width="256"> </check_box> - - <check_box - control_name="RenderDeferred" - height="16" - initial_value="true" - label="Advanced Lighting Model" + <button + height="23" + label="Exceptions..." layout="topleft" - left="30" - name="UseLightShaders" + left="48" + name="RenderExceptionsButton" top_delta="24" - width="256"> - <check_box.commit_callback - function="Pref.VertexShaderEnable" /> - </check_box> + width="100"> + <button.commit_callback + function="Pref.RenderExceptions"/> + </button> <!-- End of Basic Settings block --> diff --git a/indra/newview/skins/default/xui/en/panel_preferences_uploads.xml b/indra/newview/skins/default/xui/en/panel_preferences_uploads.xml new file mode 100644 index 0000000000..343c2db2f1 --- /dev/null +++ b/indra/newview/skins/default/xui/en/panel_preferences_uploads.xml @@ -0,0 +1,139 @@ +<?xml version="1.0" encoding="UTF-8"?> +<panel + border="true" + follows="all" + height="408" + label="Uploads" + layout="topleft" + left="102" + name="uploads" + top="1" + width="517"> + <text + type="string" + length="1" + follows="left|top" + height="12" + layout="topleft" + left="33" + name="title" + top_pad="10" + width="250"> + Current destination folders for uploads + </text> + + <text + type="string" + length="1" + follows="left|top" + height="12" + layout="topleft" + left="37" + name="title_models" + top_pad="17" + width="100"> + Images + </text> + <text + type="string" + use_ellipses="true" + follows="left|top" + height="27" + layout="topleft" + font.style="BOLD" + left="37" + name="upload_textures" + top_pad="5" + width="370" + word_wrap="true"/> + + <text + type="string" + length="1" + follows="left|top" + height="12" + layout="topleft" + left="37" + name="title_sounds" + top_pad="7" + width="100"> + Sounds + </text> + <text + type="string" + use_ellipses="true" + follows="left|top" + height="27" + layout="topleft" + font.style="BOLD" + left="37" + name="upload_sounds" + top_pad="5" + width="370" + word_wrap="true"/> + + <text + type="string" + length="1" + follows="left|top" + height="12" + layout="topleft" + left="37" + name="title_animation" + top_pad="7" + width="100"> + Animations + </text> + <text + type="string" + use_ellipses="true" + follows="left|top" + height="27" + layout="topleft" + font.style="BOLD" + left="37" + name="upload_animation" + top_pad="5" + width="370" + word_wrap="true"/> + + <text + type="string" + length="1" + follows="left|top" + height="12" + layout="topleft" + left="37" + name="title_animation" + top_pad="7" + width="100"> + Models + </text> + <text + type="string" + use_ellipses="true" + follows="left|top" + height="27" + layout="topleft" + font.style="BOLD" + left="37" + name="upload_models" + top_pad="5" + width="370" + word_wrap="true"/> + + <text + type="string" + length="1" + follows="left|top" + height="30" + layout="topleft" + font.style="ITALIC" + left="33" + name="upload_help" + top_pad="6" + width="387"> + To change a destination folder, right click on it in inventory and choose + "Use as default for" + </text> +</panel> diff --git a/indra/newview/skins/default/xui/en/panel_snapshot_options.xml b/indra/newview/skins/default/xui/en/panel_snapshot_options.xml index 265217ef60..305cce1cbe 100644 --- a/indra/newview/skins/default/xui/en/panel_snapshot_options.xml +++ b/indra/newview/skins/default/xui/en/panel_snapshot_options.xml @@ -48,7 +48,7 @@ image_overlay_alignment="left" image_top_pad="-1" imgoverlay_label_space="10" - label="Upload to Profile" + label="Share to Profile Feed" layout="topleft" name="save_to_profile_btn" left_delta="0" @@ -65,7 +65,7 @@ image_overlay_alignment="left" image_top_pad="0" imgoverlay_label_space="10" - label="Upload to Facebook" + label="Share to Facebook" layout="topleft" left_delta="0" name="send_to_facebook_btn" @@ -82,7 +82,7 @@ image_overlay_alignment="left" image_top_pad="0" imgoverlay_label_space="10" - label="Upload to Twitter" + label="Share to Twitter" layout="topleft" left_delta="0" name="send_to_twitter_btn" @@ -99,7 +99,7 @@ image_overlay_alignment="left" image_top_pad="0" imgoverlay_label_space="10" - label="Upload to Flickr" + label="Share to Flickr" layout="topleft" left_delta="0" name="send_to_flickr_btn" diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml index 6b3422d892..f8bbda320a 100644 --- a/indra/newview/skins/default/xui/en/strings.xml +++ b/indra/newview/skins/default/xui/en/strings.xml @@ -61,7 +61,7 @@ VFS (cache) creation time: [VFS_TIME] <string name="AboutLibs"> J2C Decoder Version: [J2C_VERSION] Audio Driver Version: [AUDIO_DRIVER_VERSION] -LLCEFLib/CEF Version: [LLCEFLIB_VERSION] +[LIBCEF_VERSION] LibVLC Version: [LIBVLC_VERSION] Voice Server Version: [VOICE_VERSION] </string> @@ -2312,7 +2312,8 @@ We are accessing your account on the [[MARKETPLACE_CREATE_STORE_URL] Marketplace The [[MARKETPLACE_CREATE_STORE_URL] Marketplace store] is returning errors. </string> <string name="InventoryMarketplaceError"> -This feature is currently in Beta. Please add your name to this [http://goo.gl/forms/FCQ7UXkakz Google form] if you would like to participate. +An error occurred while opening Marketplace Listings. +If you continue to receive this message, please contact Second Life support for assistance at http://support.secondlife.com </string> <string name="InventoryMarketplaceListingsNoItemsTitle">Your Marketplace Listings folder is empty.</string> <string name="InventoryMarketplaceListingsNoItemsTooltip"></string> @@ -3628,7 +3629,10 @@ If you continue to receive this message, contact the [SUPPORT_SITE]. Conference with [AGENT_NAME] </string> <string name="inventory_item_offered-im"> - Inventory item offered + Inventory item '[ITEM_NAME]' offered + </string> + <string name="inventory_folder_offered-im"> + Inventory folder '[ITEM_NAME]' offered </string> <string name="share_alert"> Drag items from inventory here @@ -3736,7 +3740,8 @@ If you continue to receive this message, contact the [SUPPORT_SITE]. <string name="Home position set.">Home position set.</string> - <string name="voice_morphing_url">http://secondlife.com/landing/voicemorphing</string> + <string name="voice_morphing_url">https://secondlife.com/destination/voice-island</string> + <string name="premium_voice_morphing_url">https://secondlife.com/destination/voice-morphing-premium</string> <!-- Financial operations strings --> <string name="paid_you_ldollars">[NAME] paid you L$[AMOUNT] [REASON].</string> @@ -3815,7 +3820,7 @@ Abuse Report</string> <string name="Male - Laugh">Male - Laugh</string> <string name="Male - Repulsed">Male - Repulsed</string> <string name="Male - Shrug">Male - Shrug</string> - <string name="Male - Stick tougue out">Male - Stick tougue out</string> + <string name="Male - Stick tougue out">Male - Stick tongue out</string> <string name="Male - Wow">Male - Wow</string> <string name="Female - Chuckle">Female - Chuckle</string> @@ -3834,7 +3839,7 @@ Abuse Report</string> <string name="Female - Please">Female - Please</string> <string name="Female - Repulsed">Female - Repulsed</string> <string name="Female - Shrug">Female - Shrug</string> - <string name="Female - Stick tougue out">Female - Stick tougue out</string> + <string name="Female - Stick tougue out">Female - Stick tongue out</string> <string name="Female - Wow">Female - Wow</string> <string name="/bow">/bow</string> @@ -3879,9 +3884,9 @@ Abuse Report</string> <string name="words_separator" value=", "/> <string name="server_is_down"> - Despite our best efforts, something unexpected has gone wrong. + Despite our best efforts, something unexpected has gone wrong. - Please check status.secondlifegrid.net to see if there is a known problem with the service. +Please check http://status.secondlifegrid.net to see if there is a known problem with the service. If you continue to experience problems, please check your network and firewall setup. </string> @@ -4070,6 +4075,7 @@ Try enclosing path to the editor with double quotes. <string name="Command_Facebook_Label">Facebook</string> <string name="Command_Flickr_Label">Flickr</string> <string name="Command_Gestures_Label">Gestures</string> + <string name="Command_Grid_Status_Label">Grid status</string> <string name="Command_HowTo_Label">How to</string> <string name="Command_Inventory_Label">Inventory</string> <string name="Command_Map_Label">Map</string> @@ -4102,6 +4108,7 @@ Try enclosing path to the editor with double quotes. <string name="Command_Facebook_Tooltip">Post to Facebook</string> <string name="Command_Flickr_Tooltip">Upload to Flickr</string> <string name="Command_Gestures_Tooltip">Gestures for your avatar</string> + <string name="Command_Grid_Status_Tooltip">Show current Grid status</string> <string name="Command_HowTo_Tooltip">How to do common tasks</string> <string name="Command_Inventory_Tooltip">View and use your belongings</string> <string name="Command_Map_Tooltip">Map of the world</string> diff --git a/indra/newview/skins/default/xui/en/widgets/location_input.xml b/indra/newview/skins/default/xui/en/widgets/location_input.xml index 61ec046649..674be59753 100644 --- a/indra/newview/skins/default/xui/en/widgets/location_input.xml +++ b/indra/newview/skins/default/xui/en/widgets/location_input.xml @@ -133,7 +133,7 @@ name="damage_text" width="35" height="18" - top="17" + top="18" follows="right|top" halign="right" font="SansSerifSmall" diff --git a/indra/newview/skins/default/xui/es/strings.xml b/indra/newview/skins/default/xui/es/strings.xml index 192d32c267..765226e6bd 100644 --- a/indra/newview/skins/default/xui/es/strings.xml +++ b/indra/newview/skins/default/xui/es/strings.xml @@ -29,7 +29,7 @@ Error de inicialización de gráficos. Actualiza tu controlador de gráficos. </string> <string name="AboutHeader"> - [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([CHANNEL]) + [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([ADDRESS_SIZE]bit) ([CHANNEL]) [[VIEWER_RELEASE_NOTES_URL] [ReleaseNotes]] </string> <string name="BuildConfig"> @@ -70,8 +70,8 @@ Tiempo de creación de VFS (caché): [VFS_TIME] <string name="AboutLibs"> Versión de J2C Decoder: [J2C_VERSION] Versión de Audio Driver: [AUDIO_DRIVER_VERSION] -Versión de LLCEFLib/CEF: [LLCEFLIB_VERSION] -Versión de LibVLC: [LLCEFLIB_VERSION] +Versión de CEF: [LIBCEF_VERSION] +Versión de LibVLC: [LIBVLC_VERSION] Versión de Voice Server: [VOICE_VERSION] </string> <string name="AboutTraffic"> diff --git a/indra/newview/skins/default/xui/fr/strings.xml b/indra/newview/skins/default/xui/fr/strings.xml index 40a41b93ab..7c1d05bb83 100644 --- a/indra/newview/skins/default/xui/fr/strings.xml +++ b/indra/newview/skins/default/xui/fr/strings.xml @@ -38,7 +38,7 @@ Échec d'initialisation des graphiques. Veuillez mettre votre pilote graphique à jour. </string> <string name="AboutHeader"> - [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([CHANNEL]) + [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([ADDRESS_SIZE]bit) ([CHANNEL]) [[VIEWER_RELEASE_NOTES_URL] [Notes de version]] </string> <string name="BuildConfig"> @@ -79,7 +79,7 @@ Durée de création VFS (cache) : [VFS_TIME] <string name="AboutLibs"> Version J2C Decoder : [J2C_VERSION] Version Audio Driver : [AUDIO_DRIVER_VERSION] -Version LLCEFLib/CEF : [LLCEFLIB_VERSION] +Version CEF : [LIBCEF_VERSION] Version LibVLC : [LIBVLC_VERSION] Version serveur vocal : [VOICE_VERSION] </string> diff --git a/indra/newview/skins/default/xui/it/strings.xml b/indra/newview/skins/default/xui/it/strings.xml index 8246f91d17..e6edfb6de4 100644 --- a/indra/newview/skins/default/xui/it/strings.xml +++ b/indra/newview/skins/default/xui/it/strings.xml @@ -35,7 +35,7 @@ Inizializzazione grafica non riuscita. Aggiorna il driver della scheda grafica! </string> <string name="AboutHeader"> - [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([CHANNEL]) + [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([ADDRESS_SIZE]bit) ([CHANNEL]) [[VIEWER_RELEASE_NOTES_URL] [ReleaseNotes]] </string> <string name="BuildConfig"> @@ -76,7 +76,7 @@ Data/ora creazione VFS (cache): [VFS_TIME] <string name="AboutLibs"> Versione J2C Decoder: [J2C_VERSION] Versione Driver audio: [AUDIO_DRIVER_VERSION] -Versione LLCEFLib/CEF: [LLCEFLIB_VERSION] +Versione CEF: [LIBCEF_VERSION] Versione LibVLC: [LIBVLC_VERSION] Versione Server voice: [VOICE_VERSION] </string> diff --git a/indra/newview/skins/default/xui/ja/strings.xml b/indra/newview/skins/default/xui/ja/strings.xml index 586b8ab2d3..92b62c9c2f 100644 --- a/indra/newview/skins/default/xui/ja/strings.xml +++ b/indra/newview/skins/default/xui/ja/strings.xml @@ -38,7 +38,7 @@ グラフィックを初期化できませんでした。グラフィックドライバを更新してください。 </string> <string name="AboutHeader"> - [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([CHANNEL]) + [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([ADDRESS_SIZE]bit) ([CHANNEL]) [[VIEWER_RELEASE_NOTES_URL] [ReleaseNotes]] </string> <string name="BuildConfig"> @@ -79,7 +79,7 @@ VFS(キャッシュ)作成時間: [VFS_TIME] <string name="AboutLibs"> J2C デコーダバージョン:[J2C_VERSION] オーディオドライババージョン:[AUDIO_DRIVER_VERSION] -LLCEFLib/CEF バージョン: [LLCEFLIB_VERSION] +CEF バージョン: [LIBCEF_VERSION] LibVLC バージョン: [LIBVLC_VERSION] ボイスサーバーバージョン:[VOICE_VERSION] </string> diff --git a/indra/newview/skins/default/xui/pl/strings.xml b/indra/newview/skins/default/xui/pl/strings.xml index e9dd18043d..9aece1221d 100644 --- a/indra/newview/skins/default/xui/pl/strings.xml +++ b/indra/newview/skins/default/xui/pl/strings.xml @@ -43,7 +43,7 @@ Wersja OpenGL: [OPENGL_VERSION] Wersja dekodera J2C: [J2C_VERSION] Wersja sterownika dźwięku (Audio Driver): [AUDIO_DRIVER_VERSION] -Wersja LLCEFLib/CEF: [LLCEFLIB_VERSION] +Wersja CEF: [LIBCEF_VERSION] Wersja LibVLC: [LIBVLC_VERSION] Wersja serwera głosu (Voice Server): [VOICE_VERSION] </string> diff --git a/indra/newview/skins/default/xui/pt/strings.xml b/indra/newview/skins/default/xui/pt/strings.xml index 207b4e7097..94b69634d4 100644 --- a/indra/newview/skins/default/xui/pt/strings.xml +++ b/indra/newview/skins/default/xui/pt/strings.xml @@ -29,7 +29,7 @@ Falha na inicialização dos gráficos. Atualize seu driver gráfico! </string> <string name="AboutHeader"> - [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([CHANNEL]) + [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([ADDRESS_SIZE]bit) ([CHANNEL]) [[VIEWER_RELEASE_NOTES_URL] [ReleaseNotes]] </string> <string name="BuildConfig"> @@ -70,7 +70,7 @@ Tempo de criação de VFS (cache): [VFS_TIME] <string name="AboutLibs"> Versão do J2C Decoder: [J2C_VERSION] Versão do driver de áudio: [AUDIO_DRIVER_VERSION] -Versão de LLCEFLib/CEF: [LLCEFLIB_VERSION] +Versão de CEF: [LIBCEF_VERSION] Versão da LibVLC: [LIBVLC_VERSION] Versão do servidor de voz: [VOICE_VERSION] </string> diff --git a/indra/newview/skins/default/xui/ru/strings.xml b/indra/newview/skins/default/xui/ru/strings.xml index e44d63b3b9..7a003b536a 100644 --- a/indra/newview/skins/default/xui/ru/strings.xml +++ b/indra/newview/skins/default/xui/ru/strings.xml @@ -38,7 +38,7 @@ Ошибка инициализации графики. Обновите графический драйвер! </string> <string name="AboutHeader"> - [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([CHANNEL]) + [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([ADDRESS_SIZE]bit) ([CHANNEL]) [[VIEWER_RELEASE_NOTES_URL] [ReleaseNotes]] </string> <string name="BuildConfig"> @@ -79,7 +79,7 @@ SLURL: <nolink>[SLURL]</nolink> <string name="AboutLibs"> Версия декодера J2C: [J2C_VERSION] Версия драйвера звука: [AUDIO_DRIVER_VERSION] -Версия LLCEFLib/CEF: [LLCEFLIB_VERSION] +Версия CEF: [LIBCEF_VERSION] Версия LibVLC: [LIBVLC_VERSION] Версия голосового сервера: [VOICE_VERSION] </string> diff --git a/indra/newview/skins/default/xui/tr/strings.xml b/indra/newview/skins/default/xui/tr/strings.xml index 7b4bf1fca6..53b95d69dd 100644 --- a/indra/newview/skins/default/xui/tr/strings.xml +++ b/indra/newview/skins/default/xui/tr/strings.xml @@ -38,7 +38,7 @@ Grafik başlatma başarılamadı. Lütfen grafik sürücünüzü güncelleştirin! </string> <string name="AboutHeader"> - [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([CHANNEL]) + [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([ADDRESS_SIZE]bit) ([CHANNEL]) [[VIEWER_RELEASE_NOTES_URL] [ReleaseNotes]] </string> <string name="BuildConfig"> @@ -79,7 +79,7 @@ VFS (önbellek) oluşturma zamanı: [VFS_TIME] <string name="AboutLibs"> J2C Kod Çözücü Sürümü: [J2C_VERSION] Ses Sürücüsü Sürümü: [AUDIO_DRIVER_VERSION] -LLCEFLib/CEF Sürümü: [LLCEFLIB_VERSION] +CEF Sürümü: [LIBCEF_VERSION] LibVLC Sürümü: [LIBVLC_VERSION] Ses Sunucusu Sürümü: [VOICE_VERSION] </string> diff --git a/indra/newview/skins/default/xui/zh/strings.xml b/indra/newview/skins/default/xui/zh/strings.xml index ec08c9f91e..51a108126b 100644 --- a/indra/newview/skins/default/xui/zh/strings.xml +++ b/indra/newview/skins/default/xui/zh/strings.xml @@ -38,7 +38,7 @@ 顯像初始化失敗。 請更新你的顯像卡驅動程式! </string> <string name="AboutHeader"> - [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([CHANNEL]) + [APP_NAME] [VIEWER_VERSION_0].[VIEWER_VERSION_1].[VIEWER_VERSION_2].[VIEWER_VERSION_3] ([ADDRESS_SIZE]bit) ([CHANNEL]) [[VIEWER_RELEASE_NOTES_URL] [ReleaseNotes]] </string> <string name="BuildConfig"> @@ -79,7 +79,7 @@ VFS(快取)建立時間:[VFS_TIME] <string name="AboutLibs"> J2C 解碼器版本: [J2C_VERSION] 音效驅動程式版本: [AUDIO_DRIVER_VERSION] -LLCEFLib/CEF版本:[LLCEFLIB_VERSION] +CEF版本:[LIBCEF_VERSION] LibVLC版本:[LIBVLC_VERSION]N] 語音伺服器版本: [VOICE_VERSION] </string> diff --git a/indra/newview/viewer_manifest.py b/indra/newview/viewer_manifest.py index 6fb9479564..142951da25 100755 --- a/indra/newview/viewer_manifest.py +++ b/indra/newview/viewer_manifest.py @@ -391,13 +391,9 @@ class WindowsManifest(ViewerManifest): if self.args['configuration'].lower() == 'debug': self.path("msvcr120d.dll") self.path("msvcp120d.dll") - self.path("msvcr100d.dll") - self.path("msvcp100d.dll") else: self.path("msvcr120.dll") self.path("msvcp120.dll") - self.path("msvcr100.dll") - self.path("msvcp100.dll") # Vivox runtimes self.path("SLVoice.exe") @@ -439,33 +435,39 @@ class WindowsManifest(ViewerManifest): self.path("media_plugin_libvlc.dll") self.end_prefix() + # Media plugins - Example (useful for debugging - not shipped with release viewer) + if self.channel_type() != 'release': + if self.prefix(src='../media_plugins/example/%s' % self.args['configuration'], dst="llplugin"): + self.path("media_plugin_example.dll") + self.end_prefix() + # CEF runtime files - debug if self.args['configuration'].lower() == 'debug': if self.prefix(src=os.path.join(os.pardir, 'packages', 'bin', 'debug'), dst="llplugin"): + self.path("chrome_elf.dll") self.path("d3dcompiler_43.dll") self.path("d3dcompiler_47.dll") self.path("libcef.dll") self.path("libEGL.dll") self.path("libGLESv2.dll") - self.path("llceflib_host.exe") + self.path("dullahan_host.exe") self.path("natives_blob.bin") self.path("snapshot_blob.bin") self.path("widevinecdmadapter.dll") - self.path("wow_helper.exe") self.end_prefix() else: # CEF runtime files - not debug (release, relwithdebinfo etc.) if self.prefix(src=os.path.join(os.pardir, 'packages', 'bin', 'release'), dst="llplugin"): + self.path("chrome_elf.dll") self.path("d3dcompiler_43.dll") self.path("d3dcompiler_47.dll") self.path("libcef.dll") self.path("libEGL.dll") self.path("libGLESv2.dll") - self.path("llceflib_host.exe") + self.path("dullahan_host.exe") self.path("natives_blob.bin") self.path("snapshot_blob.bin") self.path("widevinecdmadapter.dll") - self.path("wow_helper.exe") self.end_prefix() # MSVC DLLs needed for CEF and have to be in same directory as plugin @@ -633,6 +635,13 @@ class WindowsManifest(ViewerManifest): Caption "%(caption)s" """ + if(self.args['arch'].lower() == 'x86_64'): + engage_registry="SetRegView 64" + program_files="$PROGRAMFILES64" + else: + engage_registry="SetRegView 32" + program_files="$PROGRAMFILES32" + tempfile = "secondlife_setup_tmp.nsi" # the following replaces strings in the nsi template # it also does python-style % substitution @@ -641,6 +650,8 @@ class WindowsManifest(ViewerManifest): "%%SOURCE%%":self.get_src_prefix(), "%%INST_VARS%%":inst_vars_template % substitution_strings, "%%INSTALL_FILES%%":self.nsi_file_commands(True), + "%%PROGRAMFILES%%":program_files, + "%%ENGAGEREGISTRY%%":engage_registry, "%%DELETE_FILES%%":self.nsi_file_commands(False)}) # We use the Unicode version of NSIS, available from @@ -839,26 +850,30 @@ class DarwinManifest(ViewerManifest): except OSError as err: print "Can't symlink %s -> %s: %s" % (src, dst, err) - # LLCefLib helper apps go inside SLPlugin.app + # Dullahan helper apps go inside SLPlugin.app if self.prefix(src="", dst="SLPlugin.app/Contents/Frameworks"): - for helperappfile in ('LLCefLib Helper.app', - 'LLCefLib Helper EH.app'): + for helperappfile in ('DullahanHelper.app'): self.path2basename(relpkgdir, helperappfile) pluginframeworkpath = self.dst_path_of('Chromium Embedded Framework.framework'); # Putting a Frameworks directory under Contents/MacOS - # isn't canonical, but the path baked into LLCefLib - # Helper.app/Contents/MacOS/LLCefLib Helper is: + # isn't canonical, but the path baked into Dullahan + # Helper.app/Contents/MacOS/DullahanHelper is: # @executable_path/Frameworks/Chromium Embedded Framework.framework/Chromium Embedded Framework # (notice, not @executable_path/../Frameworks/etc.) # So we'll create a symlink (below) from there back to the # Frameworks directory nested under SLPlugin.app. helperframeworkpath = \ - self.dst_path_of('LLCefLib Helper.app/Contents/MacOS/' + self.dst_path_of('DullahanHelper.app/Contents/MacOS/' 'Frameworks/Chromium Embedded Framework.framework') self.end_prefix() + helperexecutablepath = self.dst_path_of('SLPlugin.app/Contents/Frameworks/DullahanHelper.app/Contents/MacOS/DullahanHelper') + self.run_command('install_name_tool -change ' + '"@rpath/Frameworks/Chromium Embedded Framework.framework/Chromium Embedded Framework" ' + '"@executable_path/Frameworks/Chromium Embedded Framework.framework/Chromium Embedded Framework" "%s"' % helperexecutablepath) + # SLPlugin plugins if self.prefix(src="", dst="llplugin"): self.path2basename("../media_plugins/cef/" + self.args['configuration'], @@ -874,13 +889,19 @@ class DarwinManifest(ViewerManifest): self.end_prefix() # copy LibVLC plugins folder - if self.prefix(src=os.path.join(os.pardir, 'packages', 'lib', 'release', 'plugins' ), dst="plugins"): - self.path( "lib*_plugin.dylib" ) + if self.prefix(src=os.path.join(os.pardir, 'packages', 'lib', 'release', 'plugins' ), dst="lib"): + self.path( "*.dylib" ) self.path( "plugins.dat" ) self.end_prefix() self.end_prefix("llplugin") + # do this install_name_tool *after* media plugin is copied over + dylibexecutablepath = self.dst_path_of('llplugin/media_plugin_cef.dylib') + self.run_command('install_name_tool -change ' + '"@rpath/Frameworks/Chromium Embedded Framework.framework/Chromium Embedded Framework" ' + '"@executable_path/../Frameworks/Chromium Embedded Framework.framework/Chromium Embedded Framework" "%s"' % dylibexecutablepath) + self.end_prefix("Resources") # CEF framework goes inside Second Life.app/Contents/Frameworks @@ -918,7 +939,7 @@ class DarwinManifest(ViewerManifest): # Life.app/Contents/Frameworks/Chromium Embedded Framework.framework origin, target = pluginframeworkpath, frameworkpath symlinkf(target, origin) - # from SLPlugin.app/Contents/Frameworks/LLCefLib + # from SLPlugin.app/Contents/Frameworks/Dullahan # Helper.app/Contents/MacOS/Frameworks/Chromium Embedded # Framework.framework back to # SLPlugin.app/Contents/Frameworks/Chromium Embedded Framework.framework @@ -961,7 +982,7 @@ class DarwinManifest(ViewerManifest): # make sure we don't have stale files laying about self.remove(sparsename, finalname) - self.run_command('hdiutil create %(sparse)r -volname %(vol)r -fs HFS+ -type SPARSE -megabytes 1000 -layout SPUD' % { + self.run_command('hdiutil create %(sparse)r -volname %(vol)r -fs HFS+ -type SPARSE -megabytes 1300 -layout SPUD' % { 'sparse':sparsename, 'vol':volname}) |