summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.hgtags11
-rw-r--r--BuildParams6
-rw-r--r--autobuild.xml769
-rw-r--r--doc/contributions.txt14
-rw-r--r--indra/cmake/Copy3rdPartyLibs.cmake4
-rw-r--r--indra/cmake/Variables.cmake1
-rw-r--r--indra/llcommon/llversionviewer.h2
-rw-r--r--indra/llimage/llimagedimensionsinfo.cpp83
-rw-r--r--indra/llimage/llimagedimensionsinfo.h3
-rw-r--r--indra/llui/lllineeditor.cpp5
-rw-r--r--indra/llui/lllineeditor.h1
-rw-r--r--indra/llui/lltextbase.cpp103
-rw-r--r--indra/llui/lltextbase.h4
-rw-r--r--indra/llwindow/llwindowwin32.cpp9
-rw-r--r--indra/media_plugins/winmmshim/forwarding_api.cpp173
-rw-r--r--indra/media_plugins/winmmshim/forwarding_api.h1
-rw-r--r--indra/media_plugins/winmmshim/winmm_shim.cpp22
-rw-r--r--indra/newview/app_settings/settings.xml29
-rw-r--r--indra/newview/character/avatar_lad.xml20
-rw-r--r--indra/newview/llappviewer.cpp8
-rw-r--r--indra/newview/llbreastmotion.cpp36
-rw-r--r--indra/newview/llbreastmotion.h36
-rw-r--r--indra/newview/lldateutil.cpp4
-rw-r--r--indra/newview/llexpandabletextbox.cpp33
-rw-r--r--indra/newview/llexpandabletextbox.h6
-rw-r--r--indra/newview/llfloaterpreference.cpp38
-rw-r--r--indra/newview/llfloaterpreference.h4
-rw-r--r--indra/newview/llimfloater.cpp7
-rw-r--r--indra/newview/llinventorybridge.cpp2
-rw-r--r--indra/newview/llinventorymodel.cpp19
-rw-r--r--indra/newview/llinventorymodel.h5
-rw-r--r--indra/newview/llinventorymodelbackgroundfetch.cpp6
-rw-r--r--indra/newview/llinventoryobserver.cpp11
-rw-r--r--indra/newview/llinventoryobserver.h1
-rw-r--r--indra/newview/llnearbychatbar.cpp14
-rw-r--r--indra/newview/llnearbychatbar.h1
-rw-r--r--indra/newview/llpaneleditwearable.cpp6
-rw-r--r--indra/newview/llpanellogin.cpp37
-rw-r--r--indra/newview/llphysicsmotion.cpp1418
-rw-r--r--indra/newview/llphysicsmotion.h242
-rw-r--r--indra/newview/llpolymorph.cpp10
-rw-r--r--indra/newview/llsidetraylistener.cpp21
-rw-r--r--indra/newview/llsidetraylistener.h21
-rw-r--r--indra/newview/llstartup.cpp4
-rw-r--r--indra/newview/llsyswellwindow.cpp2
-rw-r--r--indra/newview/lltoastalertpanel.cpp5
-rw-r--r--indra/newview/lltooldraganddrop.cpp4
-rw-r--r--indra/newview/llviewerchat.cpp14
-rw-r--r--indra/newview/llviewerchat.h6
-rw-r--r--indra/newview/llviewerinventory.cpp29
-rw-r--r--indra/newview/llviewermenu.cpp4
-rw-r--r--indra/newview/llviewertexture.cpp2
-rw-r--r--indra/newview/llwaterparammanager.cpp33
-rw-r--r--indra/newview/llwaterparammanager.h6
-rw-r--r--indra/newview/llwearabletype.cpp2
-rw-r--r--indra/newview/llworld.cpp69
-rw-r--r--indra/newview/skins/default/colors.xml3
-rw-r--r--indra/newview/skins/default/xui/da/panel_preferences_chat.xml3
-rw-r--r--indra/newview/skins/default/xui/da/panel_preferences_sound.xml3
-rw-r--r--indra/newview/skins/default/xui/de/panel_preferences_chat.xml3
-rw-r--r--indra/newview/skins/default/xui/de/panel_preferences_sound.xml3
-rw-r--r--indra/newview/skins/default/xui/en/floater_preferences.xml2
-rw-r--r--indra/newview/skins/default/xui/en/menu_viewer.xml10
-rw-r--r--indra/newview/skins/default/xui/en/panel_preferences_alerts.xml4
-rw-r--r--indra/newview/skins/default/xui/en/panel_preferences_chat.xml20
-rw-r--r--indra/newview/skins/default/xui/en/panel_preferences_general.xml21
-rw-r--r--indra/newview/skins/default/xui/en/panel_preferences_move.xml9
-rw-r--r--indra/newview/skins/default/xui/en/panel_preferences_privacy.xml2
-rw-r--r--indra/newview/skins/default/xui/en/panel_preferences_sound.xml16
-rw-r--r--indra/newview/skins/default/xui/es/panel_preferences_chat.xml3
-rw-r--r--indra/newview/skins/default/xui/es/panel_preferences_sound.xml3
-rw-r--r--indra/newview/skins/default/xui/fr/panel_preferences_chat.xml3
-rw-r--r--indra/newview/skins/default/xui/fr/panel_preferences_sound.xml3
-rw-r--r--indra/newview/skins/default/xui/it/panel_preferences_chat.xml3
-rw-r--r--indra/newview/skins/default/xui/it/panel_preferences_sound.xml3
-rw-r--r--indra/newview/skins/default/xui/ja/panel_preferences_chat.xml3
-rw-r--r--indra/newview/skins/default/xui/ja/panel_preferences_sound.xml3
-rw-r--r--indra/newview/skins/default/xui/nl/panel_preferences_sound.xml3
-rw-r--r--indra/newview/skins/default/xui/pl/panel_preferences_chat.xml3
-rw-r--r--indra/newview/skins/default/xui/pl/panel_preferences_sound.xml3
-rw-r--r--indra/newview/skins/default/xui/pt/panel_preferences_chat.xml3
-rw-r--r--indra/newview/skins/default/xui/pt/panel_preferences_sound.xml3
-rw-r--r--indra/newview/viewer_manifest.py4
-rw-r--r--indra/test_apps/llplugintest/llmediaplugintest.cpp10
84 files changed, 1797 insertions, 1781 deletions
diff --git a/.hgtags b/.hgtags
index 80f6bd60fd..b982a7eea2 100644
--- a/.hgtags
+++ b/.hgtags
@@ -88,12 +88,19 @@ f1827b441e05bf37c68e2c15ebc6d09e9b03f527 2.6.0-start
c5bdef3aaa2744626aef3c217ce29e1900d357b3 2.6.1-start
c5bdef3aaa2744626aef3c217ce29e1900d357b3 DRTVWR-43_2.6.1-beta1
c5bdef3aaa2744626aef3c217ce29e1900d357b3 2.6.1-beta1
-9e4641f4a7870c0f565a25a2971368d5a29516a1 DRTVWR-41_2.6.0-beta2
-9e4641f4a7870c0f565a25a2971368d5a29516a1 2.6.0-beta2
+c9182ed77d427c759cfacf49a7b71a2e20d522aa DRTVWR-42_2.6.1-release
+c9182ed77d427c759cfacf49a7b71a2e20d522aa 2.6.1-release
56b2778c743c2a964d82e1caf11084d76a87de2c 2.6.2-start
42f32494bac475d0737799346f6831558ae8bf5d DRTVWR-39_2.6.0-release
42f32494bac475d0737799346f6831558ae8bf5d 2.6.0-release
d1203046bb653b763f835b04d184646949d8dd5c DRTVWR-45_2.6.2-beta1
d1203046bb653b763f835b04d184646949d8dd5c 2.6.2-beta1
+214180ad5714ce8392b82bbebcc92f4babd98300 DRTVWR-44_2.6.2-release
+214180ad5714ce8392b82bbebcc92f4babd98300 2.6.2-release
52b2263ab28f0976c689fd0b76c55a9eb027cdbf end-of-develop.py
ec32f1045e7c2644015245df3a9933620aa194b8 2.6.3-start
+d7fcefabdf32bb61a9ea6d6037c1bb26190a85bc DRTVWR-47_2.6.3-beta1
+d7fcefabdf32bb61a9ea6d6037c1bb26190a85bc 2.6.3-beta1
+74cd32a06837b0c2cb793b2e8d4d82f5d49462b2 2.6.4-start
+74cd32a06837b0c2cb793b2e8d4d82f5d49462b2 2.6.4-start
+f632f87bb71b0f13d21f2f64b0c42cedb008c749 2.6.4-start
diff --git a/BuildParams b/BuildParams
index f49a714c03..824c15cd12 100644
--- a/BuildParams
+++ b/BuildParams
@@ -67,6 +67,9 @@ viewer-pre-release.login_channel = "Second Life Release"
viewer-pre-release.build_debug_release_separately = true
viewer-pre-release.build_viewer_update_version_manager = true
viewer-pre-release.release-viewer.jira = DRTVWR-42
+#viewer-pre-release.release-viewer.jira = DRTVWR-13
+viewer-pre-release.release-viewer.jira = DRTVWR-46
+
# =======================================
# brad
# ========================================
@@ -155,6 +158,9 @@ media.build_viewer_update_version_manager = false
# ================
oz_viewer-devreview.build_debug_release_separately = true
+oz_project-1.build_debug_release_separately = true
+oz_project-2.build_debug_release_separately = true
+oz_project-3.build_debug_release_separately = true
# ========================================
# enus
diff --git a/autobuild.xml b/autobuild.xml
index a31d280b6f..bd98d59766 100644
--- a/autobuild.xml
+++ b/autobuild.xml
@@ -510,9 +510,9 @@
<key>archive</key>
<map>
<key>hash</key>
- <string>9b58d1a9c15807a1301e42a313641010</string>
+ <string>9f8a9dc39fd7c3da0fb3533782d1fddf</string>
<key>url</key>
- <string>http://s3.amazonaws.com/viewer-source-downloads/install_pkgs/freetype-2.4.4-linux-20110310.tar.bz2</string>
+ <string>http://automated-builds-secondlife-com.s3.amazonaws.com/hg/repo/3p-freetype/rev/226814/arch/Linux/installer/freetype-2.3.9-linux-20110418.tar.bz2</string>
</map>
<key>name</key>
<string>linux</string>
@@ -1242,9 +1242,9 @@
<key>archive</key>
<map>
<key>hash</key>
- <string>cc159598ef3fcd34fd33a8a0ef846165</string>
+ <string>3d40be8566fa4b9df9a38e2a0f9ea467</string>
<key>url</key>
- <string>http://automated-builds-secondlife-com.s3.amazonaws.com/hg/repo/3p-openssl/rev/223711/arch/Linux/installer/openssl-0.9.8q-linux-20110314.tar.bz2</string>
+ <string>http://automated-builds-secondlife-com.s3.amazonaws.com/hg/repo/3p-openssl/rev/226882/arch/Linux/installer/openssl-1.0.0d-linux-20110418.tar.bz2</string>
</map>
<key>name</key>
<string>linux</string>
@@ -1590,15 +1590,15 @@
<key>options</key>
<array>
<string>-DCMAKE_BUILD_TYPE:STRING=Debug</string>
- <string>-DUNATTENDED:BOOL=OFF</string>
<string>-DWORD_SIZE:STRING=32</string>
<string>-DROOT_PROJECT_NAME:STRING=SecondLife</string>
+ <string>-DINSTALL_PROPRIETARY=TRUE</string>
</array>
</map>
<key>name</key>
<string>Debug</string>
</map>
- <key>OpenSourceDebug</key>
+ <key>DebugOS</key>
<map>
<key>configure</key>
<map>
@@ -1607,67 +1607,23 @@
<key>options</key>
<array>
<string>-DCMAKE_BUILD_TYPE:STRING=Debug</string>
- <string>-DUNATTENDED:BOOL=OFF</string>
- <string>-DWORD_SIZE:STRING=32</string>
- <string>-DROOT_PROJECT_NAME:STRING=SecondLife</string>
- </array>
- </map>
- <key>name</key>
- <string>OpenSourceDebug</string>
- </map>
- <key>OpenSourceRelWithDebInfo</key>
- <map>
- <key>configure</key>
- <map>
- <key>command</key>
- <string>cmake</string>
- <key>options</key>
- <array>
- <string>-DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo</string>
- <string>-DUNATTENDED:BOOL=OFF</string>
<string>-DWORD_SIZE:STRING=32</string>
<string>-DROOT_PROJECT_NAME:STRING=SecondLife</string>
+ <string>-DINSTALL_PROPRIETARY=FALSE</string>
</array>
- </map>
- <key>name</key>
- <string>OpenSourceRelWithDebInfo</string>
- </map>
- <key>OpenSourceRelease</key>
- <map>
- <key>configure</key>
- <map>
- <key>command</key>
- <string>cmake</string>
- <key>options</key>
+ <key>arguments</key>
<array>
- <string>-DCMAKE_BUILD_TYPE:STRING=Release</string>
- <string>-DUNATTENDED:BOOL=OFF</string>
- <string>-DWORD_SIZE:STRING=32</string>
- <string>-DROOT_PROJECT_NAME:STRING=SecondLife</string>
+ <string>../indra</string>
</array>
</map>
<key>name</key>
- <string>OpenSourceRelease</string>
+ <string>DebugOS</string>
</map>
- <key>OpenSourceStandAloneDebug</key>
+ <key>RelWithDebInfo</key>
<map>
- <key>configure</key>
+ <key>build</key>
<map>
- <key>command</key>
- <string>cmake</string>
- <key>options</key>
- <array>
- <string>-DCMAKE_BUILD_TYPE:STRING=Debug</string>
- <string>-DUNATTENDED:BOOL=OFF</string>
- <string>-DWORD_SIZE:STRING=32</string>
- <string>-DROOT_PROJECT_NAME:STRING=SecondLife</string>
- </array>
</map>
- <key>name</key>
- <string>OpenSourceStandAloneDebug</string>
- </map>
- <key>OpenSourceStandAloneRelWithDebInfo</key>
- <map>
<key>configure</key>
<map>
<key>command</key>
@@ -1675,15 +1631,15 @@
<key>options</key>
<array>
<string>-DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo</string>
- <string>-DUNATTENDED:BOOL=OFF</string>
<string>-DWORD_SIZE:STRING=32</string>
<string>-DROOT_PROJECT_NAME:STRING=SecondLife</string>
+ <string>-DINSTALL_PROPRIETARY=TRUE</string>
</array>
</map>
<key>name</key>
- <string>OpenSourceStandAloneRelWithDebInfo</string>
+ <string>RelWithDebInfo</string>
</map>
- <key>OpenSourceStandAloneRelease</key>
+ <key>RelWithDebInfoOS</key>
<map>
<key>configure</key>
<map>
@@ -1691,34 +1647,18 @@
<string>cmake</string>
<key>options</key>
<array>
- <string>-DCMAKE_BUILD_TYPE:STRING=Release</string>
- <string>-DUNATTENDED:BOOL=OFF</string>
+ <string>-DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo</string>
<string>-DWORD_SIZE:STRING=32</string>
<string>-DROOT_PROJECT_NAME:STRING=SecondLife</string>
+ <string>-DINSTALL_PROPRIETARY=FALSE</string>
</array>
- </map>
- <key>name</key>
- <string>OpenSourceStandAloneRelease</string>
- </map>
- <key>RelWithDebInfo</key>
- <map>
- <key>build</key>
- <map>
- </map>
- <key>configure</key>
- <map>
- <key>command</key>
- <string>cmake</string>
- <key>options</key>
+ <key>arguments</key>
<array>
- <string>-DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo</string>
- <string>-DUNATTENDED:BOOL=OFF</string>
- <string>-DWORD_SIZE:STRING=32</string>
- <string>-DROOT_PROJECT_NAME:STRING=SecondLife</string>
+ <string>../indra</string>
</array>
</map>
<key>name</key>
- <string>RelWithDebInfo</string>
+ <string>RelWithDebInfoOS</string>
</map>
<key>Release</key>
<map>
@@ -1732,83 +1672,38 @@
<key>options</key>
<array>
<string>-DCMAKE_BUILD_TYPE:STRING=Release</string>
- <string>-DUNATTENDED:BOOL=OFF</string>
<string>-DWORD_SIZE:STRING=32</string>
<string>-DROOT_PROJECT_NAME:STRING=SecondLife</string>
+ <string>-DUSE_PRECOMPILED_HEADERS=ON</string>
+ <string>-DLL_RELEASE_FOR_DOWNLOAD:BOOL=TRUE</string>
+ <string>-DINSTALL_PROPRIETARY=TRUE</string>
</array>
</map>
<key>name</key>
<string>Release</string>
</map>
- <!-- OPEN-1 WORKAROUND begin - to be removed when VC express is detected correctly -->
- <key>VCexpressRelWithDebInfo</key>
- <map>
- <key>configure</key>
- <map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
- <key>command</key>
- <string>cmake</string>
- <key>options</key>
- <array>
- <string>-DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo</string>
- <string>-DUNATTENDED:BOOL=OFF</string>
- <string>-DWORD_SIZE:STRING=32</string>
- <string>-DROOT_PROJECT_NAME:STRING=SecondLife</string>
- </array>
- </map>
- <key>name</key>
- <string>VCexpressRelWithDebInfo</string>
- </map>
- <!-- OPEN-1 WORKAROUND end -->
- <!-- OPEN-1a WORKAROUND begin - to be removed when VC 2010 is detected correctly -->
- <key>VC10msbuildRelWithDebInfo</key>
+ <key>ReleaseOS</key>
<map>
<key>configure</key>
<map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
<key>command</key>
<string>cmake</string>
<key>options</key>
<array>
- <string>-DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo</string>
- <string>-DUNATTENDED:BOOL=OFF</string>
+ <string>-DCMAKE_BUILD_TYPE:STRING=Release</string>
<string>-DWORD_SIZE:STRING=32</string>
<string>-DROOT_PROJECT_NAME:STRING=SecondLife</string>
+ <string>-DINSTALL_PROPRIETARY=FALSE</string>
+ <string>-DLL_RELEASE_FOR_DOWNLOAD:BOOL=YES</string>
</array>
- </map>
- <key>name</key>
- <string>VC10msbuildRelWithDebInfo</string>
- </map>
- <!-- OPEN-1a WORKAROUND end -->
- <!-- OPEN-1a Release WORKAROUND begin - to be removed when VC 2010 is detected correctly -->
- <key>VC10msbuildRelease</key>
- <map>
- <key>configure</key>
- <map>
<key>arguments</key>
<array>
<string>../indra</string>
</array>
- <key>command</key>
- <string>cmake</string>
- <key>options</key>
- <array>
- <string>-DCMAKE_BUILD_TYPE:STRING=Release</string>
- <string>-DUNATTENDED:BOOL=OFF</string>
- <string>-DWORD_SIZE:STRING=32</string>
- <string>-DROOT_PROJECT_NAME:STRING=SecondLife</string>
- </array>
</map>
<key>name</key>
- <string>VC10msbuildRelease</string>
+ <string>ReleaseOS</string>
</map>
- <!-- OPEN-1a Release WORKAROUND end -->
</map>
<key>name</key>
<string>common</string>
@@ -1848,15 +1743,12 @@
<array>
<string>-G</string>
<string>'Xcode'</string>
- <string>-DSTANDALONE:BOOL=OFF</string>
- <string>-DINSTALL_PROPRIETARY=TRUE</string>
- <string>-DFMOD=TRUE</string>
</array>
</map>
<key>name</key>
<string>Debug</string>
</map>
- <key>OpenSourceDebug</key>
+ <key>DebugOS</key>
<map>
<key>build</key>
<map>
@@ -1870,116 +1762,26 @@
</map>
<key>configure</key>
<map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
- <key>options</key>
- <array>
- <string>-G</string>
- <string>'Xcode'</string>
- <string>-DSTANDALONE:BOOL=FALSE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
- </array>
- </map>
- <key>name</key>
- <string>OpenSourceDebug</string>
- </map>
- <key>OpenSourceRelWithDebInfo</key>
- <map>
- <key>build</key>
- <map>
- <key>command</key>
- <string>xcodebuild</string>
- <key>options</key>
- <array>
- <string>-configuration RelWithDebInfo</string>
- <string>-project SecondLife.xcodeproj</string>
- </array>
- </map>
- <key>configure</key>
- <map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
<key>options</key>
<array>
<string>-G</string>
<string>'Xcode'</string>
- <string>-DSTANDALONE:BOOL=FALSE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
</array>
</map>
<key>name</key>
- <string>OpenSourceRelWithDebInfo</string>
+ <string>DebugOS</string>
</map>
- <key>OpenSourceRelease</key>
- <map>
- <key>build</key>
- <map>
- <key>command</key>
- <string>xcodebuild</string>
- <key>options</key>
- <array>
- <string>-configuration Release</string>
- <string>-project SecondLife.xcodeproj</string>
- </array>
- </map>
- <key>configure</key>
- <map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
- <key>options</key>
- <array>
- <string>-G</string>
- <string>'Xcode'</string>
- <string>-DSTANDALONE:BOOL=FALSE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
- </array>
- </map>
- <key>name</key>
- <string>OpenSourceRelease</string>
- </map>
- <key>OpenSourceStandAloneDebug</key>
+ <key>RelWithDebInfo</key>
<map>
<key>build</key>
<map>
- <key>command</key>
- <string>xcodebuild</string>
- <key>options</key>
- <array>
- <string>-configuration Debug</string>
- <string>-project SecondLife.xcodeproj</string>
- </array>
- </map>
- <key>configure</key>
- <map>
<key>arguments</key>
<array>
- <string>../indra</string>
- </array>
- <key>options</key>
- <array>
- <string>-G</string>
- <string>'Xcode'</string>
- <string>-DSTANDALONE:BOOL=TRUE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
+ <string>|</string>
+ <string>grep</string>
+ <string>-v</string>
+ <string>setenv</string>
</array>
- </map>
- <key>name</key>
- <string>OpenSourceStandAloneDebug</string>
- </map>
- <key>OpenSourceStandAloneRelWithDebInfo</key>
- <map>
- <key>build</key>
- <map>
<key>command</key>
<string>xcodebuild</string>
<key>options</key>
@@ -1998,15 +1800,14 @@
<array>
<string>-G</string>
<string>'Xcode'</string>
- <string>-DSTANDALONE:BOOL=TRUE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
</array>
</map>
+ <key>default</key>
+ <string>True</string>
<key>name</key>
- <string>OpenSourceStandAloneRelWithDebInfo</string>
+ <string>RelWithDebInfo</string>
</map>
- <key>OpenSourceStandAloneRelease</key>
+ <key>RelWithDebInfoOS</key>
<map>
<key>build</key>
<map>
@@ -2014,29 +1815,22 @@
<string>xcodebuild</string>
<key>options</key>
<array>
- <string>-configuration Release</string>
+ <string>-configuration RelWithDebInfo</string>
<string>-project SecondLife.xcodeproj</string>
</array>
</map>
<key>configure</key>
<map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
<key>options</key>
<array>
<string>-G</string>
<string>'Xcode'</string>
- <string>-DSTANDALONE:BOOL=TRUE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
</array>
</map>
<key>name</key>
- <string>OpenSourceStandAloneRelease</string>
+ <string>RelWithDebInfoOS</string>
</map>
- <key>RelWithDebInfo</key>
+ <key>Release</key>
<map>
<key>build</key>
<map>
@@ -2051,7 +1845,7 @@
<string>xcodebuild</string>
<key>options</key>
<array>
- <string>-configuration RelWithDebInfo</string>
+ <string>-configuration Release</string>
<string>-project SecondLife.xcodeproj</string>
</array>
</map>
@@ -2065,27 +1859,15 @@
<array>
<string>-G</string>
<string>'Xcode'</string>
- <string>-DSTANDALONE:BOOL=OFF</string>
- <string>-DINSTALL_PROPRIETARY=TRUE</string>
- <string>-DFMOD=TRUE</string>
</array>
</map>
- <key>default</key>
- <string>True</string>
<key>name</key>
- <string>RelWithDebInfo</string>
+ <string>Release</string>
</map>
- <key>Release</key>
+ <key>ReleaseOS</key>
<map>
<key>build</key>
<map>
- <key>arguments</key>
- <array>
- <string>|</string>
- <string>grep</string>
- <string>-v</string>
- <string>setenv</string>
- </array>
<key>command</key>
<string>xcodebuild</string>
<key>options</key>
@@ -2096,21 +1878,14 @@
</map>
<key>configure</key>
<map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
<key>options</key>
<array>
<string>-G</string>
<string>'Xcode'</string>
- <string>-DSTANDALONE:BOOL=OFF</string>
- <string>-DINSTALL_PROPRIETARY=TRUE</string>
- <string>-DFMOD=TRUE</string>
</array>
</map>
<key>name</key>
- <string>Release</string>
+ <string>ReleaseOS</string>
</map>
</map>
<key>name</key>
@@ -2143,73 +1918,12 @@
<array>
<string>-G</string>
<string>'Unix Makefiles'</string>
- <string>-DSTANDALONE:BOOL=OFF</string>
- <string>-DINSTALL_PROPRIETARY=TRUE</string>
- <string>-DFMOD=TRUE</string>
</array>
</map>
<key>name</key>
<string>Debug</string>
</map>
- <key>OpenSourceDebug</key>
- <map>
- <key>build</key>
- <map>
- <key>command</key>
- <string>make</string>
- <key>options</key>
- <array>
- <string>-j 12</string>
- </array>
- </map>
- <key>configure</key>
- <map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
- <key>options</key>
- <array>
- <string>-G</string>
- <string>'Unix Makefiles'</string>
- <string>-DSTANDALONE:BOOL=FALSE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
- </array>
- </map>
- <key>name</key>
- <string>OpenSourceDebug</string>
- </map>
- <key>OpenSourceRelWithDebInfo</key>
- <map>
- <key>build</key>
- <map>
- <key>command</key>
- <string>make</string>
- <key>options</key>
- <array>
- <string>-j 12</string>
- </array>
- </map>
- <key>configure</key>
- <map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
- <key>options</key>
- <array>
- <string>-G</string>
- <string>'Unix Makefiles'</string>
- <string>-DSTANDALONE:BOOL=FALSE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
- </array>
- </map>
- <key>name</key>
- <string>OpenSourceRelWithDebInfo</string>
- </map>
- <key>OpenSourceRelease</key>
+ <key>DebugOS</key>
<map>
<key>build</key>
<map>
@@ -2217,57 +1931,21 @@
<string>make</string>
<key>options</key>
<array>
- <string>-j 12</string>
- </array>
- </map>
- <key>configure</key>
- <map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
- <key>options</key>
- <array>
- <string>-G</string>
- <string>'Unix Makefiles'</string>
- <string>-DSTANDALONE:BOOL=FALSE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
- </array>
- </map>
- <key>name</key>
- <string>OpenSourceRelease</string>
- </map>
- <key>OpenSourceStandAloneDebug</key>
- <map>
- <key>build</key>
- <map>
- <key>command</key>
- <string>make</string>
- <key>options</key>
- <array>
- <string>-j 12</string>
+ <string>-j 2</string>
</array>
</map>
<key>configure</key>
<map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
<key>options</key>
<array>
<string>-G</string>
<string>'Unix Makefiles'</string>
- <string>-DSTANDALONE:BOOL=TRUE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
</array>
</map>
<key>name</key>
- <string>OpenSourceStandAloneDebug</string>
+ <string>DebugOS</string>
</map>
- <key>OpenSourceStandAloneRelWithDebInfo</key>
+ <key>RelWithDebInfo</key>
<map>
<key>build</key>
<map>
@@ -2288,15 +1966,14 @@
<array>
<string>-G</string>
<string>'Unix Makefiles'</string>
- <string>-DSTANDALONE:BOOL=TRUE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
</array>
</map>
+ <key>default</key>
+ <string>True</string>
<key>name</key>
- <string>OpenSourceStandAloneRelWithDebInfo</string>
+ <string>RelWithDebInfo</string>
</map>
- <key>OpenSourceStandAloneRelease</key>
+ <key>RelWithDebInfoOS</key>
<map>
<key>build</key>
<map>
@@ -2304,28 +1981,21 @@
<string>make</string>
<key>options</key>
<array>
- <string>-j 12</string>
+ <string>-j 2</string>
</array>
</map>
<key>configure</key>
<map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
<key>options</key>
<array>
<string>-G</string>
<string>'Unix Makefiles'</string>
- <string>-DSTANDALONE:BOOL=TRUE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
</array>
</map>
<key>name</key>
- <string>OpenSourceStandAloneRelease</string>
+ <string>RelWithDebInfoOS</string>
</map>
- <key>RelWithDebInfo</key>
+ <key>Release</key>
<map>
<key>build</key>
<map>
@@ -2346,17 +2016,12 @@
<array>
<string>-G</string>
<string>'Unix Makefiles'</string>
- <string>-DSTANDALONE:BOOL=OFF</string>
- <string>-DINSTALL_PROPRIETARY=TRUE</string>
- <string>-DFMOD=TRUE</string>
</array>
</map>
- <key>default</key>
- <string>True</string>
<key>name</key>
- <string>RelWithDebInfo</string>
+ <string>Release</string>
</map>
- <key>Release</key>
+ <key>ReleaseOS</key>
<map>
<key>build</key>
<map>
@@ -2364,26 +2029,19 @@
<string>make</string>
<key>options</key>
<array>
- <string>-j 12</string>
+ <string>-j 2</string>
</array>
</map>
<key>configure</key>
<map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
<key>options</key>
<array>
<string>-G</string>
<string>'Unix Makefiles'</string>
- <string>-DSTANDALONE:BOOL=OFF</string>
- <string>-DINSTALL_PROPRIETARY=TRUE</string>
- <string>-DFMOD=TRUE</string>
</array>
</map>
<key>name</key>
- <string>Release</string>
+ <string>ReleaseOS</string>
</map>
<key>default</key>
<map>
@@ -2437,91 +2095,12 @@
<array>
<string>-G</string>
<string>"Visual Studio 10"</string>
- <string>-DSTANDALONE:BOOL=OFF</string>
- <string>-DINSTALL_PROPRIETARY=TRUE</string>
- <string>-DFMOD=TRUE</string>
</array>
</map>
<key>name</key>
<string>Debug</string>
</map>
- <key>OpenSourceDebug</key>
- <map>
- <key>build</key>
- <map>
- <key>arguments</key>
- <array>
- <string>SecondLife.sln</string>
- </array>
- <key>command</key>
- <string>devenv.com</string>
- <key>options</key>
- <array>
- <string>/build</string>
- <string>Debug</string>
- </array>
- </map>
- <key>configure</key>
- <map>
- <key>arguments</key>
- <array>
- <string>..\indra</string>
- <string>&amp;&amp;</string>
- <string>..\indra\tools\vstool\VSTool.exe</string>
- <string>--solution</string>
- <string>SecondLife.sln</string>
- <string>--config</string>
- <string>Debug</string>
- <string>--startup</string>
- <string>secondlife-bin</string>
- </array>
- <key>options</key>
- <array>
- <string>-G</string>
- <string>"Visual Studio 10"</string>
- <string>-DSTANDALONE:BOOL=FALSE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
- </array>
- </map>
- <key>name</key>
- <string>OpenSourceDebug</string>
- </map>
- <key>OpenSourceRelWithDebInfo</key>
- <map>
- <key>build</key>
- <map>
- <key>arguments</key>
- <array>
- <string>SecondLife.sln</string>
- </array>
- <key>command</key>
- <string>devenv.com</string>
- <key>options</key>
- <array>
- <string>/build</string>
- <string>RelWithDebInfo</string>
- </array>
- </map>
- <key>configure</key>
- <map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
- <key>options</key>
- <array>
- <string>-G</string>
- <string>"Visual Studio 10"</string>
- <string>-DSTANDALONE:BOOL=FALSE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
- </array>
- </map>
- <key>name</key>
- <string>OpenSourceRelWithDebInfo</string>
- </map>
- <key>OpenSourceRelease</key>
+ <key>DebugOS</key>
<map>
<key>build</key>
<map>
@@ -2530,32 +2109,35 @@
<string>SecondLife.sln</string>
</array>
<key>command</key>
- <string>devenv.com</string>
+ <string>msbuild.exe</string>
<key>options</key>
<array>
- <string>/build</string>
- <string>Release</string>
+ <string>/p:Configuration=Debug</string>
+ <string>/p:Platform=Win32</string>
+ <string>/t:Build</string>
+ <string>/p:useenv=true</string>
+ <string>/verbosity:minimal</string>
+ <string>/toolsversion:4.0</string>
+ <string>/p:"VCBuildAdditionalOptions= /incremental"</string>
</array>
</map>
<key>configure</key>
<map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
<key>options</key>
<array>
<string>-G</string>
<string>"Visual Studio 10"</string>
- <string>-DSTANDALONE:BOOL=FALSE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
+ <string>-DUNATTENDED:BOOL=ON</string>
+ <string>-DUSE_PRECOMPILED_HEADERS=ON</string>
+ <string>-DINSTALL_PROPRIETARY=TRUE</string>
+ <string>-DUSE_KDU=FALSE</string>
<string>-DFMOD=FALSE</string>
</array>
</map>
<key>name</key>
- <string>OpenSourceRelease</string>
+ <string>DebugOS</string>
</map>
- <key>OpenSourceStandAloneDebug</key>
+ <key>RelWithDebInfo</key>
<map>
<key>build</key>
<map>
@@ -2564,11 +2146,11 @@
<string>SecondLife.sln</string>
</array>
<key>command</key>
- <string>devenv.com</string>
+ <string>BuildConsole</string>
<key>options</key>
<array>
<string>/build</string>
- <string>Debug</string>
+ <string>"/cfg=RelWithDebInfo|Win32"</string>
</array>
</map>
<key>configure</key>
@@ -2589,83 +2171,14 @@
<array>
<string>-G</string>
<string>"Visual Studio 10"</string>
- <string>-DSTANDALONE:BOOL=TRUE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
- </array>
- </map>
- <key>name</key>
- <string>OpenSourceStandAloneDebug</string>
- </map>
- <key>OpenSourceStandAloneRelWithDebInfo</key>
- <map>
- <key>build</key>
- <map>
- <key>arguments</key>
- <array>
- <string>SecondLife.sln</string>
- </array>
- <key>command</key>
- <string>devenv.com</string>
- <key>options</key>
- <array>
- <string>/build</string>
- <string>RelWithDebInfo</string>
- </array>
- </map>
- <key>configure</key>
- <map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
- <key>options</key>
- <array>
- <string>-G</string>
- <string>"Visual Studio 10"</string>
- <string>-DSTANDALONE:BOOL=TRUE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
- </array>
- </map>
- <key>name</key>
- <string>OpenSourceStandAloneRelWithDebInfo</string>
- </map>
- <key>OpenSourceStandAloneRelease</key>
- <map>
- <key>build</key>
- <map>
- <key>arguments</key>
- <array>
- <string>SecondLife.sln</string>
- </array>
- <key>command</key>
- <string>devenv.com</string>
- <key>options</key>
- <array>
- <string>/build</string>
- <string>Release</string>
- </array>
- </map>
- <key>configure</key>
- <map>
- <key>arguments</key>
- <array>
- <string>../indra</string>
- </array>
- <key>options</key>
- <array>
- <string>-G</string>
- <string>"Visual Studio 10"</string>
- <string>-DSTANDALONE:BOOL=TRUE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
</array>
</map>
+ <key>default</key>
+ <string>True</string>
<key>name</key>
- <string>OpenSourceStandAloneRelease</string>
+ <string>RelWithDebInfo</string>
</map>
- <key>RelWithDebInfo</key>
+ <key>RelWithDebInfoOS</key>
<map>
<key>build</key>
<map>
@@ -2674,40 +2187,33 @@
<string>SecondLife.sln</string>
</array>
<key>command</key>
- <string>BuildConsole</string>
+ <string>msbuild.exe</string>
<key>options</key>
<array>
- <string>/build</string>
- <string>"/cfg=RelWithDebInfo|Win32"</string>
+ <string>/p:Configuration=RelWithDebInfo</string>
+ <string>/p:Platform=Win32</string>
+ <string>/t:Build</string>
+ <string>/p:useenv=true</string>
+ <string>/verbosity:minimal</string>
+ <string>/toolsversion:4.0</string>
+ <string>/p:"VCBuildAdditionalOptions= /incremental"</string>
</array>
</map>
<key>configure</key>
<map>
- <key>arguments</key>
- <array>
- <string>..\indra</string>
- <string>&amp;&amp;</string>
- <string>..\indra\tools\vstool\VSTool.exe</string>
- <string>--solution</string>
- <string>SecondLife.sln</string>
- <string>--config</string>
- <string>RelWithDebInfo</string>
- <string>--startup</string>
- <string>secondlife-bin</string>
- </array>
<key>options</key>
<array>
<string>-G</string>
<string>"Visual Studio 10"</string>
- <string>-DSTANDALONE:BOOL=OFF</string>
+ <string>-DUNATTENDED:BOOL=ON</string>
+ <string>-DUSE_PRECOMPILED_HEADERS=ON</string>
<string>-DINSTALL_PROPRIETARY=TRUE</string>
- <string>-DFMOD=TRUE</string>
+ <string>-DUSE_KDU=FALSE</string>
+ <string>-DFMOD=FALSE</string>
</array>
</map>
- <key>default</key>
- <string>True</string>
<key>name</key>
- <string>RelWithDebInfo</string>
+ <string>RelWithDebInfoOS</string>
</map>
<key>Release</key>
<map>
@@ -2744,95 +2250,31 @@
<array>
<string>-G</string>
<string>"Visual Studio 10"</string>
- <string>-DSTANDALONE:BOOL=OFF</string>
- <string>-DINSTALL_PROPRIETARY=TRUE</string>
- <string>-DFMOD=TRUE</string>
</array>
</map>
<key>name</key>
<string>Release</string>
</map>
- <!-- OPEN-1 WORKAROUND begin - to be removed when VC express is detected correctly -->
- <key>VCexpressRelWithDebInfo</key>
+ <key>ReleaseOS</key>
<map>
<key>build</key>
<map>
<key>arguments</key>
<array>
- <string>"RelWithDebInfo|Win32"</string>
- </array>
- <key>command</key>
- <string>vcbuild.exe</string>
- <key>options</key>
- <array>
- <string>/u</string>
<string>SecondLife.sln</string>
</array>
- </map>
- <key>configure</key>
- <map>
- <key>options</key>
- <array>
- <string>-G</string>
- <string>"Visual Studio 10"</string>
- <string>-DSTANDALONE:BOOL=FALSE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
- </array>
- </map>
- <key>name</key>
- <string>VCexpressRelWithDebInfo</string>
- </map>
- <!-- OPEN-1 WORKAROUND end -->
- <!-- OPEN-1a WORKAROUND begin - to be removed when VC 2010 is detected correctly -->
- <key>VC10msbuildRelWithDebInfo</key>
- <map>
- <key>build</key>
- <map>
<key>command</key>
<string>msbuild.exe</string>
<key>options</key>
<array>
- <string>SecondLife.sln</string>
- <string>/verbosity:minimal</string>
- <string>/t:build</string>
- <string>/p:Configuration=RelWithDebInfo</string>
- <string>/p:Platform=Win32</string>
- <string>/p:"VCBuildAdditionalOptions= /useenv"</string>
- <string>/p:"VCBuildAdditionalOptions= /incremental"</string>
- </array>
- </map>
- <key>configure</key>
- <map>
- <key>options</key>
- <array>
- <string>-G</string>
- <string>"Visual Studio 10"</string>
- <string>-DSTANDALONE:BOOL=FALSE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
- <string>-DFMOD=FALSE</string>
- </array>
- </map>
- <key>name</key>
- <string>VC10msbuildRelWithDebInfo</string>
- </map>
- <!-- OPEN-1a WORKAROUND end -->
- <!-- OPEN-1a Release WORKAROUND begin - to be removed when VC 2010 is detected correctly -->
- <key>VC10msbuildRelease</key>
- <map>
- <key>build</key>
- <map>
- <key>command</key>
- <string>msbuild.exe</string>
- <key>options</key>
- <array>
- <string>SecondLife.sln</string>
- <string>/t:build</string>
<string>/p:Configuration=Release</string>
<string>/p:Platform=Win32</string>
- <string>/p:"VCBuildAdditionalOptions= /useenv"</string>
+ <string>/t:Build</string>
+ <string>/p:useenv=true</string>
+ <string>/verbosity:minimal</string>
+ <string>/toolsversion:4.0</string>
<string>/p:"VCBuildAdditionalOptions= /incremental"</string>
- </array>
+ </array>
</map>
<key>configure</key>
<map>
@@ -2840,15 +2282,16 @@
<array>
<string>-G</string>
<string>"Visual Studio 10"</string>
- <string>-DSTANDALONE:BOOL=FALSE</string>
- <string>-DINSTALL_PROPRIETARY=FALSE</string>
+ <string>-DUNATTENDED:BOOL=ON</string>
+ <string>-DUSE_PRECOMPILED_HEADERS=ON</string>
+ <string>-DINSTALL_PROPRIETARY=TRUE</string>
+ <string>-DUSE_KDU=FALSE</string>
<string>-DFMOD=FALSE</string>
</array>
</map>
<key>name</key>
- <string>VC10msbuildRelease</string>
+ <string>ReleaseOS</string>
</map>
- <!-- OPEN-1a WORKAROUND end -->
</map>
<key>name</key>
<string>windows</string>
diff --git a/doc/contributions.txt b/doc/contributions.txt
index 71c54e8624..a19967fd4d 100644
--- a/doc/contributions.txt
+++ b/doc/contributions.txt
@@ -155,6 +155,8 @@ Angus Boyd
VWR-592
Ann Congrejo
CT-193
+Ansariel Hiller
+ STORM-1101
Ardy Lay
VWR-19499
VWR-24917
@@ -417,8 +419,12 @@ Jonathan Yap
STORM-1020
STORM-1064
STORM-960
+ STORM-1101
+ STORM-1108
+ STORM-1094
STORM-1077
STORM-953
+ STORM-1095
Kage Pixel
VWR-11
Ken March
@@ -440,6 +446,8 @@ Kitty Barnett
Kunnis Basiat
VWR-82
VWR-102
+Lance Corrimal
+ VWR-25269
Latif Khalifa
VWR-5370
Lisa Lowe
@@ -581,7 +589,7 @@ Nicholaz Beresford
VWR-2684
Nicky Perian
OPEN-1
- OPEN-1087
+ STORM-1087
STORM-1090
Nounouch Hapmouche
VWR-238
@@ -653,6 +661,7 @@ Robin Cornelius
STORM-422
STORM-960
STORM-1019
+ STORM-1095
VWR-2488
VWR-9557
VWR-10579
@@ -703,6 +712,7 @@ Shawn Kaufmat
SNOW-240
Siana Gearz
STORM-960
+ STORM-1088
SignpostMarv Martin
VWR-153
VWR-154
@@ -789,6 +799,7 @@ Thickbrick Sleaford
VWR-13483
VWR-13947
VWR-24420
+ STORM-1147
Thraxis Epsilon
SVC-371
VWR-383
@@ -864,6 +875,7 @@ WolfPup Lowenhar
STORM-674
STORM-776
STORM-825
+ STORM-1098
VWR-20741
VWR-20933
Zai Lynch
diff --git a/indra/cmake/Copy3rdPartyLibs.cmake b/indra/cmake/Copy3rdPartyLibs.cmake
index 4698116022..1c43c4ce12 100644
--- a/indra/cmake/Copy3rdPartyLibs.cmake
+++ b/indra/cmake/Copy3rdPartyLibs.cmake
@@ -243,7 +243,7 @@ elseif(LINUX)
libaprutil-1.so.0
libatk-1.0.so
libbreakpad_client.so.0
- libcrypto.so.0.9.8
+ libcrypto.so.1.0.0
libdb-5.1.so
libexpat.so
libexpat.so.1
@@ -259,7 +259,7 @@ elseif(LINUX)
libtcmalloc.so
libuuid.so.16
libuuid.so.16.0.22
- libssl.so.0.9.8
+ libssl.so.1.0.0
libfontconfig.so.1.4.4
)
diff --git a/indra/cmake/Variables.cmake b/indra/cmake/Variables.cmake
index b6710300bb..03428691cf 100644
--- a/indra/cmake/Variables.cmake
+++ b/indra/cmake/Variables.cmake
@@ -135,6 +135,7 @@ set(VIEWER_LOGIN_CHANNEL ${VIEWER_CHANNEL} CACHE STRING "Fake login channel for
set(VERSION_BUILD "0" CACHE STRING "Revision number passed in from the outside")
set(STANDALONE OFF CACHE BOOL "Do not use Linden-supplied prebuilt libraries.")
+set(UNATTENDED OFF CACHE BOOL "Should be set to ON for building with VC Express editions.")
if (NOT STANDALONE AND EXISTS ${CMAKE_SOURCE_DIR}/llphysics)
set(SERVER ON CACHE BOOL "Build Second Life server software.")
diff --git a/indra/llcommon/llversionviewer.h b/indra/llcommon/llversionviewer.h
index ae2bd0d78b..df5afcbf1c 100644
--- a/indra/llcommon/llversionviewer.h
+++ b/indra/llcommon/llversionviewer.h
@@ -29,7 +29,7 @@
const S32 LL_VERSION_MAJOR = 2;
const S32 LL_VERSION_MINOR = 6;
-const S32 LL_VERSION_PATCH = 4;
+const S32 LL_VERSION_PATCH = 6;
const S32 LL_VERSION_BUILD = 0;
const char * const LL_CHANNEL = "Second Life Developer";
diff --git a/indra/llimage/llimagedimensionsinfo.cpp b/indra/llimage/llimagedimensionsinfo.cpp
index 835664c60f..c6bfa50b40 100644
--- a/indra/llimage/llimagedimensionsinfo.cpp
+++ b/indra/llimage/llimagedimensionsinfo.cpp
@@ -73,9 +73,28 @@ bool LLImageDimensionsInfo::load(const std::string& src_filename,U32 codec)
bool LLImageDimensionsInfo::getImageDimensionsBmp()
{
- const S32 BMP_FILE_HEADER_SIZE = 14;
+ // Make sure the file is long enough.
+ const S32 DATA_LEN = 26; // BMP header (14) + DIB header size (4) + width (4) + height (4)
+ if (!checkFileLength(DATA_LEN))
+ {
+ llwarns << "Premature end of file" << llendl;
+ return false;
+ }
+
+ // Read BMP signature.
+ U8 signature[2];
+ mInfile.read((void*)signature, sizeof(signature)/sizeof(signature[0]));
+
+ // Make sure this is actually a BMP file.
+ // We only support Windows bitmaps (BM), according to LLImageBMP::updateData().
+ if (signature[0] != 'B' || signature[1] != 'M')
+ {
+ llwarns << "Not a BMP" << llendl;
+ return false;
+ }
- mInfile.seek(APR_CUR,BMP_FILE_HEADER_SIZE+4);
+ // Read image dimensions.
+ mInfile.seek(APR_CUR, 16);
mWidth = read_reverse_s32();
mHeight = read_reverse_s32();
@@ -86,6 +105,14 @@ bool LLImageDimensionsInfo::getImageDimensionsTga()
{
const S32 TGA_FILE_HEADER_SIZE = 12;
+ // Make sure the file is long enough.
+ if (!checkFileLength(TGA_FILE_HEADER_SIZE + 1 /* width */ + 1 /* height */))
+ {
+ llwarns << "Premature end of file" << llendl;
+ return false;
+ }
+
+ // *TODO: Detect non-TGA files somehow.
mInfile.seek(APR_CUR,TGA_FILE_HEADER_SIZE);
mWidth = read_byte() | read_byte() << 8;
mHeight = read_byte() | read_byte() << 8;
@@ -95,9 +122,29 @@ bool LLImageDimensionsInfo::getImageDimensionsTga()
bool LLImageDimensionsInfo::getImageDimensionsPng()
{
- const S32 PNG_FILE_MARKER_SIZE = 8;
+ const S32 PNG_MAGIC_SIZE = 8;
+
+ // Make sure the file is long enough.
+ if (!checkFileLength(PNG_MAGIC_SIZE + 8 + sizeof(S32) * 2 /* width, height */))
+ {
+ llwarns << "Premature end of file" << llendl;
+ return false;
+ }
- mInfile.seek(APR_CUR,PNG_FILE_MARKER_SIZE + 8/*header offset+chunk length+chunk type*/);
+ // Read PNG signature.
+ const U8 png_magic[PNG_MAGIC_SIZE] = {0x89, 0x50, 0x4E, 0x47, 0x0D, 0x0A, 0x1A, 0x0A};
+ U8 signature[PNG_MAGIC_SIZE];
+ mInfile.read((void*)signature, PNG_MAGIC_SIZE);
+
+ // Make sure it's a PNG file.
+ if (memcmp(signature, png_magic, PNG_MAGIC_SIZE) != 0)
+ {
+ llwarns << "Not a PNG" << llendl;
+ return false;
+ }
+
+ // Read image dimensions.
+ mInfile.seek(APR_CUR, 8 /* chunk length + chunk type */);
mWidth = read_s32();
mHeight = read_s32();
@@ -122,6 +169,24 @@ bool LLImageDimensionsInfo::getImageDimensionsJpeg()
setLastError("Unable to open file for reading", mSrcFilename);
return false;
}
+
+ /* Make sure this is a JPEG file. */
+ const size_t JPEG_MAGIC_SIZE = 2;
+ const uint8_t jpeg_magic[JPEG_MAGIC_SIZE] = {0xFF, 0xD8};
+ uint8_t signature[JPEG_MAGIC_SIZE];
+
+ if (fread(signature, sizeof(signature), 1, fp) != 1)
+ {
+ llwarns << "Premature end of file" << llendl;
+ return false;
+ }
+ if (memcmp(signature, jpeg_magic, JPEG_MAGIC_SIZE) != 0)
+ {
+ llwarns << "Not a JPEG" << llendl;
+ return false;
+ }
+ fseek(fp, 0, SEEK_SET); // go back to start of the file
+
/* Init jpeg */
jpeg_error_mgr jerr;
jpeg_decompress_struct cinfo;
@@ -145,3 +210,13 @@ bool LLImageDimensionsInfo::getImageDimensionsJpeg()
return !sJpegErrorEncountered;
}
+bool LLImageDimensionsInfo::checkFileLength(S32 min_len)
+{
+ // Make sure the file is not shorter than min_len bytes.
+ // so that we don't have to check value returned by each read() or seek().
+ char* buf = new char[min_len];
+ int nread = mInfile.read(buf, min_len);
+ delete[] buf;
+ mInfile.seek(APR_SET, 0);
+ return nread == min_len;
+}
diff --git a/indra/llimage/llimagedimensionsinfo.h b/indra/llimage/llimagedimensionsinfo.h
index 5384faf3f4..382fdb2a0e 100644
--- a/indra/llimage/llimagedimensionsinfo.h
+++ b/indra/llimage/llimagedimensionsinfo.h
@@ -119,6 +119,9 @@ protected:
return read_byte() << 8 | read_byte();
}
+ /// Check if the file is not shorter than min_len bytes.
+ bool checkFileLength(S32 min_len);
+
protected:
LLAPRFile mInfile ;
std::string mSrcFilename;
diff --git a/indra/llui/lllineeditor.cpp b/indra/llui/lllineeditor.cpp
index 7e348656a9..d99ee5a545 100644
--- a/indra/llui/lllineeditor.cpp
+++ b/indra/llui/lllineeditor.cpp
@@ -2290,3 +2290,8 @@ void LLLineEditor::setContextMenu(LLContextMenu* new_context_menu)
else
mContextMenuHandle.markDead();
}
+
+void LLLineEditor::setFont(const LLFontGL* font)
+{
+ mGLFont = font;
+}
diff --git a/indra/llui/lllineeditor.h b/indra/llui/lllineeditor.h
index 723423a5b9..7b5fa218f2 100644
--- a/indra/llui/lllineeditor.h
+++ b/indra/llui/lllineeditor.h
@@ -201,6 +201,7 @@ public:
const LLColor4& getTentativeFgColor() const { return mTentativeFgColor.get(); }
const LLFontGL* getFont() const { return mGLFont; }
+ void setFont(const LLFontGL* font);
void setIgnoreArrowKeys(BOOL b) { mIgnoreArrowKeys = b; }
void setIgnoreTab(BOOL b) { mIgnoreTab = b; }
diff --git a/indra/llui/lltextbase.cpp b/indra/llui/lltextbase.cpp
index 49537ef78f..82269282ef 100644
--- a/indra/llui/lltextbase.cpp
+++ b/indra/llui/lltextbase.cpp
@@ -157,6 +157,7 @@ LLTextBase::Params::Params()
read_only("read_only", false),
v_pad("v_pad", 0),
h_pad("h_pad", 0),
+ clip("clip", true),
clip_partial("clip_partial", true),
line_spacing("line_spacing"),
max_text_length("max_length", 255),
@@ -199,6 +200,7 @@ LLTextBase::LLTextBase(const LLTextBase::Params &p)
mVAlign(p.font_valign),
mLineSpacingMult(p.line_spacing.multiple),
mLineSpacingPixels(p.line_spacing.pixels),
+ mClip(p.clip),
mClipPartial(p.clip_partial && !p.allow_scroll),
mTrackEnd( p.track_end ),
mScrollIndex(-1),
@@ -334,7 +336,7 @@ void LLTextBase::drawSelectionBackground()
// binary search for line that starts before top of visible buffer
line_list_t::const_iterator line_iter = std::lower_bound(mLineInfoList.begin(), mLineInfoList.end(), content_display_rect.mTop, compare_bottom());
- line_list_t::const_iterator end_iter = std::lower_bound(mLineInfoList.begin(), mLineInfoList.end(), content_display_rect.mBottom, compare_top());
+ line_list_t::const_iterator end_iter = std::upper_bound(mLineInfoList.begin(), mLineInfoList.end(), content_display_rect.mBottom, compare_top());
bool done = false;
@@ -512,7 +514,6 @@ void LLTextBase::drawText()
selection_right = llmax( mSelectionStart, mSelectionEnd );
}
- LLRect scrolled_view_rect = getVisibleDocumentRect();
std::pair<S32, S32> line_range = getVisibleLines(mClipPartial);
S32 first_line = line_range.first;
S32 last_line = line_range.second;
@@ -545,10 +546,10 @@ void LLTextBase::drawText()
line_end = next_start;
}
- LLRect text_rect(line.mRect.mLeft + mVisibleTextRect.mLeft - scrolled_view_rect.mLeft,
- line.mRect.mTop - scrolled_view_rect.mBottom + mVisibleTextRect.mBottom,
- llmin(mDocumentView->getRect().getWidth(), line.mRect.mRight) - scrolled_view_rect.mLeft,
- line.mRect.mBottom - scrolled_view_rect.mBottom + mVisibleTextRect.mBottom);
+ LLRect text_rect(line.mRect);
+ text_rect.mRight = llmin(mDocumentView->getRect().getWidth(), text_rect.mRight); // clamp right edge to document extents
+ text_rect.translate(mVisibleTextRect.mLeft, mVisibleTextRect.mBottom); // translate into display region of text widget
+ text_rect.translate(mDocumentView->getRect().mLeft, mDocumentView->getRect().mBottom); // adjust by scroll position
// draw a single line of text
S32 seg_start = line_start;
@@ -993,14 +994,28 @@ void LLTextBase::draw()
updateScrollFromCursor();
}
- LLRect doc_rect;
+ LLRect text_rect;
if (mScroller)
{
- mScroller->localRectToOtherView(mScroller->getContentWindowRect(), &doc_rect, this);
+ mScroller->localRectToOtherView(mScroller->getContentWindowRect(), &text_rect, this);
}
else
{
- doc_rect = getLocalRect();
+ LLRect visible_lines_rect;
+ std::pair<S32, S32> line_range = getVisibleLines(mClipPartial);
+ for (S32 i = line_range.first; i < line_range.second; i++)
+ {
+ if (visible_lines_rect.isEmpty())
+ {
+ visible_lines_rect = mLineInfoList[i].mRect;
+ }
+ else
+ {
+ visible_lines_rect.unionWith(mLineInfoList[i].mRect);
+ }
+ }
+ text_rect = visible_lines_rect;
+ text_rect.translate(mDocumentView->getRect().mLeft, mDocumentView->getRect().mBottom);
}
if (mBGVisible)
@@ -1010,28 +1025,37 @@ void LLTextBase::draw()
LLRect bg_rect = mVisibleTextRect;
if (mScroller)
{
- bg_rect.intersectWith(doc_rect);
+ bg_rect.intersectWith(text_rect);
}
LLColor4 bg_color = mReadOnly
? mReadOnlyBgColor.get()
: hasFocus()
? mFocusBgColor.get()
: mWriteableBgColor.get();
- gl_rect_2d(doc_rect, bg_color % alpha, TRUE);
+ gl_rect_2d(text_rect, bg_color % alpha, TRUE);
}
- // draw document view
- LLUICtrl::draw();
-
- {
- // only clip if we support scrolling...
- // since convention is that text boxes never vertically truncate their contents
- // regardless of rect bounds
- LLLocalClipRect clip(doc_rect, mScroller != NULL);
+ bool should_clip = mClip || mScroller != NULL;
+ { LLLocalClipRect clip(text_rect, should_clip);
+
+ // draw document view
+ if (mScroller)
+ {
+ drawChild(mScroller);
+ }
+ else
+ {
+ drawChild(mDocumentView);
+ }
+
drawSelectionBackground();
drawText();
drawCursor();
}
+
+ mDocumentView->setVisible(FALSE);
+ LLUICtrl::draw();
+ mDocumentView->setVisible(TRUE);
}
@@ -1415,7 +1439,7 @@ S32 LLTextBase::getFirstVisibleLine() const
return iter - mLineInfoList.begin();
}
-std::pair<S32, S32> LLTextBase::getVisibleLines(bool fully_visible)
+std::pair<S32, S32> LLTextBase::getVisibleLines(bool require_fully_visible)
{
LLRect visible_region = getVisibleDocumentRect();
line_list_t::const_iterator first_iter;
@@ -1424,14 +1448,14 @@ std::pair<S32, S32> LLTextBase::getVisibleLines(bool fully_visible)
// make sure we have an up-to-date mLineInfoList
reflow();
- if (fully_visible)
+ if (require_fully_visible)
{
first_iter = std::lower_bound(mLineInfoList.begin(), mLineInfoList.end(), visible_region.mTop, compare_top());
- last_iter = std::lower_bound(mLineInfoList.begin(), mLineInfoList.end(), visible_region.mBottom, compare_bottom());
+ last_iter = std::upper_bound(mLineInfoList.begin(), mLineInfoList.end(), visible_region.mBottom, compare_bottom());
}
else
{
- first_iter = std::lower_bound(mLineInfoList.begin(), mLineInfoList.end(), visible_region.mTop, compare_bottom());
+ first_iter = std::upper_bound(mLineInfoList.begin(), mLineInfoList.end(), visible_region.mTop, compare_bottom());
last_iter = std::lower_bound(mLineInfoList.begin(), mLineInfoList.end(), visible_region.mBottom, compare_top());
}
return std::pair<S32, S32>(first_iter - mLineInfoList.begin(), last_iter - mLineInfoList.begin());
@@ -2405,14 +2429,41 @@ LLRect LLTextBase::getVisibleDocumentRect() const
{
return mScroller->getVisibleContentRect();
}
- else
+ else if (mClip)
{
- // entire document rect is visible when not scrolling
+ LLRect visible_text_rect = getVisibleTextRect();
+ LLRect doc_rect = mDocumentView->getRect();
+ visible_text_rect.translate(-doc_rect.mLeft, -doc_rect.mBottom);
+
+ // reject partially visible lines
+ LLRect visible_lines_rect;
+ for (line_list_t::const_iterator it = mLineInfoList.begin(), end_it = mLineInfoList.end();
+ it != end_it;
+ ++it)
+ {
+ bool line_visible = mClipPartial ? visible_text_rect.contains(it->mRect) : visible_text_rect.overlaps(it->mRect);
+ if (line_visible)
+ {
+ if (visible_lines_rect.isEmpty())
+ {
+ visible_lines_rect = it->mRect;
+ }
+ else
+ {
+ visible_lines_rect.unionWith(it->mRect);
+ }
+ }
+ }
+ return visible_lines_rect;
+ }
+ else
+ { // entire document rect is visible
// but offset according to height of widget
+
LLRect doc_rect = mDocumentView->getLocalRect();
doc_rect.mLeft -= mDocumentView->getRect().mLeft;
// adjust for height of text above widget baseline
- doc_rect.mBottom = doc_rect.getHeight() - mVisibleTextRect.getHeight();
+ doc_rect.mBottom = llmin(0, doc_rect.getHeight() - mVisibleTextRect.getHeight());
return doc_rect;
}
}
diff --git a/indra/llui/lltextbase.h b/indra/llui/lltextbase.h
index aafcf8ceb0..7d545a1ba6 100644
--- a/indra/llui/lltextbase.h
+++ b/indra/llui/lltextbase.h
@@ -265,6 +265,7 @@ public:
use_ellipses,
parse_urls,
parse_highlights,
+ clip,
clip_partial;
Optional<S32> v_pad,
@@ -338,7 +339,7 @@ public:
void addDocumentChild(LLView* view);
void removeDocumentChild(LLView* view);
const LLView* getDocumentView() const { return mDocumentView; }
- LLRect getVisibleTextRect() { return mVisibleTextRect; }
+ LLRect getVisibleTextRect() const { return mVisibleTextRect; }
LLRect getTextBoundingRect();
LLRect getVisibleDocumentRect() const;
@@ -552,6 +553,7 @@ protected:
bool mTrackEnd; // if true, keeps scroll position at end of document during resize
bool mReadOnly;
bool mBGVisible; // render background?
+ bool mClip; // clip text to widget rect
bool mClipPartial; // false if we show lines that are partially inside bounding rect
bool mPlainText; // didn't use Image or Icon segments
S32 mMaxTextByteLength; // Maximum length mText is allowed to be in bytes
diff --git a/indra/llwindow/llwindowwin32.cpp b/indra/llwindow/llwindowwin32.cpp
index ab089081e6..551d487cc8 100644
--- a/indra/llwindow/llwindowwin32.cpp
+++ b/indra/llwindow/llwindowwin32.cpp
@@ -500,6 +500,8 @@ LLWindowWin32::LLWindowWin32(LLWindowCallbacks* callbacks,
//-----------------------------------------------------------------------
DEVMODE dev_mode;
+ ::ZeroMemory(&dev_mode, sizeof(DEVMODE));
+ dev_mode.dmSize = sizeof(DEVMODE);
DWORD current_refresh;
if (EnumDisplaySettings(NULL, ENUM_CURRENT_SETTINGS, &dev_mode))
{
@@ -878,6 +880,8 @@ BOOL LLWindowWin32::switchContext(BOOL fullscreen, const LLCoordScreen &size, BO
{
GLuint pixel_format;
DEVMODE dev_mode;
+ ::ZeroMemory(&dev_mode, sizeof(DEVMODE));
+ dev_mode.dmSize = sizeof(DEVMODE);
DWORD current_refresh;
DWORD dw_ex_style;
DWORD dw_style;
@@ -2711,6 +2715,8 @@ LLWindow::LLWindowResolution* LLWindowWin32::getSupportedResolutions(S32 &num_re
{
mSupportedResolutions = new LLWindowResolution[MAX_NUM_RESOLUTIONS];
DEVMODE dev_mode;
+ ::ZeroMemory(&dev_mode, sizeof(DEVMODE));
+ dev_mode.dmSize = sizeof(DEVMODE);
mNumSupportedResolutions = 0;
for (S32 mode_num = 0; mNumSupportedResolutions < MAX_NUM_RESOLUTIONS; mode_num++)
@@ -2786,7 +2792,8 @@ F32 LLWindowWin32::getPixelAspectRatio()
BOOL LLWindowWin32::setDisplayResolution(S32 width, S32 height, S32 bits, S32 refresh)
{
DEVMODE dev_mode;
- dev_mode.dmSize = sizeof(dev_mode);
+ ::ZeroMemory(&dev_mode, sizeof(DEVMODE));
+ dev_mode.dmSize = sizeof(DEVMODE);
BOOL success = FALSE;
// Don't change anything if we don't have to
diff --git a/indra/media_plugins/winmmshim/forwarding_api.cpp b/indra/media_plugins/winmmshim/forwarding_api.cpp
index eff7e20451..495e08942b 100644
--- a/indra/media_plugins/winmmshim/forwarding_api.cpp
+++ b/indra/media_plugins/winmmshim/forwarding_api.cpp
@@ -389,90 +389,105 @@ void init_function_pointers(HMODULE winmm_handle)
extern "C" {
LRESULT WINAPI CloseDriver( HDRVR hDriver, LPARAM lParam1, LPARAM lParam2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"CloseDriver\n");
return CloseDriver_orig( hDriver, lParam1, lParam2);
}
HDRVR WINAPI OpenDriver( LPCWSTR szDriverName, LPCWSTR szSectionName, LPARAM lParam2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"OpenDriver\n");
return OpenDriver_orig( szDriverName, szSectionName, lParam2);
}
LRESULT WINAPI SendDriverMessage( HDRVR hDriver, UINT message, LPARAM lParam1, LPARAM lParam2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"SendDriverMessage\n");
return SendDriverMessage_orig( hDriver, message, lParam1, lParam2);
}
HMODULE WINAPI DrvGetModuleHandle( HDRVR hDriver)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"DrvGetModuleHandle\n");
return DrvGetModuleHandle_orig( hDriver);
}
HMODULE WINAPI GetDriverModuleHandle( HDRVR hDriver)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"GetDriverModuleHandle\n");
return GetDriverModuleHandle_orig( hDriver);
}
LRESULT WINAPI DefDriverProc( DWORD_PTR dwDriverIdentifier, HDRVR hdrvr, UINT uMsg, LPARAM lParam1, LPARAM lParam2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"DefDriverProc\n");
return DefDriverProc_orig( dwDriverIdentifier, hdrvr, uMsg, lParam1, lParam2);
}
BOOL WINAPI DriverCallback( DWORD dwCallBack, DWORD dwFlags, HDRVR hdrvr, DWORD msg, DWORD dwUser, DWORD dwParam1, DWORD dwParam2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"DriverCallback\n");
return DriverCallback_orig(dwCallBack, dwFlags, hdrvr, msg, dwUser, dwParam1, dwParam2);
}
UINT WINAPI mmsystemGetVersion(void)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmsystemGetVersion\n");
return mmsystemGetVersion_orig();
}
BOOL WINAPI sndPlaySoundA( LPCSTR pszSound, UINT fuSound)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"sndPlaySoundA\n");
return sndPlaySoundA_orig( pszSound, fuSound);
}
BOOL WINAPI sndPlaySoundW( LPCWSTR pszSound, UINT fuSound)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"sndPlaySoundW\n");
return sndPlaySoundW_orig( pszSound, fuSound);
}
BOOL WINAPI PlaySoundA( LPCSTR pszSound, HMODULE hmod, DWORD fdwSound)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"PlaySoundA\n");
return PlaySoundA_orig( pszSound, hmod, fdwSound);
}
BOOL WINAPI PlaySoundW( LPCWSTR pszSound, HMODULE hmod, DWORD fdwSound)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"PlaySoundW\n");
return PlaySoundW_orig( pszSound, hmod, fdwSound);
}
UINT WINAPI waveOutGetNumDevs(void)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutGetNumDevs\n");
return waveOutGetNumDevs_orig();
}
MMRESULT WINAPI waveOutGetDevCapsA( UINT_PTR uDeviceID, LPWAVEOUTCAPSA pwoc, UINT cbwoc)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutGetDevCapsA\n");
return waveOutGetDevCapsA_orig( uDeviceID, pwoc, cbwoc);
}
MMRESULT WINAPI waveOutGetDevCapsW( UINT_PTR uDeviceID, LPWAVEOUTCAPSW pwoc, UINT cbwoc)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutGetDevCapsW\n");
return waveOutGetDevCapsW_orig( uDeviceID, pwoc, cbwoc);
}
@@ -480,24 +495,28 @@ extern "C" {
MMRESULT WINAPI waveOutGetVolume( HWAVEOUT hwo, LPDWORD pdwVolume)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutGetVolume\n");
return waveOutGetVolume_orig( hwo, pdwVolume);
}
MMRESULT WINAPI waveOutSetVolume( HWAVEOUT hwo, DWORD dwVolume)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutSetVolume\n");
return waveOutSetVolume_orig( hwo, dwVolume);
}
MMRESULT WINAPI waveOutGetErrorTextA( MMRESULT mmrError, LPSTR pszText, UINT cchText)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutGetErrorTextA\n");
return waveOutGetErrorTextA_orig( mmrError, pszText, cchText);
}
MMRESULT WINAPI waveOutGetErrorTextW( MMRESULT mmrError, LPWSTR pszText, UINT cchText)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutGetErrorTextW\n");
return waveOutGetErrorTextW_orig( mmrError, pszText, cchText);
}
@@ -516,12 +535,14 @@ extern "C" {
MMRESULT WINAPI waveOutPrepareHeader( HWAVEOUT hwo, LPWAVEHDR pwh, UINT cbwh)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutPrepareHeader\n");
return waveOutPrepareHeader_orig( hwo, pwh, cbwh);
}
MMRESULT WINAPI waveOutUnprepareHeader( HWAVEOUT hwo, LPWAVEHDR pwh, UINT cbwh)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutUnprepareHeader\n");
return waveOutUnprepareHeader_orig( hwo, pwh, cbwh);
}
@@ -535,834 +556,973 @@ extern "C" {
MMRESULT WINAPI waveOutPause( HWAVEOUT hwo)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutPause\n");
return waveOutPause_orig( hwo);
}
MMRESULT WINAPI waveOutRestart( HWAVEOUT hwo)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutRestart\n");
return waveOutRestart_orig( hwo);
}
MMRESULT WINAPI waveOutReset( HWAVEOUT hwo)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutReset\n");
return waveOutReset_orig( hwo);
}
MMRESULT WINAPI waveOutBreakLoop( HWAVEOUT hwo)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutBreakLoop\n");
return waveOutBreakLoop_orig( hwo);
}
MMRESULT WINAPI waveOutGetPosition( HWAVEOUT hwo, LPMMTIME pmmt, UINT cbmmt)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutGetPosition\n");
return waveOutGetPosition_orig( hwo, pmmt, cbmmt);
}
MMRESULT WINAPI waveOutGetPitch( HWAVEOUT hwo, LPDWORD pdwPitch)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutGetPitch\n");
return waveOutGetPitch_orig( hwo, pdwPitch);
}
MMRESULT WINAPI waveOutSetPitch( HWAVEOUT hwo, DWORD dwPitch)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutSetPitch\n");
return waveOutSetPitch_orig( hwo, dwPitch);
}
MMRESULT WINAPI waveOutGetPlaybackRate( HWAVEOUT hwo, LPDWORD pdwRate)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutGetPlaybackRate\n");
return waveOutGetPlaybackRate_orig( hwo, pdwRate);
}
MMRESULT WINAPI waveOutSetPlaybackRate( HWAVEOUT hwo, DWORD dwRate)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutSetPlaybackRate\n");
return waveOutSetPlaybackRate_orig( hwo, dwRate);
}
MMRESULT WINAPI waveOutGetID( HWAVEOUT hwo, LPUINT puDeviceID)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutGetID\n");
return waveOutGetID_orig( hwo, puDeviceID);
}
MMRESULT WINAPI waveOutMessage( HWAVEOUT hwo, UINT uMsg, DWORD_PTR dw1, DWORD_PTR dw2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveOutMessage\n");
return waveOutMessage_orig( hwo, uMsg, dw1, dw2);
}
UINT WINAPI waveInGetNumDevs(void)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInGetNumDevs\n");
return waveInGetNumDevs_orig();
}
MMRESULT WINAPI waveInGetDevCapsA( UINT_PTR uDeviceID, LPWAVEINCAPSA pwic, UINT cbwic)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInGetDevCapsA\n");
return waveInGetDevCapsA_orig( uDeviceID, pwic, cbwic);
}
MMRESULT WINAPI waveInGetDevCapsW( UINT_PTR uDeviceID, LPWAVEINCAPSW pwic, UINT cbwic)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInGetDevCapsW\n");
return waveInGetDevCapsW_orig( uDeviceID, pwic, cbwic);
}
MMRESULT WINAPI waveInGetErrorTextA(MMRESULT mmrError, LPSTR pszText, UINT cchText)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInGetErrorTextA\n");
return waveInGetErrorTextA_orig(mmrError, pszText, cchText);
}
MMRESULT WINAPI waveInGetErrorTextW(MMRESULT mmrError, LPWSTR pszText, UINT cchText)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInGetErrorTextW\n");
return waveInGetErrorTextW_orig(mmrError, pszText, cchText);
}
MMRESULT WINAPI waveInOpen( LPHWAVEIN phwi, UINT uDeviceID, LPCWAVEFORMATEX pwfx, DWORD_PTR dwCallback, DWORD_PTR dwInstance, DWORD fdwOpen)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInOpen\n");
return waveInOpen_orig(phwi, uDeviceID, pwfx, dwCallback, dwInstance, fdwOpen);
}
MMRESULT WINAPI waveInClose( HWAVEIN hwi)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInClose\n");
return waveInClose_orig( hwi);
}
MMRESULT WINAPI waveInPrepareHeader( HWAVEIN hwi, LPWAVEHDR pwh, UINT cbwh)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInPrepareHeader\n");
return waveInPrepareHeader_orig( hwi, pwh, cbwh);
}
MMRESULT WINAPI waveInUnprepareHeader( HWAVEIN hwi, LPWAVEHDR pwh, UINT cbwh)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInUnprepareHeader\n");
return waveInUnprepareHeader_orig( hwi, pwh, cbwh);
}
MMRESULT WINAPI waveInAddBuffer( HWAVEIN hwi, LPWAVEHDR pwh, UINT cbwh)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInAddBuffer\n");
return waveInAddBuffer_orig( hwi, pwh, cbwh);
}
MMRESULT WINAPI waveInStart( HWAVEIN hwi)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInStart\n");
return waveInStart_orig( hwi);
}
MMRESULT WINAPI waveInStop( HWAVEIN hwi)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInStop\n");
return waveInStop_orig(hwi);
}
MMRESULT WINAPI waveInReset( HWAVEIN hwi)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInReset\n");
return waveInReset_orig(hwi);
}
MMRESULT WINAPI waveInGetPosition( HWAVEIN hwi, LPMMTIME pmmt, UINT cbmmt)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInGetPosition\n");
return waveInGetPosition_orig( hwi, pmmt, cbmmt);
}
MMRESULT WINAPI waveInGetID( HWAVEIN hwi, LPUINT puDeviceID)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInGetID\n");
return waveInGetID_orig( hwi, puDeviceID);
}
MMRESULT WINAPI waveInMessage( HWAVEIN hwi, UINT uMsg, DWORD_PTR dw1, DWORD_PTR dw2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"waveInMessage\n");
return waveInMessage_orig( hwi, uMsg, dw1, dw2);
}
UINT WINAPI midiOutGetNumDevs(void)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutGetNumDevs\n");
return midiOutGetNumDevs_orig();
}
MMRESULT WINAPI midiStreamOpen( LPHMIDISTRM phms, LPUINT puDeviceID, DWORD cMidi, DWORD_PTR dwCallback, DWORD_PTR dwInstance, DWORD fdwOpen)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiStreamOpen\n");
return midiStreamOpen_orig( phms, puDeviceID, cMidi, dwCallback, dwInstance, fdwOpen);
}
MMRESULT WINAPI midiStreamClose( HMIDISTRM hms)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiStreamClose\n");
return midiStreamClose_orig( hms);
}
MMRESULT WINAPI midiStreamProperty( HMIDISTRM hms, LPBYTE lppropdata, DWORD dwProperty)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiStreamProperty\n");
return midiStreamProperty_orig( hms, lppropdata, dwProperty);
}
MMRESULT WINAPI midiStreamPosition( HMIDISTRM hms, LPMMTIME lpmmt, UINT cbmmt)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiStreamPosition\n");
return midiStreamPosition_orig( hms, lpmmt, cbmmt);
}
MMRESULT WINAPI midiStreamOut( HMIDISTRM hms, LPMIDIHDR pmh, UINT cbmh)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiStreamOut\n");
return midiStreamOut_orig( hms, pmh, cbmh);
}
MMRESULT WINAPI midiStreamPause( HMIDISTRM hms)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiStreamPause\n");
return midiStreamPause_orig( hms);
}
MMRESULT WINAPI midiStreamRestart( HMIDISTRM hms)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiStreamRestart\n");
return midiStreamRestart_orig( hms);
}
MMRESULT WINAPI midiStreamStop( HMIDISTRM hms)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiStreamStop\n");
return midiStreamStop_orig( hms);
}
MMRESULT WINAPI midiConnect( HMIDI hmi, HMIDIOUT hmo, LPVOID pReserved)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiConnect\n");
return midiConnect_orig( hmi, hmo, pReserved);
}
MMRESULT WINAPI midiDisconnect( HMIDI hmi, HMIDIOUT hmo, LPVOID pReserved)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiDisconnect\n");
return midiDisconnect_orig( hmi, hmo, pReserved);
}
MMRESULT WINAPI midiOutGetDevCapsA( UINT_PTR uDeviceID, LPMIDIOUTCAPSA pmoc, UINT cbmoc)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutGetDevCapsA\n");
return midiOutGetDevCapsA_orig( uDeviceID, pmoc, cbmoc);
}
MMRESULT WINAPI midiOutGetDevCapsW( UINT_PTR uDeviceID, LPMIDIOUTCAPSW pmoc, UINT cbmoc)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutGetDevCapsW\n");
return midiOutGetDevCapsW_orig( uDeviceID, pmoc, cbmoc);
}
MMRESULT WINAPI midiOutGetVolume( HMIDIOUT hmo, LPDWORD pdwVolume)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutGetVolume\n");
return midiOutGetVolume_orig( hmo, pdwVolume);
}
MMRESULT WINAPI midiOutSetVolume( HMIDIOUT hmo, DWORD dwVolume)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutSetVolume\n");
return midiOutSetVolume_orig( hmo, dwVolume);
}
MMRESULT WINAPI midiOutGetErrorTextA( MMRESULT mmrError, LPSTR pszText, UINT cchText)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutGetErrorTextA\n");
return midiOutGetErrorTextA_orig( mmrError, pszText, cchText);
}
MMRESULT WINAPI midiOutGetErrorTextW( MMRESULT mmrError, LPWSTR pszText, UINT cchText)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutGetErrorTextW\n");
return midiOutGetErrorTextW_orig( mmrError, pszText, cchText);
}
MMRESULT WINAPI midiOutOpen( LPHMIDIOUT phmo, UINT uDeviceID, DWORD_PTR dwCallback, DWORD_PTR dwInstance, DWORD fdwOpen)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutOpen\n");
return midiOutOpen_orig(phmo, uDeviceID, dwCallback, dwInstance, fdwOpen);
}
MMRESULT WINAPI midiOutClose( HMIDIOUT hmo)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutClose\n");
return midiOutClose_orig( hmo);
}
MMRESULT WINAPI midiOutPrepareHeader( HMIDIOUT hmo, LPMIDIHDR pmh, UINT cbmh)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutPrepareHeader\n");
return midiOutPrepareHeader_orig( hmo, pmh, cbmh);
}
MMRESULT WINAPI midiOutUnprepareHeader(HMIDIOUT hmo, LPMIDIHDR pmh, UINT cbmh)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutUnprepareHeader\n");
return midiOutUnprepareHeader_orig(hmo, pmh, cbmh);
}
MMRESULT WINAPI midiOutShortMsg( HMIDIOUT hmo, DWORD dwMsg)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutShortMsg\n");
return midiOutShortMsg_orig( hmo, dwMsg);
}
MMRESULT WINAPI midiOutLongMsg(HMIDIOUT hmo, LPMIDIHDR pmh, UINT cbmh)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutLongMsg\n");
return midiOutLongMsg_orig(hmo, pmh, cbmh);
}
MMRESULT WINAPI midiOutReset( HMIDIOUT hmo)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutReset\n");
return midiOutReset_orig( hmo);
}
MMRESULT WINAPI midiOutCachePatches( HMIDIOUT hmo, UINT uBank, LPWORD pwpa, UINT fuCache)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutCachePatches\n");
return midiOutCachePatches_orig( hmo, uBank, pwpa, fuCache);
}
MMRESULT WINAPI midiOutCacheDrumPatches( HMIDIOUT hmo, UINT uPatch, LPWORD pwkya, UINT fuCache)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutCacheDrumPatches\n");
return midiOutCacheDrumPatches_orig( hmo, uPatch, pwkya, fuCache);
}
MMRESULT WINAPI midiOutGetID( HMIDIOUT hmo, LPUINT puDeviceID)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutGetID\n");
return midiOutGetID_orig( hmo, puDeviceID);
}
MMRESULT WINAPI midiOutMessage( HMIDIOUT hmo, UINT uMsg, DWORD_PTR dw1, DWORD_PTR dw2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiOutMessage\n");
return midiOutMessage_orig( hmo, uMsg, dw1, dw2);
}
UINT WINAPI midiInGetNumDevs(void)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInGetNumDevs\n");
return midiInGetNumDevs_orig();
}
MMRESULT WINAPI midiInGetDevCapsA( UINT_PTR uDeviceID, LPMIDIINCAPSA pmic, UINT cbmic)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInGetDevCapsA\n");
return midiInGetDevCapsA_orig( uDeviceID, pmic, cbmic);
}
MMRESULT WINAPI midiInGetDevCapsW( UINT_PTR uDeviceID, LPMIDIINCAPSW pmic, UINT cbmic)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInGetDevCapsW\n");
return midiInGetDevCapsW_orig( uDeviceID, pmic, cbmic);
}
MMRESULT WINAPI midiInGetErrorTextA( MMRESULT mmrError, LPSTR pszText, UINT cchText)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInGetErrorTextA\n");
return midiInGetErrorTextA_orig( mmrError, pszText, cchText);
}
MMRESULT WINAPI midiInGetErrorTextW( MMRESULT mmrError, LPWSTR pszText, UINT cchText)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInGetErrorTextW\n");
return midiInGetErrorTextW_orig( mmrError, pszText, cchText);
}
MMRESULT WINAPI midiInOpen( LPHMIDIIN phmi, UINT uDeviceID, DWORD_PTR dwCallback, DWORD_PTR dwInstance, DWORD fdwOpen)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInOpen\n");
return midiInOpen_orig(phmi, uDeviceID, dwCallback, dwInstance, fdwOpen);
}
MMRESULT WINAPI midiInClose( HMIDIIN hmi)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInClose\n");
return midiInClose_orig( hmi);
}
MMRESULT WINAPI midiInPrepareHeader( HMIDIIN hmi, LPMIDIHDR pmh, UINT cbmh)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInPrepareHeader\n");
return midiInPrepareHeader_orig( hmi, pmh, cbmh);
}
MMRESULT WINAPI midiInUnprepareHeader( HMIDIIN hmi, LPMIDIHDR pmh, UINT cbmh)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInUnprepareHeader\n");
return midiInUnprepareHeader_orig( hmi, pmh, cbmh);
}
MMRESULT WINAPI midiInAddBuffer( HMIDIIN hmi, LPMIDIHDR pmh, UINT cbmh)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInAddBuffer\n");
return midiInAddBuffer_orig( hmi, pmh, cbmh);
}
MMRESULT WINAPI midiInStart( HMIDIIN hmi)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInStart\n");
return midiInStart_orig( hmi);
}
MMRESULT WINAPI midiInStop( HMIDIIN hmi)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInStop\n");
return midiInStop_orig(hmi);
}
MMRESULT WINAPI midiInReset( HMIDIIN hmi)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInReset\n");
return midiInReset_orig( hmi);
}
MMRESULT WINAPI midiInGetID( HMIDIIN hmi, LPUINT puDeviceID)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInGetID\n");
return midiInGetID_orig( hmi, puDeviceID);
}
MMRESULT WINAPI midiInMessage( HMIDIIN hmi, UINT uMsg, DWORD_PTR dw1, DWORD_PTR dw2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"midiInMessage\n");
return midiInMessage_orig( hmi, uMsg, dw1, dw2);
}
UINT WINAPI auxGetNumDevs(void)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"auxGetNumDevs\n");
return auxGetNumDevs_orig();
}
MMRESULT WINAPI auxGetDevCapsA( UINT_PTR uDeviceID, LPAUXCAPSA pac, UINT cbac)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"auxGetDevCapsA\n");
return auxGetDevCapsA_orig( uDeviceID, pac, cbac);
}
MMRESULT WINAPI auxGetDevCapsW( UINT_PTR uDeviceID, LPAUXCAPSW pac, UINT cbac)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"auxGetDevCapsW\n");
return auxGetDevCapsW_orig( uDeviceID, pac, cbac);
}
MMRESULT WINAPI auxSetVolume( UINT uDeviceID, DWORD dwVolume)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"auxSetVolume\n");
return auxSetVolume_orig( uDeviceID, dwVolume);
}
MMRESULT WINAPI auxGetVolume( UINT uDeviceID, LPDWORD pdwVolume)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"auxGetVolume\n");
return auxGetVolume_orig( uDeviceID, pdwVolume);
}
MMRESULT WINAPI auxOutMessage( UINT uDeviceID, UINT uMsg, DWORD_PTR dw1, DWORD_PTR dw2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"auxOutMessage\n");
return auxOutMessage_orig( uDeviceID, uMsg, dw1, dw2);
}
UINT WINAPI mixerGetNumDevs(void)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerGetNumDevs\n");
return mixerGetNumDevs_orig();
}
MMRESULT WINAPI mixerGetDevCapsA( UINT_PTR uMxId, LPMIXERCAPSA pmxcaps, UINT cbmxcaps)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerGetDevCapsA\n");
return mixerGetDevCapsA_orig( uMxId, pmxcaps, cbmxcaps);
}
MMRESULT WINAPI mixerGetDevCapsW( UINT_PTR uMxId, LPMIXERCAPSW pmxcaps, UINT cbmxcaps)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerGetDevCapsW\n");
return mixerGetDevCapsW_orig( uMxId, pmxcaps, cbmxcaps);
}
MMRESULT WINAPI mixerOpen( LPHMIXER phmx, UINT uMxId, DWORD_PTR dwCallback, DWORD_PTR dwInstance, DWORD fdwOpen)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerOpen\n");
return mixerOpen_orig( phmx, uMxId, dwCallback, dwInstance, fdwOpen);
}
MMRESULT WINAPI mixerClose( HMIXER hmx)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerClose\n");
return mixerClose_orig( hmx);
}
DWORD WINAPI mixerMessage( HMIXER hmx, UINT uMsg, DWORD_PTR dwParam1, DWORD_PTR dwParam2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerMessage\n");
return mixerMessage_orig( hmx, uMsg, dwParam1, dwParam2);
}
MMRESULT WINAPI mixerGetLineInfoA( HMIXEROBJ hmxobj, LPMIXERLINEA pmxl, DWORD fdwInfo)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerGetLineInfoA\n");
return mixerGetLineInfoA_orig( hmxobj, pmxl, fdwInfo);
}
MMRESULT WINAPI mixerGetLineInfoW( HMIXEROBJ hmxobj, LPMIXERLINEW pmxl, DWORD fdwInfo)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerGetLineInfoW\n");
return mixerGetLineInfoW_orig( hmxobj, pmxl, fdwInfo);
}
MMRESULT WINAPI mixerGetID( HMIXEROBJ hmxobj, UINT FAR *puMxId, DWORD fdwId)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerGetID\n");
return mixerGetID_orig( hmxobj, puMxId, fdwId);
}
MMRESULT WINAPI mixerGetLineControlsA( HMIXEROBJ hmxobj, LPMIXERLINECONTROLSA pmxlc, DWORD fdwControls)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerGetLineControlsA\n");
return mixerGetLineControlsA_orig( hmxobj, pmxlc, fdwControls);
}
MMRESULT WINAPI mixerGetLineControlsW( HMIXEROBJ hmxobj, LPMIXERLINECONTROLSW pmxlc, DWORD fdwControls)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerGetLineControlsW\n");
return mixerGetLineControlsW_orig( hmxobj, pmxlc, fdwControls);
}
MMRESULT WINAPI mixerGetControlDetailsA( HMIXEROBJ hmxobj, LPMIXERCONTROLDETAILS pmxcd, DWORD fdwDetails)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerGetControlDetailsA\n");
return mixerGetControlDetailsA_orig( hmxobj, pmxcd, fdwDetails);
}
MMRESULT WINAPI mixerGetControlDetailsW( HMIXEROBJ hmxobj, LPMIXERCONTROLDETAILS pmxcd, DWORD fdwDetails)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerGetControlDetailsW\n");
return mixerGetControlDetailsW_orig( hmxobj, pmxcd, fdwDetails);
}
MMRESULT WINAPI mixerSetControlDetails( HMIXEROBJ hmxobj, LPMIXERCONTROLDETAILS pmxcd, DWORD fdwDetails)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mixerSetControlDetails\n");
return mixerSetControlDetails_orig( hmxobj, pmxcd, fdwDetails);
}
DWORD WINAPI mmGetCurrentTask(void)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmGetCurrentTask\n");
return mmGetCurrentTask_orig();
}
void WINAPI mmTaskBlock(DWORD val)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmTaskBlock\n");
return mmTaskBlock_orig(val);
}
UINT WINAPI mmTaskCreate(LPTASKCALLBACK a, HANDLE* b, DWORD_PTR c)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmTaskCreate\n");
return mmTaskCreate_orig(a, b, c);
}
BOOL WINAPI mmTaskSignal(DWORD a)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmTaskSignal\n");
return mmTaskSignal_orig(a);
}
VOID WINAPI mmTaskYield()
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmTaskYield\n");
mmTaskYield_orig();
}
MMRESULT WINAPI timeGetSystemTime( LPMMTIME pmmt, UINT cbmmt)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"timeGetSystemTime\n");
return timeGetSystemTime_orig( pmmt, cbmmt);
}
DWORD WINAPI timeGetTime(void)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"timeGetTime\n");
return timeGetTime_orig();
}
MMRESULT WINAPI timeSetEvent( UINT uDelay, UINT uResolution, LPTIMECALLBACK fptc, DWORD_PTR dwUser, UINT fuEvent)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"timeSetEvent\n");
return timeSetEvent_orig(uDelay, uResolution, fptc, dwUser, fuEvent);
}
MMRESULT WINAPI timeKillEvent( UINT uTimerID)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"timeKillEvent\n");
return timeKillEvent_orig( uTimerID);
}
MMRESULT WINAPI timeGetDevCaps( LPTIMECAPS ptc, UINT cbtc)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"timeGetDevCaps\n");
return timeGetDevCaps_orig( ptc, cbtc);
}
MMRESULT WINAPI timeBeginPeriod( UINT uPeriod)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"timeBeginPeriod\n");
return timeBeginPeriod_orig( uPeriod);
}
MMRESULT WINAPI timeEndPeriod( UINT uPeriod)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"timeEndPeriod\n");
return timeEndPeriod_orig( uPeriod);
}
UINT WINAPI joyGetNumDevs(void)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"joyGetNumDevs\n");
return joyGetNumDevs_orig();
}
MMRESULT WINAPI joyConfigChanged(DWORD dwFlags)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"joyConfigChanged\n");
return joyConfigChanged_orig(dwFlags);
}
MMRESULT WINAPI joyGetDevCapsA( UINT_PTR uJoyID, LPJOYCAPSA pjc, UINT cbjc)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"joyGetDevCapsA\n");
return joyGetDevCapsA_orig( uJoyID, pjc, cbjc);
}
MMRESULT WINAPI joyGetDevCapsW( UINT_PTR uJoyID, LPJOYCAPSW pjc, UINT cbjc)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"joyGetDevCapsW\n");
return joyGetDevCapsW_orig( uJoyID, pjc, cbjc);
}
MMRESULT WINAPI joyGetPos( UINT uJoyID, LPJOYINFO pji)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"joyGetPos\n");
return joyGetPos_orig( uJoyID, pji);
}
MMRESULT WINAPI joyGetPosEx( UINT uJoyID, LPJOYINFOEX pji)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"joyGetPosEx\n");
return joyGetPosEx_orig( uJoyID, pji);
}
MMRESULT WINAPI joyGetThreshold( UINT uJoyID, LPUINT puThreshold)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"joyGetThreshold\n");
return joyGetThreshold_orig( uJoyID, puThreshold);
}
MMRESULT WINAPI joyReleaseCapture( UINT uJoyID)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"joyReleaseCapture\n");
return joyReleaseCapture_orig( uJoyID);
}
MMRESULT WINAPI joySetCapture( HWND hwnd, UINT uJoyID, UINT uPeriod, BOOL fChanged)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"joySetCapture\n");
return joySetCapture_orig(hwnd, uJoyID, uPeriod, fChanged);
}
MMRESULT WINAPI joySetThreshold( UINT uJoyID, UINT uThreshold)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"joySetThreshold\n");
return joySetThreshold_orig( uJoyID, uThreshold);
}
BOOL WINAPI mciDriverNotify(HWND hwndCallback, UINT uDeviceID, UINT uStatus)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciDriverNotify\n");
return mciDriverNotify_orig(hwndCallback, uDeviceID, uStatus);
}
UINT WINAPI mciDriverYield(UINT uDeviceID)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciDriverYield\n");
return mciDriverYield_orig(uDeviceID);
}
FOURCC WINAPI mmioStringToFOURCCA( LPCSTR sz, UINT uFlags)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioStringToFOURCCA\n");
return mmioStringToFOURCCA_orig( sz, uFlags);
}
FOURCC WINAPI mmioStringToFOURCCW( LPCWSTR sz, UINT uFlags)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioStringToFOURCCW\n");
return mmioStringToFOURCCW_orig( sz, uFlags);
}
LPMMIOPROC WINAPI mmioInstallIOProcA( FOURCC fccIOProc, LPMMIOPROC pIOProc, DWORD dwFlags)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioInstallIOProcA\n");
return mmioInstallIOProcA_orig( fccIOProc, pIOProc, dwFlags);
}
LPMMIOPROC WINAPI mmioInstallIOProcW( FOURCC fccIOProc, LPMMIOPROC pIOProc, DWORD dwFlags)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioInstallIOProcW\n");
return mmioInstallIOProcW_orig( fccIOProc, pIOProc, dwFlags);
}
HMMIO WINAPI mmioOpenA( LPSTR pszFileName, LPMMIOINFO pmmioinfo, DWORD fdwOpen)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioOpenA\n");
return mmioOpenA_orig( pszFileName, pmmioinfo, fdwOpen);
}
HMMIO WINAPI mmioOpenW( LPWSTR pszFileName, LPMMIOINFO pmmioinfo, DWORD fdwOpen)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioOpenW\n");
return mmioOpenW_orig( pszFileName, pmmioinfo, fdwOpen);
}
MMRESULT WINAPI mmioRenameA( LPCSTR pszFileName, LPCSTR pszNewFileName, LPCMMIOINFO pmmioinfo, DWORD fdwRename)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioRenameA\n");
return mmioRenameA_orig( pszFileName, pszNewFileName, pmmioinfo, fdwRename);
}
MMRESULT WINAPI mmioRenameW( LPCWSTR pszFileName, LPCWSTR pszNewFileName, LPCMMIOINFO pmmioinfo, DWORD fdwRename)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioRenameW\n");
return mmioRenameW_orig( pszFileName, pszNewFileName, pmmioinfo, fdwRename);
}
MMRESULT WINAPI mmioClose( HMMIO hmmio, UINT fuClose)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioClose\n");
return mmioClose_orig( hmmio, fuClose);
}
LONG WINAPI mmioRead( HMMIO hmmio, HPSTR pch, LONG cch)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioRead\n");
return mmioRead_orig( hmmio, pch, cch);
}
LONG WINAPI mmioWrite( HMMIO hmmio, const char _huge* pch, LONG cch)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioWrite\n");
return mmioWrite_orig( hmmio, pch, cch);
}
LONG WINAPI mmioSeek( HMMIO hmmio, LONG lOffset, int iOrigin)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioSeek\n");
return mmioSeek_orig(hmmio, lOffset, iOrigin);
}
MMRESULT WINAPI mmioGetInfo( HMMIO hmmio, LPMMIOINFO pmmioinfo, UINT fuInfo)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioGetInfo\n");
return mmioGetInfo_orig( hmmio, pmmioinfo, fuInfo);
}
MMRESULT WINAPI mmioSetInfo( HMMIO hmmio, LPCMMIOINFO pmmioinfo, UINT fuInfo)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioSetInfo\n");
return mmioSetInfo_orig( hmmio, pmmioinfo, fuInfo);
}
MMRESULT WINAPI mmioSetBuffer( HMMIO hmmio, LPSTR pchBuffer, LONG cchBuffer, UINT fuBuffer)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioSetBuffer\n");
return mmioSetBuffer_orig(hmmio, pchBuffer, cchBuffer, fuBuffer);
}
MMRESULT WINAPI mmioFlush( HMMIO hmmio, UINT fuFlush)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioFlush\n");
return mmioFlush_orig( hmmio, fuFlush);
}
MMRESULT WINAPI mmioAdvance( HMMIO hmmio, LPMMIOINFO pmmioinfo, UINT fuAdvance)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioAdvance\n");
return mmioAdvance_orig( hmmio, pmmioinfo, fuAdvance);
}
LRESULT WINAPI mmioSendMessage( HMMIO hmmio, UINT uMsg, LPARAM lParam1, LPARAM lParam2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioSendMessage\n");
return mmioSendMessage_orig(hmmio, uMsg, lParam1, lParam2);
}
MMRESULT WINAPI mmioDescend( HMMIO hmmio, LPMMCKINFO pmmcki, const MMCKINFO FAR* pmmckiParent, UINT fuDescend)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioDescend\n");
return mmioDescend_orig(hmmio, pmmcki, pmmckiParent, fuDescend);
}
MMRESULT WINAPI mmioAscend( HMMIO hmmio, LPMMCKINFO pmmcki, UINT fuAscend)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioAscend\n");
return mmioAscend_orig( hmmio, pmmcki, fuAscend);
}
MMRESULT WINAPI mmioCreateChunk(HMMIO hmmio, LPMMCKINFO pmmcki, UINT fuCreate)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mmioCreateChunk\n");
return mmioCreateChunk_orig(hmmio, pmmcki, fuCreate);
}
MCIERROR WINAPI mciSendCommandA( MCIDEVICEID mciId, UINT uMsg, DWORD_PTR dwParam1, DWORD_PTR dwParam2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciSendCommandA\n");
return mciSendCommandA_orig( mciId, uMsg, dwParam1, dwParam2);
}
MCIERROR WINAPI mciSendCommandW( MCIDEVICEID mciId, UINT uMsg, DWORD_PTR dwParam1, DWORD_PTR dwParam2)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciSendCommandW\n");
return mciSendCommandW_orig( mciId, uMsg, dwParam1, dwParam2);
}
MCIERROR WINAPI mciSendStringA( LPCSTR lpstrCommand, LPSTR lpstrReturnString, UINT uReturnLength, HWND hwndCallback)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciSendStringA\n");
return mciSendStringA_orig( lpstrCommand, lpstrReturnString, uReturnLength, hwndCallback);
}
MCIERROR WINAPI mciSendStringW( LPCWSTR lpstrCommand, LPWSTR lpstrReturnString, UINT uReturnLength, HWND hwndCallback)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciSendStringW\n");
return mciSendStringW_orig( lpstrCommand, lpstrReturnString, uReturnLength, hwndCallback);
}
@@ -1375,72 +1535,84 @@ extern "C" {
MCIDEVICEID WINAPI mciGetDeviceIDW( LPCWSTR pszDevice)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciGetDeviceIDW\n");
return mciGetDeviceIDW_orig( pszDevice);
}
MCIDEVICEID WINAPI mciGetDeviceIDFromElementIDA( DWORD dwElementID, LPCSTR lpstrType )
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciGetDeviceIDFromElementIDA\n");
return mciGetDeviceIDFromElementIDA_orig( dwElementID, lpstrType );
}
MCIDEVICEID WINAPI mciGetDeviceIDFromElementIDW( DWORD dwElementID, LPCWSTR lpstrType )
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciGetDeviceIDFromElementIDW\n");
return mciGetDeviceIDFromElementIDW_orig( dwElementID, lpstrType );
}
DWORD_PTR WINAPI mciGetDriverData(UINT uDeviceID)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciGetDriverData\n");
return mciGetDriverData_orig(uDeviceID);
}
BOOL WINAPI mciGetErrorStringA( MCIERROR mcierr, LPSTR pszText, UINT cchText)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciGetErrorStringA\n");
return mciGetErrorStringA_orig( mcierr, pszText, cchText);
}
BOOL WINAPI mciGetErrorStringW( MCIERROR mcierr, LPWSTR pszText, UINT cchText)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciGetErrorStringW\n");
return mciGetErrorStringW_orig( mcierr, pszText, cchText);
}
BOOL WINAPI mciSetDriverData(UINT uDeviceID, DWORD_PTR dwData)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciSetDriverData_type\n");
return mciSetDriverData_orig( uDeviceID, dwData );
}
BOOL WINAPI mciSetYieldProc( MCIDEVICEID mciId, YIELDPROC fpYieldProc, DWORD dwYieldData)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciSetYieldProc\n");
return mciSetYieldProc_orig(mciId, fpYieldProc, dwYieldData);
}
BOOL WINAPI mciFreeCommandResource(UINT uTable)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciFreeCommandResource\n");
return mciFreeCommandResource_orig(uTable);
}
HTASK WINAPI mciGetCreatorTask( MCIDEVICEID mciId)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciGetCreatorTask\n");
return mciGetCreatorTask_orig( mciId);
}
YIELDPROC WINAPI mciGetYieldProc( MCIDEVICEID mciId, LPDWORD pdwYieldData)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciGetYieldProc\n");
return mciGetYieldProc_orig( mciId, pdwYieldData);
}
UINT WINAPI mciLoadCommandResource(HINSTANCE hInstance, LPCWSTR lpResName, UINT uType)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciLoadCommandResource");
return mciLoadCommandResource_orig(hInstance, lpResName, uType);
}
@@ -1448,6 +1620,7 @@ extern "C" {
BOOL WINAPI mciExecute(LPCSTR pszCommand)
{
+ ll_winmm_shim_initialize();
//OutputDebugString(L"mciExecute\n");
return mciExecute_orig(pszCommand);
}
diff --git a/indra/media_plugins/winmmshim/forwarding_api.h b/indra/media_plugins/winmmshim/forwarding_api.h
index 89a6b347f3..076a08f769 100644
--- a/indra/media_plugins/winmmshim/forwarding_api.h
+++ b/indra/media_plugins/winmmshim/forwarding_api.h
@@ -30,6 +30,7 @@
#include <mmsystem.h>
void init_function_pointers(HMODULE winmm_handle);
+void ll_winmm_shim_initialize();
typedef VOID (*LPTASKCALLBACK)(DWORD_PTR dwInst);
diff --git a/indra/media_plugins/winmmshim/winmm_shim.cpp b/indra/media_plugins/winmmshim/winmm_shim.cpp
index 9563a3b664..47a1e5c018 100644
--- a/indra/media_plugins/winmmshim/winmm_shim.cpp
+++ b/indra/media_plugins/winmmshim/winmm_shim.cpp
@@ -32,14 +32,21 @@ using std::wstring;
static float sVolumeLevel = 1.f;
static bool sMute = false;
+static CRITICAL_SECTION sCriticalSection;
BOOL APIENTRY DllMain( HMODULE hModule,
DWORD ul_reason_for_call,
LPVOID lpReserved
)
{
+ InitializeCriticalSection(&sCriticalSection);
+ return TRUE;
+}
+
+void ll_winmm_shim_initialize(){
static bool initialized = false;
// do this only once
+ EnterCriticalSection(&sCriticalSection);
if (!initialized)
{ // bind to original winmm.dll
TCHAR system_path[MAX_PATH];
@@ -54,13 +61,15 @@ BOOL APIENTRY DllMain( HMODULE hModule,
{ // we have a dll, let's get out pointers!
initialized = true;
init_function_pointers(winmm_handle);
- return true;
+ ::OutputDebugStringA("WINMM_SHIM.DLL: real winmm.dll initialized successfully\n");
+ }
+ else
+ {
+ // failed to initialize real winmm.dll
+ ::OutputDebugStringA("WINMM_SHIM.DLL: Failed to initialize real winmm.dll\n");
}
-
- // failed to initialize real winmm.dll
- return false;
}
- return true;
+ LeaveCriticalSection(&sCriticalSection);
}
@@ -79,6 +88,7 @@ extern "C"
MMRESULT WINAPI waveOutOpen( LPHWAVEOUT phwo, UINT uDeviceID, LPCWAVEFORMATEX pwfx, DWORD_PTR dwCallback, DWORD_PTR dwInstance, DWORD fdwOpen)
{
+ ll_winmm_shim_initialize();
if (pwfx->wFormatTag != WAVE_FORMAT_PCM
|| (pwfx->wBitsPerSample != 8 && pwfx->wBitsPerSample != 16))
{ // uncompressed 8 and 16 bit sound are the only types we support
@@ -97,6 +107,7 @@ extern "C"
MMRESULT WINAPI waveOutClose( HWAVEOUT hwo)
{
+ ll_winmm_shim_initialize();
wave_out_map_t::iterator found_it = sWaveOuts.find(hwo);
if (found_it != sWaveOuts.end())
{ // forget what we know about this handle
@@ -108,6 +119,7 @@ extern "C"
MMRESULT WINAPI waveOutWrite( HWAVEOUT hwo, LPWAVEHDR pwh, UINT cbwh)
{
+ ll_winmm_shim_initialize();
MMRESULT result = MMSYSERR_NOERROR;
if (sMute)
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml
index f2a0e5ac19..636f6e65fe 100644
--- a/indra/newview/app_settings/settings.xml
+++ b/indra/newview/app_settings/settings.xml
@@ -9557,7 +9557,7 @@
<key>ShowNetStats</key>
<map>
<key>Comment</key>
- <string>Show the Search Bar in the Status Overlay</string>
+ <string>Show the Status Indicators for the Viewer and Network Usage in the Status Overlay</string>
<key>Persist</key>
<integer>1</integer>
<key>Type</key>
@@ -11926,6 +11926,33 @@
<key>Value</key>
<integer>0</integer>
</map>
+ <key>WaterFogColor</key>
+ <map>
+ <key>Comment</key>
+ <string>Water fog color</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>Color4</string>
+ <key>Value</key>
+ <array>
+ <real>0.0863</real>
+ <real>0.168</real>
+ <real>0.212</real>
+ <real>0</real>
+ </array>
+ </map>
+ <key>WaterFogDensity</key>
+ <map>
+ <key>Comment</key>
+ <string>Water fog density</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>F32</string>
+ <key>Value</key>
+ <real>16.0</real>
+ </map>
<key>WaterGLFogDensityScale</key>
<map>
<key>Comment</key>
diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml
index 85899603ee..ec162e3608 100644
--- a/indra/newview/character/avatar_lad.xml
+++ b/indra/newview/character/avatar_lad.xml
@@ -4339,8 +4339,8 @@
wearable="shape"
edit_group="driven"
value_default="0"
- value_min="-2"
- value_max="2">
+ value_min="-3"
+ value_max="3">
<param_morph />
</param>
@@ -4352,8 +4352,8 @@
wearable="shape"
edit_group="driven"
value_default="0"
- value_min="-1"
- value_max="1">
+ value_min="-1.5"
+ value_max="1.5">
<param_morph />
</param>
@@ -11916,7 +11916,7 @@ render_pass="bump">
edit_group="physics_breasts_updown"
value_default=".1"
value_min="0"
- value_max="1">
+ value_max="3">
<param_driver />
</param>
<param
@@ -11971,7 +11971,7 @@ render_pass="bump">
edit_group="physics_breasts_inout"
value_default=".1"
value_min="0"
- value_max="1">
+ value_max="3">
<param_driver />
</param>
<param
@@ -12058,7 +12058,7 @@ render_pass="bump">
edit_group="physics_belly_updown"
value_default=".1"
value_min="0"
- value_max="1">
+ value_max="3">
<param_driver />
</param>
<param
@@ -12144,7 +12144,7 @@ render_pass="bump">
edit_group="physics_butt_updown"
value_default=".1"
value_min="0"
- value_max="1">
+ value_max="3">
<param_driver />
</param>
<param
@@ -12193,7 +12193,7 @@ render_pass="bump">
edit_group="physics_butt_leftright"
value_default=".1"
value_min="0"
- value_max="1">
+ value_max="3">
<param_driver />
</param>
<param
@@ -12244,7 +12244,7 @@ render_pass="bump">
edit_group="physics_breasts_leftright"
value_default=".1"
value_min="0"
- value_max="1">
+ value_max="3">
<param_driver />
</param>
<param
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp
index cbd996f909..061ef7268e 100644
--- a/indra/newview/llappviewer.cpp
+++ b/indra/newview/llappviewer.cpp
@@ -2467,6 +2467,14 @@ bool LLAppViewer::initConfiguration()
}
}
+ // If automatic login from command line with --login switch
+ // init StartSLURL location. In interactive login, LLPanelLogin
+ // will take care of it.
+ if ((clp.hasOption("login") || clp.hasOption("autologin")) && !clp.hasOption("url") && !clp.hasOption("slurl"))
+ {
+ LLStartUp::setStartSLURL(LLSLURL(gSavedSettings.getString("LoginLocation")));
+ }
+
if (!gSavedSettings.getBOOL("AllowMultipleViewers"))
{
//
diff --git a/indra/newview/llbreastmotion.cpp b/indra/newview/llbreastmotion.cpp
index 7c205a8b9f..9a8cd5ceae 100644
--- a/indra/newview/llbreastmotion.cpp
+++ b/indra/newview/llbreastmotion.cpp
@@ -2,31 +2,25 @@
* @file llbreastmotion.cpp
* @brief Implementation of LLBreastMotion class.
*
- * $LicenseInfo:firstyear=2001&license=viewergpl$
- *
- * Copyright (c) 2001-2009, Linden Research, Inc.
- *
+ * $LicenseInfo:firstyear=2011&license=viewerlgpl$
* Second Life Viewer Source Code
- * The source code in this file ("Source Code") is provided by Linden Lab
- * to you under the terms of the GNU General Public License, version 2.0
- * ("GPL"), unless you have obtained a separate licensing agreement
- * ("Other License"), formally executed by you and Linden Lab. Terms of
- * the GPL can be found in doc/GPL-license.txt in this distribution, or
- * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ * Copyright (C) 2011, 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.
*
- * There are special exceptions to the terms and conditions of the GPL as
- * it is applied to this Source Code. View the full text of the exception
- * in the file doc/FLOSS-exception.txt in this software distribution, or
- * online at
- * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ * 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.
*
- * By copying, modifying or distributing this software, you acknowledge
- * that you have read and understood your obligations described above,
- * and agree to abide by those obligations.
+ * 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
*
- * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
- * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
- * COMPLETENESS OR PERFORMANCE.
+ * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
* $/LicenseInfo$
*/
diff --git a/indra/newview/llbreastmotion.h b/indra/newview/llbreastmotion.h
index 8578d4ad1a..aa0fdf9f8b 100644
--- a/indra/newview/llbreastmotion.h
+++ b/indra/newview/llbreastmotion.h
@@ -2,31 +2,25 @@
* @file llbreastmotion.h
* @brief Implementation of LLBreastMotion class.
*
- * $LicenseInfo:firstyear=2001&license=viewergpl$
- *
- * Copyright (c) 2001-2009, Linden Research, Inc.
- *
+ * $LicenseInfo:firstyear=2011&license=viewerlgpl$
* Second Life Viewer Source Code
- * The source code in this file ("Source Code") is provided by Linden Lab
- * to you under the terms of the GNU General Public License, version 2.0
- * ("GPL"), unless you have obtained a separate licensing agreement
- * ("Other License"), formally executed by you and Linden Lab. Terms of
- * the GPL can be found in doc/GPL-license.txt in this distribution, or
- * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
+ * Copyright (C) 2011, 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.
*
- * There are special exceptions to the terms and conditions of the GPL as
- * it is applied to this Source Code. View the full text of the exception
- * in the file doc/FLOSS-exception.txt in this software distribution, or
- * online at
- * http://secondlifegrid.net/programs/open_source/licensing/flossexception
+ * 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.
*
- * By copying, modifying or distributing this software, you acknowledge
- * that you have read and understood your obligations described above,
- * and agree to abide by those obligations.
+ * 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
*
- * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
- * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
- * COMPLETENESS OR PERFORMANCE.
+ * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
* $/LicenseInfo$
*/
diff --git a/indra/newview/lldateutil.cpp b/indra/newview/lldateutil.cpp
index fcc73a07bc..18ae6107e7 100644
--- a/indra/newview/lldateutil.cpp
+++ b/indra/newview/lldateutil.cpp
@@ -32,9 +32,9 @@
#include "llui.h"
static S32 DAYS_PER_MONTH_NOLEAP[] =
- { 31, 28, 21, 30, 31, 30, 31, 31, 30, 31, 30, 31 };
+ { 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 };
static S32 DAYS_PER_MONTH_LEAP[] =
- { 31, 29, 21, 30, 31, 30, 31, 31, 30, 31, 30, 31 };
+ { 31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 };
static S32 days_from_month(S32 year, S32 month)
{
diff --git a/indra/newview/llexpandabletextbox.cpp b/indra/newview/llexpandabletextbox.cpp
index 5e10f60aba..5501b8c2ac 100644
--- a/indra/newview/llexpandabletextbox.cpp
+++ b/indra/newview/llexpandabletextbox.cpp
@@ -123,10 +123,7 @@ void LLExpandableTextBox::LLTextBoxEx::reshape(S32 width, S32 height, BOOL calle
{
LLTextEditor::reshape(width, height, called_from_parent);
- if (getTextPixelHeight() > getRect().getHeight())
- {
- showExpandText();
- }
+ hideOrShowExpandTextAsNeeded();
}
void LLExpandableTextBox::LLTextBoxEx::setText(const LLStringExplicit& text,const LLStyle::Params& input_params)
@@ -136,17 +133,7 @@ void LLExpandableTextBox::LLTextBoxEx::setText(const LLStringExplicit& text,cons
mExpanderVisible = false;
LLTextEditor::setText(text, input_params);
- // text contents have changed, segments are cleared out
- // so hide the expander and determine if we need it
- //mExpanderVisible = false;
- if (getTextPixelHeight() > getRect().getHeight())
- {
- showExpandText();
- }
- else
- {
- hideExpandText();
- }
+ hideOrShowExpandTextAsNeeded();
}
@@ -200,6 +187,22 @@ S32 LLExpandableTextBox::LLTextBoxEx::getTextPixelHeight()
return getTextBoundingRect().getHeight();
}
+void LLExpandableTextBox::LLTextBoxEx::hideOrShowExpandTextAsNeeded()
+{
+ // Restore the text box contents to calculate the text height properly,
+ // otherwise if a part of the text is hidden under "More" link
+ // getTextPixelHeight() returns only the height of currently visible text
+ // including the "More" link. See STORM-250.
+ hideExpandText();
+
+ // Show the expander a.k.a. "More" link if we need it, depending on text
+ // contents height. If not, keep it hidden.
+ if (getTextPixelHeight() > getRect().getHeight())
+ {
+ showExpandText();
+ }
+}
+
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
diff --git a/indra/newview/llexpandabletextbox.h b/indra/newview/llexpandabletextbox.h
index bce77225c4..f75ef954ff 100644
--- a/indra/newview/llexpandabletextbox.h
+++ b/indra/newview/llexpandabletextbox.h
@@ -77,6 +77,12 @@ protected:
*/
void hideExpandText();
+ /**
+ * Shows the "More" link if the text is too high to be completely
+ * visible without expanding the text box. Hides that link otherwise.
+ */
+ void hideOrShowExpandTextAsNeeded();
+
protected:
LLTextBoxEx(const Params& p);
diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp
index 1a9d0af9af..b4b12024aa 100644
--- a/indra/newview/llfloaterpreference.cpp
+++ b/indra/newview/llfloaterpreference.cpp
@@ -286,8 +286,7 @@ LLFloaterPreference::LLFloaterPreference(const LLSD& key)
mOriginalIMViaEmail(false),
mLanguageChanged(false),
mAvatarDataInitialized(false),
- mDoubleClickActionDirty(false),
- mFavoritesRecordMayExist(false)
+ mDoubleClickActionDirty(false)
{
//Build Floater is now Called from LLFloaterReg::add("preferences", "floater_preferences.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<LLFloaterPreference>);
@@ -412,6 +411,8 @@ BOOL LLFloaterPreference::postBuild()
gSavedSettings.getControl("ChatFontSize")->getSignal()->connect(boost::bind(&LLNearbyChat::processChatHistoryStyleUpdate, _2));
+ gSavedSettings.getControl("ChatFontSize")->getSignal()->connect(boost::bind(&LLViewerChat::signalChatFontChanged));
+
gSavedSettings.getControl("ChatBubbleOpacity")->getSignal()->connect(boost::bind(&LLFloaterPreference::onNameTagOpacityChange, this, _2));
LLTabContainer* tabcontainer = getChild<LLTabContainer>("pref core");
@@ -565,34 +566,6 @@ void LLFloaterPreference::apply()
updateDoubleClickSettings();
mDoubleClickActionDirty = false;
}
-
- if (mFavoritesRecordMayExist && !gSavedPerAccountSettings.getBOOL("ShowFavoritesOnLogin"))
- {
- removeFavoritesRecordOfUser();
- }
-}
-
-void LLFloaterPreference::removeFavoritesRecordOfUser()
-{
- mFavoritesRecordMayExist = false;
- std::string filename = gDirUtilp->getExpandedFilename(LL_PATH_USER_SETTINGS, "stored_favorites.xml");
- LLSD fav_llsd;
- llifstream file;
- file.open(filename);
- if (!file.is_open()) return;
- LLSDSerialize::fromXML(fav_llsd, file);
-
- LLAvatarName av_name;
- LLAvatarNameCache::get( gAgentID, &av_name );
- if (fav_llsd.has(av_name.getLegacyName()))
- {
- fav_llsd.erase(av_name.getLegacyName());
- }
-
- llofstream out_file;
- out_file.open(filename);
- LLSDSerialize::toPrettyXML(fav_llsd, out_file);
-
}
void LLFloaterPreference::cancel()
@@ -678,11 +651,6 @@ void LLFloaterPreference::onOpen(const LLSD& key)
getChildView("maturity_desired_combobox")->setVisible( false);
}
- if (LLStartUp::getStartupState() == STATE_STARTED)
- {
- mFavoritesRecordMayExist = gSavedPerAccountSettings.getBOOL("ShowFavoritesOnLogin");
- }
-
// Forget previous language changes.
mLanguageChanged = false;
diff --git a/indra/newview/llfloaterpreference.h b/indra/newview/llfloaterpreference.h
index 5d5e066ec5..4d8a2489be 100644
--- a/indra/newview/llfloaterpreference.h
+++ b/indra/newview/llfloaterpreference.h
@@ -159,8 +159,6 @@ public:
void buildPopupLists();
static void refreshSkin(void* data);
- // Remove record of current user's favorites from file on disk.
- void removeFavoritesRecordOfUser();
private:
static std::string sSkin;
// set true if state of double-click action checkbox or radio-group was changed by user
@@ -172,8 +170,6 @@ private:
bool mAvatarDataInitialized;
bool mOriginalHideOnlineStatus;
- // Record of current user's favorites may be stored in file on disk.
- bool mFavoritesRecordMayExist;
std::string mDirectoryVisibility;
LLAvatarData mAvatarProperties;
diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp
index f74ae92a7b..50a9c56518 100644
--- a/indra/newview/llimfloater.cpp
+++ b/indra/newview/llimfloater.cpp
@@ -56,6 +56,7 @@
#include "llrootview.h"
#include "llspeakers.h"
#include "llsidetray.h"
+#include "llviewerchat.h"
static const S32 RECT_PADDING_NOT_INIT = -1;
@@ -266,7 +267,9 @@ BOOL LLIMFloater::postBuild()
mInputEditor->setMaxTextLength(1023);
// enable line history support for instant message bar
mInputEditor->setEnableLineHistory(TRUE);
-
+
+ LLFontGL* font = LLViewerChat::getChatFont();
+ mInputEditor->setFont(font);
mInputEditor->setFocusReceivedCallback( boost::bind(onInputEditorFocusReceived, _1, this) );
mInputEditor->setFocusLostCallback( boost::bind(onInputEditorFocusLost, _1, this) );
@@ -891,6 +894,7 @@ void LLIMFloater::updateChatHistoryStyle()
void LLIMFloater::processChatHistoryStyleUpdate(const LLSD& newvalue)
{
+ LLFontGL* font = LLViewerChat::getChatFont();
LLFloaterReg::const_instance_list_t& inst_list = LLFloaterReg::getFloaterList("impanel");
for (LLFloaterReg::const_instance_list_t::const_iterator iter = inst_list.begin();
iter != inst_list.end(); ++iter)
@@ -899,6 +903,7 @@ void LLIMFloater::processChatHistoryStyleUpdate(const LLSD& newvalue)
if (floater)
{
floater->updateChatHistoryStyle();
+ floater->mInputEditor->setFont(font);
}
}
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index 622a5607df..bdb9f6167a 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -4681,7 +4681,7 @@ void LLWearableBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
if (LLWearableType::getAllowMultiwear(mWearableType))
{
items.push_back(std::string("Wearable Add"));
- if (gAgentWearables.getWearableCount(mWearableType) > 0)
+ if (gAgentWearables.getWearableCount(mWearableType) >= LLAgentWearables::MAX_CLOTHING_PER_TYPE)
{
disabled_items.push_back(std::string("Wearable Add"));
}
diff --git a/indra/newview/llinventorymodel.cpp b/indra/newview/llinventorymodel.cpp
index 53835f0166..b1975c7261 100644
--- a/indra/newview/llinventorymodel.cpp
+++ b/indra/newview/llinventorymodel.cpp
@@ -1059,12 +1059,11 @@ void LLInventoryModel::idleNotifyObservers()
{
return;
}
- notifyObservers("");
+ notifyObservers();
}
// Call this method when it's time to update everyone on a new state.
-// The optional argument 'service_name' is used by Agent Inventory Service [DEV-20328]
-void LLInventoryModel::notifyObservers(const std::string service_name)
+void LLInventoryModel::notifyObservers()
{
if (mIsNotifyObservers)
{
@@ -1081,15 +1080,7 @@ void LLInventoryModel::notifyObservers(const std::string service_name)
{
LLInventoryObserver* observer = *iter;
- if (service_name.empty())
- {
- observer->changed(mModifyMask);
- }
- else
- {
- observer->mMessageName = service_name;
- observer->changed(mModifyMask);
- }
+ observer->changed(mModifyMask);
// safe way to increment since changed may delete entries! (@!##%@!@&*!)
iter = mObservers.upper_bound(observer);
@@ -1187,7 +1178,7 @@ void LLInventoryModel::fetchInventoryResponder::result(const LLSD& content)
{
changes |= gInventory.updateItem(*it);
}
- gInventory.notifyObservers("fetchinventory");
+ gInventory.notifyObservers();
gViewerWindow->getWindow()->decBusyCount();
}
@@ -1196,7 +1187,7 @@ void LLInventoryModel::fetchInventoryResponder::error(U32 status, const std::str
{
llinfos << "fetchInventory::error "
<< status << ": " << reason << llendl;
- gInventory.notifyObservers("fetchinventory");
+ gInventory.notifyObservers();
}
bool LLInventoryModel::fetchDescendentsOf(const LLUUID& folder_id) const
diff --git a/indra/newview/llinventorymodel.h b/indra/newview/llinventorymodel.h
index f6728fd575..15da09990f 100644
--- a/indra/newview/llinventorymodel.h
+++ b/indra/newview/llinventorymodel.h
@@ -425,9 +425,8 @@ public:
// has been indicated.
void idleNotifyObservers();
- // Call to explicitly update everyone on a new state. The optional argument
- // 'service_name' is used by Agent Inventory Service [DEV-20328]
- void notifyObservers(const std::string service_name="");
+ // Call to explicitly update everyone on a new state.
+ void notifyObservers();
// Allows outsiders to tell the inventory if something has
// been changed 'under the hood', but outside the control of the
diff --git a/indra/newview/llinventorymodelbackgroundfetch.cpp b/indra/newview/llinventorymodelbackgroundfetch.cpp
index e31360fcbc..7b1ff102e7 100644
--- a/indra/newview/llinventorymodelbackgroundfetch.cpp
+++ b/indra/newview/llinventorymodelbackgroundfetch.cpp
@@ -388,7 +388,7 @@ void LLInventoryModelFetchDescendentsResponder::result(const LLSD& content)
titem->setParent(lost_uuid);
titem->updateParentOnServer(FALSE);
gInventory.updateItem(titem);
- gInventory.notifyObservers("fetchDescendents");
+ gInventory.notifyObservers();
}
}
@@ -464,7 +464,7 @@ void LLInventoryModelFetchDescendentsResponder::result(const LLSD& content)
fetcher->setAllFoldersFetched();
}
- gInventory.notifyObservers("fetchDescendents");
+ gInventory.notifyObservers();
}
// If we get back an error (not found, etc...), handle it here.
@@ -496,7 +496,7 @@ void LLInventoryModelFetchDescendentsResponder::error(U32 status, const std::str
fetcher->setAllFoldersFetched();
}
}
- gInventory.notifyObservers("fetchDescendents");
+ gInventory.notifyObservers();
}
BOOL LLInventoryModelFetchDescendentsResponder::getIsRecursive(const LLUUID& cat_id) const
diff --git a/indra/newview/llinventoryobserver.cpp b/indra/newview/llinventoryobserver.cpp
index 0fd4b2bee5..6bf19e346d 100644
--- a/indra/newview/llinventoryobserver.cpp
+++ b/indra/newview/llinventoryobserver.cpp
@@ -572,16 +572,7 @@ void LLInventoryAddedObserver::changed(U32 mask)
// the network, figure out which item was updated.
LLMessageSystem* msg = gMessageSystem;
- std::string msg_name;
- if (mMessageName.empty())
- {
- msg_name = msg->getMessageName();
- }
- else
- {
- msg_name = mMessageName;
- }
-
+ std::string msg_name = msg->getMessageName();
if (msg_name.empty())
{
return;
diff --git a/indra/newview/llinventoryobserver.h b/indra/newview/llinventoryobserver.h
index f2a2049a51..2d9021961e 100644
--- a/indra/newview/llinventoryobserver.h
+++ b/indra/newview/llinventoryobserver.h
@@ -63,7 +63,6 @@ public:
LLInventoryObserver();
virtual ~LLInventoryObserver();
virtual void changed(U32 mask) = 0;
- std::string mMessageName; // used by Agent Inventory Service only. [DEV-20328]
};
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
diff --git a/indra/newview/llnearbychatbar.cpp b/indra/newview/llnearbychatbar.cpp
index 162e465fef..d3fd959152 100644
--- a/indra/newview/llnearbychatbar.cpp
+++ b/indra/newview/llnearbychatbar.cpp
@@ -47,6 +47,7 @@
#include "llwindow.h"
#include "llviewerwindow.h"
#include "llrootview.h"
+#include "llviewerchat.h"
S32 LLNearbyChatBar::sLastSpecialChatChannel = 0;
@@ -433,13 +434,26 @@ BOOL LLNearbyChatBar::postBuild()
mChatBox->setPassDelete(TRUE);
mChatBox->setReplaceNewlinesWithSpaces(FALSE);
mChatBox->setEnableLineHistory(TRUE);
+ mChatBox->setFont(LLViewerChat::getChatFont());
mOutputMonitor = getChild<LLOutputMonitorCtrl>("chat_zone_indicator");
mOutputMonitor->setVisible(FALSE);
+ // Register for font change notifications
+ LLViewerChat::setFontChangedCallback(boost::bind(&LLNearbyChatBar::onChatFontChange, this, _1));
+
return TRUE;
}
+void LLNearbyChatBar::onChatFontChange(LLFontGL* fontp)
+{
+ // Update things with the new font whohoo
+ if (mChatBox)
+ {
+ mChatBox->setFont(fontp);
+ }
+}
+
//static
LLNearbyChatBar* LLNearbyChatBar::getInstance()
{
diff --git a/indra/newview/llnearbychatbar.h b/indra/newview/llnearbychatbar.h
index 96ab45071b..efddec942f 100644
--- a/indra/newview/llnearbychatbar.h
+++ b/indra/newview/llnearbychatbar.h
@@ -127,6 +127,7 @@ protected:
void sendChat( EChatType type );
void onChatBoxCommit();
+ void onChatFontChange(LLFontGL* fontp);
static LLWString stripChannelNumber(const LLWString &mesg, S32* channel);
EChatType processChatTypeTriggers(EChatType type, std::string &str);
diff --git a/indra/newview/llpaneleditwearable.cpp b/indra/newview/llpaneleditwearable.cpp
index 8bd2d5ad6a..cb8fbd66b5 100644
--- a/indra/newview/llpaneleditwearable.cpp
+++ b/indra/newview/llpaneleditwearable.cpp
@@ -1196,6 +1196,12 @@ void LLPanelEditWearable::onTabExpandedCollapsed(const LLSD& param, U8 index)
void LLPanelEditWearable::changeCamera(U8 subpart)
{
+ // Don't change the camera if this type doesn't have a camera switch.
+ // Useful for wearables like physics that don't have an associated physical body part.
+ if (LLWearableType::getDisableCameraSwitch(mWearablePtr->getType()))
+ {
+ return;
+ }
const LLEditWearableDictionary::WearableEntry *wearable_entry = LLEditWearableDictionary::getInstance()->getWearable(mWearablePtr->getType());
if (!wearable_entry)
{
diff --git a/indra/newview/llpanellogin.cpp b/indra/newview/llpanellogin.cpp
index 7820ac3ecd..979d96ca0d 100644
--- a/indra/newview/llpanellogin.cpp
+++ b/indra/newview/llpanellogin.cpp
@@ -81,6 +81,9 @@ const S32 MAX_PASSWORD = 16;
LLPanelLogin *LLPanelLogin::sInstance = NULL;
BOOL LLPanelLogin::sCapslockDidNotification = FALSE;
+// Helper for converting a user name into the canonical "Firstname Lastname" form.
+// For new accounts without a last name "Resident" is added as a last name.
+static std::string canonicalize_username(const std::string& name);
class LLLoginRefreshHandler : public LLCommandHandler
{
@@ -302,7 +305,14 @@ void LLPanelLogin::addFavoritesToStartLocation()
for (LLSD::map_const_iterator iter = fav_llsd.beginMap();
iter != fav_llsd.endMap(); ++iter)
{
- if(iter->first != getChild<LLComboBox>("username_combo")->getSimple()) continue;
+ std::string user_defined_name = getChild<LLComboBox>("username_combo")->getSimple();
+
+ // The account name in stored_favorites.xml has Resident last name even if user has
+ // a single word account name, so it can be compared case-insensitive with the
+ // user defined "firstname lastname".
+ S32 res = LLStringUtil::compareInsensitive(canonicalize_username(user_defined_name), iter->first);
+ if (res != 0) continue;
+
combo->addSeparator();
LLSD user_llsd = iter->second;
for (LLSD::array_const_iterator iter1 = user_llsd.beginArray();
@@ -1186,3 +1196,28 @@ void LLPanelLogin::onModeChangeConfirm(const LLSD& original_value, const LLSD& n
break;
}
}
+
+std::string canonicalize_username(const std::string& name)
+{
+ std::string cname = name;
+ LLStringUtil::trim(cname);
+
+ // determine if the username is a first/last form or not.
+ size_t separator_index = cname.find_first_of(" ._");
+ std::string first = cname.substr(0, separator_index);
+ std::string last;
+ if (separator_index != cname.npos)
+ {
+ last = cname.substr(separator_index+1, cname.npos);
+ LLStringUtil::trim(last);
+ }
+ else
+ {
+ // ...on Linden grids, single username users as considered to have
+ // last name "Resident"
+ last = "Resident";
+ }
+
+ // Username in traditional "firstname lastname" form.
+ return first + ' ' + last;
+}
diff --git a/indra/newview/llphysicsmotion.cpp b/indra/newview/llphysicsmotion.cpp
index acf8973f03..23fa0cbd9c 100644
--- a/indra/newview/llphysicsmotion.cpp
+++ b/indra/newview/llphysicsmotion.cpp
@@ -1,701 +1,717 @@
-/**
- * @file llphysicsmotion.cpp
- * @brief Implementation of LLPhysicsMotion class.
- *
- * $LicenseInfo:firstyear=2001&license=viewergpl$
- *
- * Copyright (c) 2001-2009, Linden Research, Inc.
- *
- * Second Life Viewer Source Code
- * The source code in this file ("Source Code") is provided by Linden Lab
- * to you under the terms of the GNU General Public License, version 2.0
- * ("GPL"), unless you have obtained a separate licensing agreement
- * ("Other License"), formally executed by you and Linden Lab. Terms of
- * the GPL can be found in doc/GPL-license.txt in this distribution, or
- * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
- *
- * There are special exceptions to the terms and conditions of the GPL as
- * it is applied to this Source Code. View the full text of the exception
- * in the file doc/FLOSS-exception.txt in this software distribution, or
- * online at
- * http://secondlifegrid.net/programs/open_source/licensing/flossexception
- *
- * By copying, modifying or distributing this software, you acknowledge
- * that you have read and understood your obligations described above,
- * and agree to abide by those obligations.
- *
- * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
- * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
- * COMPLETENESS OR PERFORMANCE.
- * $/LicenseInfo$
- */
-
-//-----------------------------------------------------------------------------
-// Header Files
-//-----------------------------------------------------------------------------
-#include "llviewerprecompiledheaders.h"
-#include "linden_common.h"
-
-#include "m3math.h"
-#include "v3dmath.h"
-
-#include "llphysicsmotion.h"
-#include "llcharacter.h"
-#include "llviewercontrol.h"
-#include "llviewervisualparam.h"
-#include "llvoavatarself.h"
-
-typedef std::map<std::string, std::string> controller_map_t;
-typedef std::map<std::string, F32> default_controller_map_t;
-
-#define MIN_REQUIRED_PIXEL_AREA_BREAST_MOTION 0.f;
-
-inline F64 llsgn(const F64 a)
-{
- if (a >= 0)
- return 1;
- return -1;
-}
-
-/*
- At a high level, this works by setting temporary parameters that are not stored
- in the avatar's list of params, and are not conveyed to other users. We accomplish
- this by creating some new temporary driven params inside avatar_lad that are then driven
- by the actual params that the user sees and sets. For example, in the old system,
- the user sets a param called breast bouyancy, which controls the Z value of the breasts.
- In our new system, the user still sets the breast bouyancy, but that param is redefined
- as a driver param so that affects a new temporary driven param that the bounce is applied
- to.
-*/
-
-class LLPhysicsMotion
-{
-public:
- /*
- param_driver_name: The param that controls the params that are being affected by the physics.
- joint_name: The joint that the body part is attached to. The joint is
- used to determine the orientation (rotation) of the body part.
-
- character: The avatar that this physics affects.
-
- motion_direction_vec: The direction (in world coordinates) that determines the
- motion. For example, (0,0,1) is up-down, and means that up-down motion is what
- determines how this joint moves.
-
- controllers: The various settings (e.g. spring force, mass) that determine how
- the body part behaves.
- */
- LLPhysicsMotion(const std::string &param_driver_name,
- const std::string &joint_name,
- LLCharacter *character,
- const LLVector3 &motion_direction_vec,
- const controller_map_t &controllers) :
- mParamDriverName(param_driver_name),
- mJointName(joint_name),
- mMotionDirectionVec(motion_direction_vec),
- mParamDriver(NULL),
- mParamControllers(controllers),
- mCharacter(character),
- mLastTime(0),
- mPosition_local(0),
- mVelocityJoint_local(0),
- mPositionLastUpdate_local(0)
- {
- mJointState = new LLJointState;
- }
-
- BOOL initialize();
-
- ~LLPhysicsMotion() {}
-
- BOOL onUpdate(F32 time);
-
- LLPointer<LLJointState> getJointState()
- {
- return mJointState;
- }
-protected:
- F32 getParamValue(const std::string& controller_key)
- {
- const controller_map_t::const_iterator& entry = mParamControllers.find(controller_key);
- if (entry == mParamControllers.end())
- {
- return sDefaultController[controller_key];
- }
- const std::string& param_name = (*entry).second.c_str();
- return mCharacter->getVisualParamWeight(param_name.c_str());
- }
- void setParamValue(LLViewerVisualParam *param,
- const F32 new_value_local);
-
- F32 toLocal(const LLVector3 &world);
- F32 calculateVelocity_local(const F32 time_delta);
- F32 calculateAcceleration_local(F32 velocity_local,
- const F32 time_delta);
-private:
- const std::string mParamDriverName;
- const std::string mParamControllerName;
- const LLVector3 mMotionDirectionVec;
- const std::string mJointName;
-
- F32 mPosition_local;
- F32 mVelocityJoint_local; // How fast the joint is moving
- F32 mAccelerationJoint_local; // Acceleration on the joint
-
- F32 mVelocity_local; // How fast the param is moving
- F32 mPositionLastUpdate_local;
- LLVector3 mPosition_world;
-
- LLViewerVisualParam *mParamDriver;
- const controller_map_t mParamControllers;
-
- LLPointer<LLJointState> mJointState;
- LLCharacter *mCharacter;
-
- F32 mLastTime;
-
- static default_controller_map_t sDefaultController;
-};
-
-default_controller_map_t initDefaultController()
-{
- default_controller_map_t controller;
- controller["Mass"] = 0.2f;
- controller["Gravity"] = 0.0f;
- controller["Damping"] = .05f;
- controller["Drag"] = 0.15f;
- controller["MaxEffect"] = 0.1f;
- controller["Spring"] = 0.1f;
- controller["Gain"] = 10.0f;
- return controller;
-}
-
-default_controller_map_t LLPhysicsMotion::sDefaultController = initDefaultController();
-
-BOOL LLPhysicsMotion::initialize()
-{
- if (!mJointState->setJoint(mCharacter->getJoint(mJointName.c_str())))
- return FALSE;
- mJointState->setUsage(LLJointState::ROT);
-
- mParamDriver = (LLViewerVisualParam*)mCharacter->getVisualParam(mParamDriverName.c_str());
- if (mParamDriver == NULL)
- {
- llinfos << "Failure reading in [ " << mParamDriverName << " ]" << llendl;
- return FALSE;
- }
-
- return TRUE;
-}
-
-LLPhysicsMotionController::LLPhysicsMotionController(const LLUUID &id) :
- LLMotion(id),
- mCharacter(NULL)
-{
- mName = "breast_motion";
-}
-
-LLPhysicsMotionController::~LLPhysicsMotionController()
-{
- for (motion_vec_t::iterator iter = mMotions.begin();
- iter != mMotions.end();
- ++iter)
- {
- delete (*iter);
- }
-}
-
-BOOL LLPhysicsMotionController::onActivate()
-{
- return TRUE;
-}
-
-void LLPhysicsMotionController::onDeactivate()
-{
-}
-
-LLMotion::LLMotionInitStatus LLPhysicsMotionController::onInitialize(LLCharacter *character)
-{
- mCharacter = character;
-
- mMotions.clear();
-
- // Breast Cleavage
- {
- controller_map_t controller;
- controller["Mass"] = "Breast_Physics_Mass";
- controller["Gravity"] = "Breast_Physics_Gravity";
- controller["Drag"] = "Breast_Physics_Drag";
- controller["Damping"] = "Breast_Physics_InOut_Damping";
- controller["MaxEffect"] = "Breast_Physics_InOut_Max_Effect";
- controller["Spring"] = "Breast_Physics_InOut_Spring";
- controller["Gain"] = "Breast_Physics_InOut_Gain";
- LLPhysicsMotion *motion = new LLPhysicsMotion("Breast_Physics_InOut_Controller",
- "mChest",
- character,
- LLVector3(-1,0,0),
- controller);
- if (!motion->initialize())
- {
- llassert_always(FALSE);
- return STATUS_FAILURE;
- }
- addMotion(motion);
- }
-
- // Breast Bounce
- {
- controller_map_t controller;
- controller["Mass"] = "Breast_Physics_Mass";
- controller["Gravity"] = "Breast_Physics_Gravity";
- controller["Drag"] = "Breast_Physics_Drag";
- controller["Damping"] = "Breast_Physics_UpDown_Damping";
- controller["MaxEffect"] = "Breast_Physics_UpDown_Max_Effect";
- controller["Spring"] = "Breast_Physics_UpDown_Spring";
- controller["Gain"] = "Breast_Physics_UpDown_Gain";
- LLPhysicsMotion *motion = new LLPhysicsMotion("Breast_Physics_UpDown_Controller",
- "mChest",
- character,
- LLVector3(0,0,1),
- controller);
- if (!motion->initialize())
- {
- llassert_always(FALSE);
- return STATUS_FAILURE;
- }
- addMotion(motion);
- }
-
- // Breast Sway
- {
- controller_map_t controller;
- controller["Mass"] = "Breast_Physics_Mass";
- controller["Gravity"] = "Breast_Physics_Gravity";
- controller["Drag"] = "Breast_Physics_Drag";
- controller["Damping"] = "Breast_Physics_LeftRight_Damping";
- controller["MaxEffect"] = "Breast_Physics_LeftRight_Max_Effect";
- controller["Spring"] = "Breast_Physics_LeftRight_Spring";
- controller["Gain"] = "Breast_Physics_LeftRight_Gain";
- LLPhysicsMotion *motion = new LLPhysicsMotion("Breast_Physics_LeftRight_Controller",
- "mChest",
- character,
- LLVector3(0,-1,0),
- controller);
- if (!motion->initialize())
- {
- llassert_always(FALSE);
- return STATUS_FAILURE;
- }
- addMotion(motion);
- }
- // Butt Bounce
- {
- controller_map_t controller;
- controller["Mass"] = "Butt_Physics_Mass";
- controller["Gravity"] = "Butt_Physics_Gravity";
- controller["Drag"] = "Butt_Physics_Drag";
- controller["Damping"] = "Butt_Physics_UpDown_Damping";
- controller["MaxEffect"] = "Butt_Physics_UpDown_Max_Effect";
- controller["Spring"] = "Butt_Physics_UpDown_Spring";
- controller["Gain"] = "Butt_Physics_UpDown_Gain";
- LLPhysicsMotion *motion = new LLPhysicsMotion("Butt_Physics_UpDown_Controller",
- "mPelvis",
- character,
- LLVector3(0,0,-1),
- controller);
- if (!motion->initialize())
- {
- llassert_always(FALSE);
- return STATUS_FAILURE;
- }
- addMotion(motion);
- }
-
- // Butt LeftRight
- {
- controller_map_t controller;
- controller["Mass"] = "Butt_Physics_Mass";
- controller["Gravity"] = "Butt_Physics_Gravity";
- controller["Drag"] = "Butt_Physics_Drag";
- controller["Damping"] = "Butt_Physics_LeftRight_Damping";
- controller["MaxEffect"] = "Butt_Physics_LeftRight_Max_Effect";
- controller["Spring"] = "Butt_Physics_LeftRight_Spring";
- controller["Gain"] = "Butt_Physics_LeftRight_Gain";
- LLPhysicsMotion *motion = new LLPhysicsMotion("Butt_Physics_LeftRight_Controller",
- "mPelvis",
- character,
- LLVector3(0,-1,0),
- controller);
- if (!motion->initialize())
- {
- llassert_always(FALSE);
- return STATUS_FAILURE;
- }
- addMotion(motion);
- }
-
- // Belly Bounce
- {
- controller_map_t controller;
- controller["Mass"] = "Belly_Physics_Mass";
- controller["Gravity"] = "Belly_Physics_Gravity";
- controller["Drag"] = "Belly_Physics_Drag";
- controller["Damping"] = "Belly_Physics_UpDown_Damping";
- controller["MaxEffect"] = "Belly_Physics_UpDown_Max_Effect";
- controller["Spring"] = "Belly_Physics_UpDown_Spring";
- controller["Gain"] = "Belly_Physics_UpDown_Gain";
- LLPhysicsMotion *motion = new LLPhysicsMotion("Belly_Physics_UpDown_Controller",
- "mPelvis",
- character,
- LLVector3(0,0,-1),
- controller);
- if (!motion->initialize())
- {
- llassert_always(FALSE);
- return STATUS_FAILURE;
- }
- addMotion(motion);
- }
-
- return STATUS_SUCCESS;
-}
-
-void LLPhysicsMotionController::addMotion(LLPhysicsMotion *motion)
-{
- addJointState(motion->getJointState());
- mMotions.push_back(motion);
-}
-
-F32 LLPhysicsMotionController::getMinPixelArea()
-{
- return MIN_REQUIRED_PIXEL_AREA_BREAST_MOTION;
-}
-
-// Local space means "parameter space".
-F32 LLPhysicsMotion::toLocal(const LLVector3 &world)
-{
- LLJoint *joint = mJointState->getJoint();
- const LLQuaternion rotation_world = joint->getWorldRotation();
-
- LLVector3 dir_world = mMotionDirectionVec * rotation_world;
- dir_world.normalize();
- return world * dir_world;
-}
-
-F32 LLPhysicsMotion::calculateVelocity_local(const F32 time_delta)
-{
- LLJoint *joint = mJointState->getJoint();
- const LLVector3 position_world = joint->getWorldPosition();
- const LLQuaternion rotation_world = joint->getWorldRotation();
- const LLVector3 last_position_world = mPosition_world;
- const LLVector3 velocity_world = (position_world-last_position_world) / time_delta;
- const F32 velocity_local = toLocal(velocity_world);
- return velocity_local;
-}
-
-F32 LLPhysicsMotion::calculateAcceleration_local(const F32 velocity_local,
- const F32 time_delta)
-{
-// const F32 smoothing = getParamValue("Smoothing");
- static const F32 smoothing = 3.0f; // Removed smoothing param since it's probably not necessary
- const F32 acceleration_local = velocity_local - mVelocityJoint_local;
-
- const F32 smoothed_acceleration_local =
- acceleration_local * 1.0/smoothing +
- mAccelerationJoint_local * (smoothing-1.0)/smoothing;
-
- return smoothed_acceleration_local;
-}
-
-BOOL LLPhysicsMotionController::onUpdate(F32 time, U8* joint_mask)
-{
- // Skip if disabled globally.
- if (!gSavedSettings.getBOOL("AvatarPhysics"))
- {
- return TRUE;
- }
-
- BOOL update_visuals = FALSE;
- for (motion_vec_t::iterator iter = mMotions.begin();
- iter != mMotions.end();
- ++iter)
- {
- LLPhysicsMotion *motion = (*iter);
- update_visuals |= motion->onUpdate(time);
- }
-
- if (update_visuals)
- mCharacter->updateVisualParams();
-
- return TRUE;
-}
-
-
-// Return TRUE if character has to update visual params.
-BOOL LLPhysicsMotion::onUpdate(F32 time)
-{
- // static FILE *mFileWrite = fopen("c:\\temp\\avatar_data.txt","w");
-
- if (!mParamDriver)
- return FALSE;
-
- if (!mLastTime)
- {
- mLastTime = time;
- return FALSE;
- }
-
- ////////////////////////////////////////////////////////////////////////////////
- // Get all parameters and settings
- //
-
- const F32 time_delta = time - mLastTime;
- if (time_delta > 3.0 || time_delta <= 0.01)
- {
- mLastTime = time;
- return FALSE;
- }
-
- // Higher LOD is better. This controls the granularity
- // and frequency of updates for the motions.
- const F32 lod_factor = LLVOAvatar::sPhysicsLODFactor;
- if (lod_factor == 0)
- {
- return TRUE;
- }
-
- LLJoint *joint = mJointState->getJoint();
-
- const F32 behavior_mass = getParamValue("Mass");
- const F32 behavior_gravity = getParamValue("Gravity");
- const F32 behavior_spring = getParamValue("Spring");
- const F32 behavior_gain = getParamValue("Gain");
- const F32 behavior_damping = getParamValue("Damping");
- const F32 behavior_drag = getParamValue("Drag");
- const BOOL physics_test = gSavedSettings.getBOOL("AvatarPhysicsTest");
-
- F32 behavior_maxeffect = getParamValue("MaxEffect");
- if (physics_test)
- behavior_maxeffect = 1.0f;
- // Maximum effect is [0,1] range.
- const F32 min_val = 0.5f-behavior_maxeffect/2.0;
- const F32 max_val = 0.5f+behavior_maxeffect/2.0;
-
- // mPositon_local should be in normalized 0,1 range already. Just making sure...
- F32 position_current_local = llclamp(mPosition_local,
- 0.0f,
- 1.0f);
-
- // Normalize the param position to be from [0,1].
- // We have to use normalized values because there may be more than one driven param,
- // and each of these driven params may have its own range.
- // This means we'll do all our calculations in normalized [0,1] local coordinates.
- F32 position_user_local = mParamDriver->getWeight();
- position_user_local = (position_user_local - mParamDriver->getMinWeight()) / (mParamDriver->getMaxWeight() - mParamDriver->getMinWeight());
-
- // If the effect is turned off then don't process unless we need one more update
- // to set the position to the default (i.e. user) position.
- if ((behavior_maxeffect == 0) && (position_current_local == position_user_local))
- {
- return FALSE;
- }
-
- //
- // End parameters and settings
- ////////////////////////////////////////////////////////////////////////////////
-
-
- ////////////////////////////////////////////////////////////////////////////////
- // Calculate velocity and acceleration in parameter space.
- //
-
- const F32 velocity_joint_local = calculateVelocity_local(time_delta);
- const F32 acceleration_joint_local = calculateAcceleration_local(velocity_joint_local, time_delta);
-
- //
- // End velocity and acceleration
- ////////////////////////////////////////////////////////////////////////////////
-
-
- ////////////////////////////////////////////////////////////////////////////////
- // Calculate the total force
- //
-
- // Spring force is a restoring force towards the original user-set breast position.
- // F = kx
- const F32 spring_length = position_current_local - position_user_local;
- const F32 force_spring = -spring_length * behavior_spring;
-
- // Acceleration is the force that comes from the change in velocity of the torso.
- // F = ma
- const F32 force_accel = behavior_gain * (acceleration_joint_local * behavior_mass);
-
- // Gravity always points downward in world space.
- // F = mg
- const LLVector3 gravity_world(0,0,1);
- const F32 force_gravity = behavior_gain * (toLocal(gravity_world) * behavior_gravity * behavior_mass);
-
- // Damping is a restoring force that opposes the current velocity.
- // F = -kv
- const F32 force_damping = -behavior_damping * mVelocity_local;
-
- // Drag is a force imparted by velocity (intuitively it is similar to wind resistance)
- // F = .5kv^2
- const F32 force_drag = .5*behavior_drag*velocity_joint_local*velocity_joint_local*llsgn(velocity_joint_local);
-
- const F32 force_net = (force_accel +
- force_gravity +
- force_spring +
- force_damping +
- force_drag);
-
- //
- // End total force
- ////////////////////////////////////////////////////////////////////////////////
-
-
- ////////////////////////////////////////////////////////////////////////////////
- // Calculate new params
- //
-
- // Calculate the new acceleration based on the net force.
- // a = F/m
- const F32 acceleration_new_local = force_net / behavior_mass;
- static const F32 max_acceleration = 10.0f; // magic number, used to be customizable.
- F32 velocity_new_local = mVelocity_local + acceleration_new_local;
- velocity_new_local = llclamp(velocity_new_local,
- -max_acceleration, max_acceleration);
-
- // Temporary debugging setting to cause all avatars to move, for profiling purposes.
- if (physics_test)
- {
- velocity_new_local = sin(time*4.0);
- }
- // Calculate the new parameters, or remain unchanged if max speed is 0.
- F32 position_new_local = position_current_local + velocity_new_local*time_delta;
- if (behavior_maxeffect == 0)
- position_new_local = position_user_local;
-
- // Zero out the velocity if the param is being pushed beyond its limits.
- if ((position_new_local < min_val && velocity_new_local < 0) ||
- (position_new_local > max_val && velocity_new_local > 0))
- {
- velocity_new_local = 0;
- }
-
- const F32 position_new_local_clamped = llclamp(position_new_local,
- min_val,
- max_val);
-
- LLDriverParam *driver_param = dynamic_cast<LLDriverParam *>(mParamDriver);
- llassert_always(driver_param);
- if (driver_param)
- {
- // If this is one of our "hidden" driver params, then make sure it's
- // the default value.
- if ((driver_param->getGroup() != VISUAL_PARAM_GROUP_TWEAKABLE) &&
- (driver_param->getGroup() != VISUAL_PARAM_GROUP_TWEAKABLE_NO_TRANSMIT))
- {
- mCharacter->setVisualParamWeight(driver_param,
- 0,
- FALSE);
- }
- for (LLDriverParam::entry_list_t::iterator iter = driver_param->mDriven.begin();
- iter != driver_param->mDriven.end();
- ++iter)
- {
- LLDrivenEntry &entry = (*iter);
- LLViewerVisualParam *driven_param = entry.mParam;
- setParamValue(driven_param,position_new_local_clamped);
- }
- }
-
- //
- // End calculate new params
- ////////////////////////////////////////////////////////////////////////////////
-
- ////////////////////////////////////////////////////////////////////////////////
- // Conditionally update the visual params
- //
-
- // Updating the visual params (i.e. what the user sees) is fairly expensive.
- // So only update if the params have changed enough, and also take into account
- // the graphics LOD settings.
-
- BOOL update_visuals = FALSE;
-
- // For non-self, if the avatar is small enough visually, then don't update.
- const F32 area_for_max_settings = 0.0;
- const F32 area_for_min_settings = 1400.0;
- const F32 area_for_this_setting = area_for_max_settings + (area_for_min_settings-area_for_max_settings)*(1.0-lod_factor);
- const F32 pixel_area = fsqrtf(mCharacter->getPixelArea());
-
- const BOOL is_self = (dynamic_cast<LLVOAvatarSelf *>(mCharacter) != NULL);
- if ((pixel_area > area_for_this_setting) || is_self)
- {
- const F32 position_diff_local = llabs(mPositionLastUpdate_local-position_new_local_clamped);
- const F32 min_delta = (1.01f-lod_factor)*0.4f;
- if (llabs(position_diff_local) > min_delta)
- {
- update_visuals = TRUE;
- mPositionLastUpdate_local = position_new_local;
- }
- }
-
- //
- // End update visual params
- ////////////////////////////////////////////////////////////////////////////////
-
- mVelocityJoint_local = velocity_joint_local;
-
- mVelocity_local = velocity_new_local;
- mAccelerationJoint_local = acceleration_joint_local;
- mPosition_local = position_new_local;
-
- mPosition_world = joint->getWorldPosition();
- mLastTime = time;
-
- /*
- // Write out debugging info into a spreadsheet.
- if (mFileWrite != NULL && is_self)
- {
- fprintf(mFileWrite,"%f\t%f\t%f \t\t%f \t\t%f\t%f\t%f\t \t\t%f\t%f\t%f\t%f\t%f \t\t%f\t%f\t%f\n",
- position_new_local,
- velocity_new_local,
- acceleration_new_local,
-
- time_delta,
-
- mPosition_world[0],
- mPosition_world[1],
- mPosition_world[2],
-
- force_net,
- force_spring,
- force_accel,
- force_damping,
- force_drag,
-
- spring_length,
- velocity_joint_local,
- acceleration_joint_local
- );
- }
- */
-
- return update_visuals;
-}
-
-// Range of new_value_local is assumed to be [0 , 1] normalized.
-void LLPhysicsMotion::setParamValue(LLViewerVisualParam *param,
- F32 new_value_normalized)
-{
- const F32 value_min_local = param->getMinWeight();
- const F32 value_max_local = param->getMaxWeight();
-
- const F32 new_value_local = value_min_local + (value_max_local-value_min_local) * new_value_normalized;
-
- mCharacter->setVisualParamWeight(param,
- new_value_local,
- FALSE);
-}
+/**
+ * @file llphysicsmotion.cpp
+ * @brief Implementation of LLPhysicsMotion class.
+ *
+ * $LicenseInfo:firstyear=2011&license=viewerlgpl$
+ * Second Life Viewer Source Code
+ * Copyright (C) 2011, 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$
+ */
+
+//-----------------------------------------------------------------------------
+// Header Files
+//-----------------------------------------------------------------------------
+#include "llviewerprecompiledheaders.h"
+#include "linden_common.h"
+
+#include "m3math.h"
+#include "v3dmath.h"
+
+#include "llphysicsmotion.h"
+#include "llagent.h"
+#include "llcharacter.h"
+#include "llviewercontrol.h"
+#include "llviewervisualparam.h"
+#include "llvoavatarself.h"
+
+typedef std::map<std::string, std::string> controller_map_t;
+typedef std::map<std::string, F32> default_controller_map_t;
+
+#define MIN_REQUIRED_PIXEL_AREA_BREAST_MOTION 0.f;
+
+inline F64 llsgn(const F64 a)
+{
+ if (a >= 0)
+ return 1;
+ return -1;
+}
+
+/*
+ At a high level, this works by setting temporary parameters that are not stored
+ in the avatar's list of params, and are not conveyed to other users. We accomplish
+ this by creating some new temporary driven params inside avatar_lad that are then driven
+ by the actual params that the user sees and sets. For example, in the old system,
+ the user sets a param called breast bouyancy, which controls the Z value of the breasts.
+ In our new system, the user still sets the breast bouyancy, but that param is redefined
+ as a driver param so that affects a new temporary driven param that the bounce is applied
+ to.
+*/
+
+class LLPhysicsMotion
+{
+public:
+ /*
+ param_driver_name: The param that controls the params that are being affected by the physics.
+ joint_name: The joint that the body part is attached to. The joint is
+ used to determine the orientation (rotation) of the body part.
+
+ character: The avatar that this physics affects.
+
+ motion_direction_vec: The direction (in world coordinates) that determines the
+ motion. For example, (0,0,1) is up-down, and means that up-down motion is what
+ determines how this joint moves.
+
+ controllers: The various settings (e.g. spring force, mass) that determine how
+ the body part behaves.
+ */
+ LLPhysicsMotion(const std::string &param_driver_name,
+ const std::string &joint_name,
+ LLCharacter *character,
+ const LLVector3 &motion_direction_vec,
+ const controller_map_t &controllers) :
+ mParamDriverName(param_driver_name),
+ mJointName(joint_name),
+ mMotionDirectionVec(motion_direction_vec),
+ mParamDriver(NULL),
+ mParamControllers(controllers),
+ mCharacter(character),
+ mLastTime(0),
+ mPosition_local(0),
+ mVelocityJoint_local(0),
+ mPositionLastUpdate_local(0)
+ {
+ mJointState = new LLJointState;
+ }
+
+ BOOL initialize();
+
+ ~LLPhysicsMotion() {}
+
+ BOOL onUpdate(F32 time);
+
+ LLPointer<LLJointState> getJointState()
+ {
+ return mJointState;
+ }
+protected:
+ F32 getParamValue(const std::string& controller_key)
+ {
+ const controller_map_t::const_iterator& entry = mParamControllers.find(controller_key);
+ if (entry == mParamControllers.end())
+ {
+ return sDefaultController[controller_key];
+ }
+ const std::string& param_name = (*entry).second.c_str();
+ return mCharacter->getVisualParamWeight(param_name.c_str());
+ }
+ void setParamValue(LLViewerVisualParam *param,
+ const F32 new_value_local,
+ F32 behavior_maxeffect);
+
+ F32 toLocal(const LLVector3 &world);
+ F32 calculateVelocity_local(const F32 time_delta);
+ F32 calculateAcceleration_local(F32 velocity_local,
+ const F32 time_delta);
+private:
+ const std::string mParamDriverName;
+ const std::string mParamControllerName;
+ const LLVector3 mMotionDirectionVec;
+ const std::string mJointName;
+
+ F32 mPosition_local;
+ F32 mVelocityJoint_local; // How fast the joint is moving
+ F32 mAccelerationJoint_local; // Acceleration on the joint
+
+ F32 mVelocity_local; // How fast the param is moving
+ F32 mPositionLastUpdate_local;
+ LLVector3 mPosition_world;
+
+ LLViewerVisualParam *mParamDriver;
+ const controller_map_t mParamControllers;
+
+ LLPointer<LLJointState> mJointState;
+ LLCharacter *mCharacter;
+
+ F32 mLastTime;
+
+ static default_controller_map_t sDefaultController;
+};
+
+default_controller_map_t initDefaultController()
+{
+ default_controller_map_t controller;
+ controller["Mass"] = 0.2f;
+ controller["Gravity"] = 0.0f;
+ controller["Damping"] = .05f;
+ controller["Drag"] = 0.15f;
+ controller["MaxEffect"] = 0.1f;
+ controller["Spring"] = 0.1f;
+ controller["Gain"] = 10.0f;
+ return controller;
+}
+
+default_controller_map_t LLPhysicsMotion::sDefaultController = initDefaultController();
+
+BOOL LLPhysicsMotion::initialize()
+{
+ if (!mJointState->setJoint(mCharacter->getJoint(mJointName.c_str())))
+ return FALSE;
+ mJointState->setUsage(LLJointState::ROT);
+
+ mParamDriver = (LLViewerVisualParam*)mCharacter->getVisualParam(mParamDriverName.c_str());
+ if (mParamDriver == NULL)
+ {
+ llinfos << "Failure reading in [ " << mParamDriverName << " ]" << llendl;
+ return FALSE;
+ }
+
+ return TRUE;
+}
+
+LLPhysicsMotionController::LLPhysicsMotionController(const LLUUID &id) :
+ LLMotion(id),
+ mCharacter(NULL)
+{
+ mName = "breast_motion";
+}
+
+LLPhysicsMotionController::~LLPhysicsMotionController()
+{
+ for (motion_vec_t::iterator iter = mMotions.begin();
+ iter != mMotions.end();
+ ++iter)
+ {
+ delete (*iter);
+ }
+}
+
+BOOL LLPhysicsMotionController::onActivate()
+{
+ return TRUE;
+}
+
+void LLPhysicsMotionController::onDeactivate()
+{
+}
+
+LLMotion::LLMotionInitStatus LLPhysicsMotionController::onInitialize(LLCharacter *character)
+{
+ mCharacter = character;
+
+ mMotions.clear();
+
+ // Breast Cleavage
+ {
+ controller_map_t controller;
+ controller["Mass"] = "Breast_Physics_Mass";
+ controller["Gravity"] = "Breast_Physics_Gravity";
+ controller["Drag"] = "Breast_Physics_Drag";
+ controller["Damping"] = "Breast_Physics_InOut_Damping";
+ controller["MaxEffect"] = "Breast_Physics_InOut_Max_Effect";
+ controller["Spring"] = "Breast_Physics_InOut_Spring";
+ controller["Gain"] = "Breast_Physics_InOut_Gain";
+ LLPhysicsMotion *motion = new LLPhysicsMotion("Breast_Physics_InOut_Controller",
+ "mChest",
+ character,
+ LLVector3(-1,0,0),
+ controller);
+ if (!motion->initialize())
+ {
+ llassert_always(FALSE);
+ return STATUS_FAILURE;
+ }
+ addMotion(motion);
+ }
+
+ // Breast Bounce
+ {
+ controller_map_t controller;
+ controller["Mass"] = "Breast_Physics_Mass";
+ controller["Gravity"] = "Breast_Physics_Gravity";
+ controller["Drag"] = "Breast_Physics_Drag";
+ controller["Damping"] = "Breast_Physics_UpDown_Damping";
+ controller["MaxEffect"] = "Breast_Physics_UpDown_Max_Effect";
+ controller["Spring"] = "Breast_Physics_UpDown_Spring";
+ controller["Gain"] = "Breast_Physics_UpDown_Gain";
+ LLPhysicsMotion *motion = new LLPhysicsMotion("Breast_Physics_UpDown_Controller",
+ "mChest",
+ character,
+ LLVector3(0,0,1),
+ controller);
+ if (!motion->initialize())
+ {
+ llassert_always(FALSE);
+ return STATUS_FAILURE;
+ }
+ addMotion(motion);
+ }
+
+ // Breast Sway
+ {
+ controller_map_t controller;
+ controller["Mass"] = "Breast_Physics_Mass";
+ controller["Gravity"] = "Breast_Physics_Gravity";
+ controller["Drag"] = "Breast_Physics_Drag";
+ controller["Damping"] = "Breast_Physics_LeftRight_Damping";
+ controller["MaxEffect"] = "Breast_Physics_LeftRight_Max_Effect";
+ controller["Spring"] = "Breast_Physics_LeftRight_Spring";
+ controller["Gain"] = "Breast_Physics_LeftRight_Gain";
+ LLPhysicsMotion *motion = new LLPhysicsMotion("Breast_Physics_LeftRight_Controller",
+ "mChest",
+ character,
+ LLVector3(0,-1,0),
+ controller);
+ if (!motion->initialize())
+ {
+ llassert_always(FALSE);
+ return STATUS_FAILURE;
+ }
+ addMotion(motion);
+ }
+ // Butt Bounce
+ {
+ controller_map_t controller;
+ controller["Mass"] = "Butt_Physics_Mass";
+ controller["Gravity"] = "Butt_Physics_Gravity";
+ controller["Drag"] = "Butt_Physics_Drag";
+ controller["Damping"] = "Butt_Physics_UpDown_Damping";
+ controller["MaxEffect"] = "Butt_Physics_UpDown_Max_Effect";
+ controller["Spring"] = "Butt_Physics_UpDown_Spring";
+ controller["Gain"] = "Butt_Physics_UpDown_Gain";
+ LLPhysicsMotion *motion = new LLPhysicsMotion("Butt_Physics_UpDown_Controller",
+ "mPelvis",
+ character,
+ LLVector3(0,0,-1),
+ controller);
+ if (!motion->initialize())
+ {
+ llassert_always(FALSE);
+ return STATUS_FAILURE;
+ }
+ addMotion(motion);
+ }
+
+ // Butt LeftRight
+ {
+ controller_map_t controller;
+ controller["Mass"] = "Butt_Physics_Mass";
+ controller["Gravity"] = "Butt_Physics_Gravity";
+ controller["Drag"] = "Butt_Physics_Drag";
+ controller["Damping"] = "Butt_Physics_LeftRight_Damping";
+ controller["MaxEffect"] = "Butt_Physics_LeftRight_Max_Effect";
+ controller["Spring"] = "Butt_Physics_LeftRight_Spring";
+ controller["Gain"] = "Butt_Physics_LeftRight_Gain";
+ LLPhysicsMotion *motion = new LLPhysicsMotion("Butt_Physics_LeftRight_Controller",
+ "mPelvis",
+ character,
+ LLVector3(0,-1,0),
+ controller);
+ if (!motion->initialize())
+ {
+ llassert_always(FALSE);
+ return STATUS_FAILURE;
+ }
+ addMotion(motion);
+ }
+
+ // Belly Bounce
+ {
+ controller_map_t controller;
+ controller["Mass"] = "Belly_Physics_Mass";
+ controller["Gravity"] = "Belly_Physics_Gravity";
+ controller["Drag"] = "Belly_Physics_Drag";
+ controller["Damping"] = "Belly_Physics_UpDown_Damping";
+ controller["MaxEffect"] = "Belly_Physics_UpDown_Max_Effect";
+ controller["Spring"] = "Belly_Physics_UpDown_Spring";
+ controller["Gain"] = "Belly_Physics_UpDown_Gain";
+ LLPhysicsMotion *motion = new LLPhysicsMotion("Belly_Physics_UpDown_Controller",
+ "mPelvis",
+ character,
+ LLVector3(0,0,-1),
+ controller);
+ if (!motion->initialize())
+ {
+ llassert_always(FALSE);
+ return STATUS_FAILURE;
+ }
+ addMotion(motion);
+ }
+
+ return STATUS_SUCCESS;
+}
+
+void LLPhysicsMotionController::addMotion(LLPhysicsMotion *motion)
+{
+ addJointState(motion->getJointState());
+ mMotions.push_back(motion);
+}
+
+F32 LLPhysicsMotionController::getMinPixelArea()
+{
+ return MIN_REQUIRED_PIXEL_AREA_BREAST_MOTION;
+}
+
+// Local space means "parameter space".
+F32 LLPhysicsMotion::toLocal(const LLVector3 &world)
+{
+ LLJoint *joint = mJointState->getJoint();
+ const LLQuaternion rotation_world = joint->getWorldRotation();
+
+ LLVector3 dir_world = mMotionDirectionVec * rotation_world;
+ dir_world.normalize();
+ return world * dir_world;
+}
+
+F32 LLPhysicsMotion::calculateVelocity_local(const F32 time_delta)
+{
+ LLJoint *joint = mJointState->getJoint();
+ const LLVector3 position_world = joint->getWorldPosition();
+ const LLQuaternion rotation_world = joint->getWorldRotation();
+ const LLVector3 last_position_world = mPosition_world;
+ const LLVector3 velocity_world = (position_world-last_position_world) / time_delta;
+ const F32 velocity_local = toLocal(velocity_world);
+ return velocity_local;
+}
+
+F32 LLPhysicsMotion::calculateAcceleration_local(const F32 velocity_local,
+ const F32 time_delta)
+{
+// const F32 smoothing = getParamValue("Smoothing");
+ static const F32 smoothing = 3.0f; // Removed smoothing param since it's probably not necessary
+ const F32 acceleration_local = velocity_local - mVelocityJoint_local;
+
+ const F32 smoothed_acceleration_local =
+ acceleration_local * 1.0/smoothing +
+ mAccelerationJoint_local * (smoothing-1.0)/smoothing;
+
+ return smoothed_acceleration_local;
+}
+
+BOOL LLPhysicsMotionController::onUpdate(F32 time, U8* joint_mask)
+{
+ // Skip if disabled globally.
+ if (!gSavedSettings.getBOOL("AvatarPhysics"))
+ {
+ return TRUE;
+ }
+
+ BOOL update_visuals = FALSE;
+ for (motion_vec_t::iterator iter = mMotions.begin();
+ iter != mMotions.end();
+ ++iter)
+ {
+ LLPhysicsMotion *motion = (*iter);
+ update_visuals |= motion->onUpdate(time);
+ }
+
+ if (update_visuals)
+ mCharacter->updateVisualParams();
+
+ return TRUE;
+}
+
+
+// Return TRUE if character has to update visual params.
+BOOL LLPhysicsMotion::onUpdate(F32 time)
+{
+ // static FILE *mFileWrite = fopen("c:\\temp\\avatar_data.txt","w");
+
+ if (!mParamDriver)
+ return FALSE;
+
+ if (!mLastTime)
+ {
+ mLastTime = time;
+ return FALSE;
+ }
+
+ ////////////////////////////////////////////////////////////////////////////////
+ // Get all parameters and settings
+ //
+
+ const F32 time_delta = time - mLastTime;
+ if (time_delta > 3.0 || time_delta <= 0.01)
+ {
+ mLastTime = time;
+ return FALSE;
+ }
+
+ // Higher LOD is better. This controls the granularity
+ // and frequency of updates for the motions.
+ const F32 lod_factor = LLVOAvatar::sPhysicsLODFactor;
+ if (lod_factor == 0)
+ {
+ return TRUE;
+ }
+
+ LLJoint *joint = mJointState->getJoint();
+
+ const F32 behavior_mass = getParamValue("Mass");
+ const F32 behavior_gravity = getParamValue("Gravity");
+ const F32 behavior_spring = getParamValue("Spring");
+ const F32 behavior_gain = getParamValue("Gain");
+ const F32 behavior_damping = getParamValue("Damping");
+ const F32 behavior_drag = getParamValue("Drag");
+ const BOOL physics_test = gSavedSettings.getBOOL("AvatarPhysicsTest") && gAgent.isGodlike();
+
+ F32 behavior_maxeffect = getParamValue("MaxEffect");
+ if (physics_test)
+ behavior_maxeffect = 1.0f;
+
+ // mPositon_local should be in normalized 0,1 range already. Just making sure...
+ F32 position_current_local = llclamp(mPosition_local,
+ 0.0f,
+ 1.0f);
+
+ // Normalize the param position to be from [0,1].
+ // We have to use normalized values because there may be more than one driven param,
+ // and each of these driven params may have its own range.
+ // This means we'll do all our calculations in normalized [0,1] local coordinates.
+ F32 position_user_local = mParamDriver->getWeight();
+ position_user_local = (position_user_local - mParamDriver->getMinWeight()) / (mParamDriver->getMaxWeight() - mParamDriver->getMinWeight());
+
+ // If the effect is turned off then don't process unless we need one more update
+ // to set the position to the default (i.e. user) position.
+ if ((behavior_maxeffect == 0) && (position_current_local == position_user_local))
+ {
+ return FALSE;
+ }
+
+ //
+ // End parameters and settings
+ ////////////////////////////////////////////////////////////////////////////////
+
+
+ ////////////////////////////////////////////////////////////////////////////////
+ // Calculate velocity and acceleration in parameter space.
+ //
+
+ const F32 velocity_joint_local = calculateVelocity_local(time_delta);
+ const F32 acceleration_joint_local = calculateAcceleration_local(velocity_joint_local, time_delta);
+
+ //
+ // End velocity and acceleration
+ ////////////////////////////////////////////////////////////////////////////////
+
+
+ ////////////////////////////////////////////////////////////////////////////////
+ // Calculate the total force
+ //
+
+ // Spring force is a restoring force towards the original user-set breast position.
+ // F = kx
+ const F32 spring_length = position_current_local - position_user_local;
+ const F32 force_spring = -spring_length * behavior_spring;
+
+ // Acceleration is the force that comes from the change in velocity of the torso.
+ // F = ma
+ const F32 force_accel = behavior_gain * (acceleration_joint_local * behavior_mass);
+
+ // Gravity always points downward in world space.
+ // F = mg
+ const LLVector3 gravity_world(0,0,1);
+ const F32 force_gravity = behavior_gain * (toLocal(gravity_world) * behavior_gravity * behavior_mass);
+
+ // Damping is a restoring force that opposes the current velocity.
+ // F = -kv
+ const F32 force_damping = -behavior_damping * mVelocity_local;
+
+ // Drag is a force imparted by velocity (intuitively it is similar to wind resistance)
+ // F = .5kv^2
+ const F32 force_drag = .5*behavior_drag*velocity_joint_local*velocity_joint_local*llsgn(velocity_joint_local);
+
+ const F32 force_net = (force_accel +
+ force_gravity +
+ force_spring +
+ force_damping +
+ force_drag);
+
+ //
+ // End total force
+ ////////////////////////////////////////////////////////////////////////////////
+
+
+ ////////////////////////////////////////////////////////////////////////////////
+ // Calculate new params
+ //
+
+ // Calculate the new acceleration based on the net force.
+ // a = F/m
+ const F32 acceleration_new_local = force_net / behavior_mass;
+ static const F32 max_acceleration = 10.0f; // magic number, used to be customizable.
+ F32 velocity_new_local = mVelocity_local + acceleration_new_local;
+ velocity_new_local = llclamp(velocity_new_local,
+ -max_acceleration, max_acceleration);
+
+ // Temporary debugging setting to cause all avatars to move, for profiling purposes.
+ if (physics_test)
+ {
+ velocity_new_local = sin(time*4.0);
+ }
+ // Calculate the new parameters, or remain unchanged if max speed is 0.
+ F32 position_new_local = position_current_local + velocity_new_local*time_delta;
+ if (behavior_maxeffect == 0)
+ position_new_local = position_user_local;
+
+ // Zero out the velocity if the param is being pushed beyond its limits.
+ if ((position_new_local < 0 && velocity_new_local < 0) ||
+ (position_new_local > 1 && velocity_new_local > 0))
+ {
+ velocity_new_local = 0;
+ }
+
+ // Check for NaN values. A NaN value is detected if the variables doesn't equal itself.
+ // If NaN, then reset everything.
+ if ((mPosition_local != mPosition_local) ||
+ (mVelocity_local != mVelocity_local) ||
+ (position_new_local != position_new_local))
+ {
+ position_new_local = 0;
+ position_current_local = 0;
+ position_user_local = 0;
+ mVelocity_local = 0;
+ mVelocityJoint_local = 0;
+ mAccelerationJoint_local = 0;
+ mPosition_local = 0;
+ mPosition_world = LLVector3(0,0,0);
+ }
+
+ const F32 position_new_local_clamped = llclamp(position_new_local,
+ 0.0f,
+ 1.0f);
+
+ LLDriverParam *driver_param = dynamic_cast<LLDriverParam *>(mParamDriver);
+ llassert_always(driver_param);
+ if (driver_param)
+ {
+ // If this is one of our "hidden" driver params, then make sure it's
+ // the default value.
+ if ((driver_param->getGroup() != VISUAL_PARAM_GROUP_TWEAKABLE) &&
+ (driver_param->getGroup() != VISUAL_PARAM_GROUP_TWEAKABLE_NO_TRANSMIT))
+ {
+ mCharacter->setVisualParamWeight(driver_param,
+ 0,
+ FALSE);
+ }
+ for (LLDriverParam::entry_list_t::iterator iter = driver_param->mDriven.begin();
+ iter != driver_param->mDriven.end();
+ ++iter)
+ {
+ LLDrivenEntry &entry = (*iter);
+ LLViewerVisualParam *driven_param = entry.mParam;
+ setParamValue(driven_param,position_new_local_clamped, behavior_maxeffect);
+ }
+ }
+
+ //
+ // End calculate new params
+ ////////////////////////////////////////////////////////////////////////////////
+
+ ////////////////////////////////////////////////////////////////////////////////
+ // Conditionally update the visual params
+ //
+
+ // Updating the visual params (i.e. what the user sees) is fairly expensive.
+ // So only update if the params have changed enough, and also take into account
+ // the graphics LOD settings.
+
+ BOOL update_visuals = FALSE;
+
+ // For non-self, if the avatar is small enough visually, then don't update.
+ const F32 area_for_max_settings = 0.0;
+ const F32 area_for_min_settings = 1400.0;
+ const F32 area_for_this_setting = area_for_max_settings + (area_for_min_settings-area_for_max_settings)*(1.0-lod_factor);
+ const F32 pixel_area = fsqrtf(mCharacter->getPixelArea());
+
+ const BOOL is_self = (dynamic_cast<LLVOAvatarSelf *>(mCharacter) != NULL);
+ if ((pixel_area > area_for_this_setting) || is_self)
+ {
+ const F32 position_diff_local = llabs(mPositionLastUpdate_local-position_new_local_clamped);
+ const F32 min_delta = (1.01f-lod_factor)*0.4f;
+ if (llabs(position_diff_local) > min_delta)
+ {
+ update_visuals = TRUE;
+ mPositionLastUpdate_local = position_new_local;
+ }
+ }
+
+ //
+ // End update visual params
+ ////////////////////////////////////////////////////////////////////////////////
+
+ mVelocityJoint_local = velocity_joint_local;
+
+ mVelocity_local = velocity_new_local;
+ mAccelerationJoint_local = acceleration_joint_local;
+ mPosition_local = position_new_local;
+
+ mPosition_world = joint->getWorldPosition();
+ mLastTime = time;
+
+ /*
+ // Write out debugging info into a spreadsheet.
+ if (mFileWrite != NULL && is_self)
+ {
+ fprintf(mFileWrite,"%f\t%f\t%f \t\t%f \t\t%f\t%f\t%f\t \t\t%f\t%f\t%f\t%f\t%f \t\t%f\t%f\t%f\n",
+ position_new_local,
+ velocity_new_local,
+ acceleration_new_local,
+
+ time_delta,
+
+ mPosition_world[0],
+ mPosition_world[1],
+ mPosition_world[2],
+
+ force_net,
+ force_spring,
+ force_accel,
+ force_damping,
+ force_drag,
+
+ spring_length,
+ velocity_joint_local,
+ acceleration_joint_local
+ );
+ }
+ */
+
+ return update_visuals;
+}
+
+// Range of new_value_local is assumed to be [0 , 1] normalized.
+void LLPhysicsMotion::setParamValue(LLViewerVisualParam *param,
+ F32 new_value_normalized,
+ F32 behavior_maxeffect)
+{
+ const F32 value_min_local = param->getMinWeight();
+ const F32 value_max_local = param->getMaxWeight();
+ const F32 min_val = 0.5f-behavior_maxeffect/2.0;
+ const F32 max_val = 0.5f+behavior_maxeffect/2.0;
+
+ // Scale from [0,1] to [min_val,max_val]
+ const F32 new_value_rescaled = min_val + (max_val-min_val) * new_value_normalized;
+
+ // Scale from [0,1] to [value_min_local,value_max_local]
+ const F32 new_value_local = value_min_local + (value_max_local-value_min_local) * new_value_rescaled;
+
+ mCharacter->setVisualParamWeight(param,
+ new_value_local,
+ FALSE);
+}
diff --git a/indra/newview/llphysicsmotion.h b/indra/newview/llphysicsmotion.h
index 0c0087d269..b246fa99bb 100644
--- a/indra/newview/llphysicsmotion.h
+++ b/indra/newview/llphysicsmotion.h
@@ -1,124 +1,118 @@
-/**
- * @file llphysicsmotion.h
- * @brief Implementation of LLPhysicsMotion class.
- *
- * $LicenseInfo:firstyear=2001&license=viewergpl$
- *
- * Copyright (c) 2001-2009, Linden Research, Inc.
- *
- * Second Life Viewer Source Code
- * The source code in this file ("Source Code") is provided by Linden Lab
- * to you under the terms of the GNU General Public License, version 2.0
- * ("GPL"), unless you have obtained a separate licensing agreement
- * ("Other License"), formally executed by you and Linden Lab. Terms of
- * the GPL can be found in doc/GPL-license.txt in this distribution, or
- * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
- *
- * There are special exceptions to the terms and conditions of the GPL as
- * it is applied to this Source Code. View the full text of the exception
- * in the file doc/FLOSS-exception.txt in this software distribution, or
- * online at
- * http://secondlifegrid.net/programs/open_source/licensing/flossexception
- *
- * By copying, modifying or distributing this software, you acknowledge
- * that you have read and understood your obligations described above,
- * and agree to abide by those obligations.
- *
- * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
- * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
- * COMPLETENESS OR PERFORMANCE.
- * $/LicenseInfo$
- */
-
-#ifndef LL_LLPHYSICSMOTIONCONTROLLER_H
-#define LL_LLPHYSICSMOTIONCONTROLLER_H
-
-//-----------------------------------------------------------------------------
-// Header files
-//-----------------------------------------------------------------------------
-#include "llmotion.h"
-#include "llframetimer.h"
-
-#define PHYSICS_MOTION_FADEIN_TIME 1.0f
-#define PHYSICS_MOTION_FADEOUT_TIME 1.0f
-
-class LLPhysicsMotion;
-
-//-----------------------------------------------------------------------------
-// class LLPhysicsMotion
-//-----------------------------------------------------------------------------
-class LLPhysicsMotionController :
- public LLMotion
-{
-public:
- // Constructor
- LLPhysicsMotionController(const LLUUID &id);
-
- // Destructor
- virtual ~LLPhysicsMotionController();
-
-public:
- //-------------------------------------------------------------------------
- // functions to support MotionController and MotionRegistry
- //-------------------------------------------------------------------------
-
- // static constructor
- // all subclasses must implement such a function and register it
- static LLMotion *create(const LLUUID &id) { return new LLPhysicsMotionController(id); }
-
-public:
- //-------------------------------------------------------------------------
- // animation callbacks to be implemented by subclasses
- //-------------------------------------------------------------------------
-
- // motions must specify whether or not they loop
- virtual BOOL getLoop() { return TRUE; }
-
- // motions must report their total duration
- virtual F32 getDuration() { return 0.0; }
-
- // motions must report their "ease in" duration
- virtual F32 getEaseInDuration() { return PHYSICS_MOTION_FADEIN_TIME; }
-
- // motions must report their "ease out" duration.
- virtual F32 getEaseOutDuration() { return PHYSICS_MOTION_FADEOUT_TIME; }
-
- // called to determine when a motion should be activated/deactivated based on avatar pixel coverage
- virtual F32 getMinPixelArea();
-
- // motions must report their priority
- virtual LLJoint::JointPriority getPriority() { return LLJoint::MEDIUM_PRIORITY; }
-
- virtual LLMotionBlendType getBlendType() { return ADDITIVE_BLEND; }
-
- // run-time (post constructor) initialization,
- // called after parameters have been set
- // must return true to indicate success and be available for activation
- virtual LLMotionInitStatus onInitialize(LLCharacter *character);
-
- // called when a motion is activated
- // must return TRUE to indicate success, or else
- // it will be deactivated
- virtual BOOL onActivate();
-
- // called per time step
- // must return TRUE while it is active, and
- // must return FALSE when the motion is completed.
- virtual BOOL onUpdate(F32 time, U8* joint_mask);
-
- // called when a motion is deactivated
- virtual void onDeactivate();
-
- LLCharacter* getCharacter() { return mCharacter; }
-
-protected:
- void addMotion(LLPhysicsMotion *motion);
-private:
- LLCharacter* mCharacter;
-
- typedef std::vector<LLPhysicsMotion *> motion_vec_t;
- motion_vec_t mMotions;
-};
-
-#endif // LL_LLPHYSICSMOTION_H
-
+/**
+ * @file llphysicsmotion.h
+ * @brief Implementation of LLPhysicsMotion class.
+ *
+ * $LicenseInfo:firstyear=2011&license=viewerlgpl$
+ * Second Life Viewer Source Code
+ * Copyright (C) 2011, 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_LLPHYSICSMOTIONCONTROLLER_H
+#define LL_LLPHYSICSMOTIONCONTROLLER_H
+
+//-----------------------------------------------------------------------------
+// Header files
+//-----------------------------------------------------------------------------
+#include "llmotion.h"
+#include "llframetimer.h"
+
+#define PHYSICS_MOTION_FADEIN_TIME 1.0f
+#define PHYSICS_MOTION_FADEOUT_TIME 1.0f
+
+class LLPhysicsMotion;
+
+//-----------------------------------------------------------------------------
+// class LLPhysicsMotion
+//-----------------------------------------------------------------------------
+class LLPhysicsMotionController :
+ public LLMotion
+{
+public:
+ // Constructor
+ LLPhysicsMotionController(const LLUUID &id);
+
+ // Destructor
+ virtual ~LLPhysicsMotionController();
+
+public:
+ //-------------------------------------------------------------------------
+ // functions to support MotionController and MotionRegistry
+ //-------------------------------------------------------------------------
+
+ // static constructor
+ // all subclasses must implement such a function and register it
+ static LLMotion *create(const LLUUID &id) { return new LLPhysicsMotionController(id); }
+
+public:
+ //-------------------------------------------------------------------------
+ // animation callbacks to be implemented by subclasses
+ //-------------------------------------------------------------------------
+
+ // motions must specify whether or not they loop
+ virtual BOOL getLoop() { return TRUE; }
+
+ // motions must report their total duration
+ virtual F32 getDuration() { return 0.0; }
+
+ // motions must report their "ease in" duration
+ virtual F32 getEaseInDuration() { return PHYSICS_MOTION_FADEIN_TIME; }
+
+ // motions must report their "ease out" duration.
+ virtual F32 getEaseOutDuration() { return PHYSICS_MOTION_FADEOUT_TIME; }
+
+ // called to determine when a motion should be activated/deactivated based on avatar pixel coverage
+ virtual F32 getMinPixelArea();
+
+ // motions must report their priority
+ virtual LLJoint::JointPriority getPriority() { return LLJoint::MEDIUM_PRIORITY; }
+
+ virtual LLMotionBlendType getBlendType() { return ADDITIVE_BLEND; }
+
+ // run-time (post constructor) initialization,
+ // called after parameters have been set
+ // must return true to indicate success and be available for activation
+ virtual LLMotionInitStatus onInitialize(LLCharacter *character);
+
+ // called when a motion is activated
+ // must return TRUE to indicate success, or else
+ // it will be deactivated
+ virtual BOOL onActivate();
+
+ // called per time step
+ // must return TRUE while it is active, and
+ // must return FALSE when the motion is completed.
+ virtual BOOL onUpdate(F32 time, U8* joint_mask);
+
+ // called when a motion is deactivated
+ virtual void onDeactivate();
+
+ LLCharacter* getCharacter() { return mCharacter; }
+
+protected:
+ void addMotion(LLPhysicsMotion *motion);
+private:
+ LLCharacter* mCharacter;
+
+ typedef std::vector<LLPhysicsMotion *> motion_vec_t;
+ motion_vec_t mMotions;
+};
+
+#endif // LL_LLPHYSICSMOTION_H
+
diff --git a/indra/newview/llpolymorph.cpp b/indra/newview/llpolymorph.cpp
index 5a67fd482a..36f8c8d13e 100644
--- a/indra/newview/llpolymorph.cpp
+++ b/indra/newview/llpolymorph.cpp
@@ -490,6 +490,16 @@ void LLPolyMorphTarget::apply( ESex avatar_sex )
mLastSex = avatar_sex;
+ // Check for NaN condition (NaN is detected if a variable doesn't equal itself.
+ if (mCurWeight != mCurWeight)
+ {
+ mCurWeight = 0.0;
+ }
+ if (mLastWeight != mLastWeight)
+ {
+ mLastWeight = mCurWeight+.001;
+ }
+
// perform differential update of morph
F32 delta_weight = ( getSex() & avatar_sex ) ? (mCurWeight - mLastWeight) : (getDefaultWeight() - mLastWeight);
// store last weight
diff --git a/indra/newview/llsidetraylistener.cpp b/indra/newview/llsidetraylistener.cpp
index 6db13e517d..cd6fa28948 100644
--- a/indra/newview/llsidetraylistener.cpp
+++ b/indra/newview/llsidetraylistener.cpp
@@ -4,8 +4,25 @@
* @date 2011-02-15
* @brief Implementation for llsidetraylistener.
*
- * $LicenseInfo:firstyear=2011&license=lgpl$
- * Copyright (c) 2011, Linden Research, Inc.
+ * $LicenseInfo:firstyear=2011&license=viewerlgpl$
+ * Second Life Viewer Source Code
+ * Copyright (C) 2011, 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$
*/
diff --git a/indra/newview/llsidetraylistener.h b/indra/newview/llsidetraylistener.h
index 0dd2067433..51e2137762 100644
--- a/indra/newview/llsidetraylistener.h
+++ b/indra/newview/llsidetraylistener.h
@@ -4,8 +4,25 @@
* @date 2011-02-15
* @brief
*
- * $LicenseInfo:firstyear=2011&license=lgpl$
- * Copyright (c) 2011, Linden Research, Inc.
+ * $LicenseInfo:firstyear=2011&license=viewerlgpl$
+ * Second Life Viewer Source Code
+ * Copyright (C) 2011, 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$
*/
diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp
index 4bc8a7ec54..ca908ef822 100644
--- a/indra/newview/llstartup.cpp
+++ b/indra/newview/llstartup.cpp
@@ -720,6 +720,8 @@ bool idle_startup()
timeout_count = 0;
+ initialize_edit_menu();
+
if (show_connect_box)
{
// Load all the name information out of the login view
@@ -736,8 +738,6 @@ bool idle_startup()
// Make sure the process dialog doesn't hide things
gViewerWindow->setShowProgress(FALSE);
- initialize_edit_menu();
-
// Show the login dialog
login_show();
// connect dialog is already shown, so fill in the names
diff --git a/indra/newview/llsyswellwindow.cpp b/indra/newview/llsyswellwindow.cpp
index e7b5c13860..cb49976e5f 100644
--- a/indra/newview/llsyswellwindow.cpp
+++ b/indra/newview/llsyswellwindow.cpp
@@ -310,7 +310,7 @@ void LLIMWellWindow::RowPanel::onChicletSizeChanged(LLChiclet* ctrl, const LLSD&
S32 new_text_left = mChiclet->getRect().mRight + CHICLET_HPAD;
LLRect text_rect = text->getRect();
text_rect.mLeft = new_text_left;
- text->setRect(text_rect);
+ text->setShape(text_rect);
}
//---------------------------------------------------------------------------------
diff --git a/indra/newview/lltoastalertpanel.cpp b/indra/newview/lltoastalertpanel.cpp
index 8b2f066d41..0f337825e9 100644
--- a/indra/newview/lltoastalertpanel.cpp
+++ b/indra/newview/lltoastalertpanel.cpp
@@ -220,7 +220,6 @@ LLToastAlertPanel::LLToastAlertPanel( LLNotificationPtr notification, bool modal
}
static LLUIColor alert_caution_text_color = LLUIColorTable::instance().getColor("AlertCautionTextColor");
- static LLUIColor alert_text_color = LLUIColorTable::instance().getColor("AlertTextColor");
if (mCaution)
{
LLIconCtrl* icon = LLUICtrlFactory::getInstance()->createFromFile<LLIconCtrl>("alert_icon.xml", this, LLPanel::child_registry_t::instance());
@@ -233,10 +232,6 @@ LLToastAlertPanel::LLToastAlertPanel( LLNotificationPtr notification, bool modal
msg_x += 32 + HPAD;
msg_box->setColor( alert_caution_text_color );
}
- else
- {
- msg_box->setColor( alert_text_color );
- }
LLRect rect;
rect.setLeftTopAndSize( msg_x, msg_y, text_rect.getWidth(), text_rect.getHeight() );
diff --git a/indra/newview/lltooldraganddrop.cpp b/indra/newview/lltooldraganddrop.cpp
index 1c745906aa..ba243f258a 100644
--- a/indra/newview/lltooldraganddrop.cpp
+++ b/indra/newview/lltooldraganddrop.cpp
@@ -1386,6 +1386,10 @@ EAcceptance LLToolDragAndDrop::willObjectAcceptInventory(LLViewerObject* obj, LL
worn = TRUE;
}
break;
+ case LLAssetType::AT_CALLINGCARD:
+ // Calling Cards in object are disabled for now
+ // because of incomplete LSL support. See STORM-1117.
+ return ACCEPT_NO;
default:
break;
}
diff --git a/indra/newview/llviewerchat.cpp b/indra/newview/llviewerchat.cpp
index 286b16bab2..f5484ff010 100644
--- a/indra/newview/llviewerchat.cpp
+++ b/indra/newview/llviewerchat.cpp
@@ -36,6 +36,7 @@
#include "llinstantmessage.h" //SYSTEM_FROM
// LLViewerChat
+LLViewerChat::font_change_signal_t LLViewerChat::sChatFontChangedSignal;
//static
void LLViewerChat::getChatColor(const LLChat& chat, LLColor4& r_color)
@@ -256,3 +257,16 @@ std::string LLViewerChat::getObjectImSLURL(const LLChat& chat, const LLSD& args)
return url;
}
+
+//static
+boost::signals2::connection LLViewerChat::setFontChangedCallback(const font_change_signal_t::slot_type& cb)
+{
+ return sChatFontChangedSignal.connect(cb);
+}
+
+//static
+void LLViewerChat::signalChatFontChanged()
+{
+ // Notify all observers that our font has changed
+ sChatFontChangedSignal(getChatFont());
+}
diff --git a/indra/newview/llviewerchat.h b/indra/newview/llviewerchat.h
index 0f15d29f04..c05caf0a95 100644
--- a/indra/newview/llviewerchat.h
+++ b/indra/newview/llviewerchat.h
@@ -35,6 +35,8 @@
class LLViewerChat
{
public:
+ typedef boost::signals2::signal<void (LLFontGL*)> font_change_signal_t;
+
static void getChatColor(const LLChat& chat, LLColor4& r_color);
static void getChatColor(const LLChat& chat, std::string& r_color_name, F32& r_color_alpha);
static LLFontGL* getChatFont();
@@ -42,8 +44,12 @@ public:
static void formatChatMsg(const LLChat& chat, std::string& formated_msg);
static std::string getSenderSLURL(const LLChat& chat, const LLSD& args);
+ static boost::signals2::connection setFontChangedCallback(const font_change_signal_t::slot_type& cb);
+ static void signalChatFontChanged();
+
private:
static std::string getObjectImSLURL(const LLChat& chat, const LLSD& args);
+ static font_change_signal_t sChatFontChangedSignal;
};
diff --git a/indra/newview/llviewerinventory.cpp b/indra/newview/llviewerinventory.cpp
index 68011ebf07..9e58acdcd3 100644
--- a/indra/newview/llviewerinventory.cpp
+++ b/indra/newview/llviewerinventory.cpp
@@ -1456,6 +1456,9 @@ private:
void saveFavoritesSLURLs();
+ // Remove record of current user's favorites from file on disk.
+ void removeFavoritesRecordOfUser();
+
void onLandmarkLoaded(const LLUUID& asset_id, LLLandmark* landmark);
void storeFavoriteSLURL(const LLUUID& asset_id, std::string& slurl);
@@ -1540,6 +1543,10 @@ void LLFavoritesOrderStorage::destroyClass()
{
LLFavoritesOrderStorage::instance().saveFavoritesSLURLs();
}
+ else
+ {
+ LLFavoritesOrderStorage::instance().removeFavoritesRecordOfUser();
+ }
}
void LLFavoritesOrderStorage::load()
@@ -1608,6 +1615,28 @@ void LLFavoritesOrderStorage::saveFavoritesSLURLs()
LLSDSerialize::toPrettyXML(fav_llsd, file);
}
+void LLFavoritesOrderStorage::removeFavoritesRecordOfUser()
+{
+ std::string filename = gDirUtilp->getExpandedFilename(LL_PATH_USER_SETTINGS, "stored_favorites.xml");
+ LLSD fav_llsd;
+ llifstream file;
+ file.open(filename);
+ if (!file.is_open()) return;
+ LLSDSerialize::fromXML(fav_llsd, file);
+
+ LLAvatarName av_name;
+ LLAvatarNameCache::get( gAgentID, &av_name );
+ if (fav_llsd.has(av_name.getLegacyName()))
+ {
+ fav_llsd.erase(av_name.getLegacyName());
+ }
+
+ llofstream out_file;
+ out_file.open(filename);
+ LLSDSerialize::toPrettyXML(fav_llsd, out_file);
+
+}
+
void LLFavoritesOrderStorage::onLandmarkLoaded(const LLUUID& asset_id, LLLandmark* landmark)
{
if (!landmark) return;
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index 3665b7d91f..5a3baf2650 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -6412,12 +6412,12 @@ class LLToolsSelectedScriptAction : public view_listener_t
else if (action == "start")
{
name = "start_queue";
- msg = "Running";
+ msg = "SetRunning";
}
else if (action == "stop")
{
name = "stop_queue";
- msg = "RunningNot";
+ msg = "SetRunningNot";
}
LLUUID id; id.generate();
diff --git a/indra/newview/llviewertexture.cpp b/indra/newview/llviewertexture.cpp
index cc635f71f9..f5fb074992 100644
--- a/indra/newview/llviewertexture.cpp
+++ b/indra/newview/llviewertexture.cpp
@@ -1469,7 +1469,7 @@ BOOL LLViewerFetchedTexture::createTexture(S32 usename/*= 0*/)
}
setActive() ;
- if (!mForceToSaveRawImage)
+ if (!needsToSaveRawImage())
{
mNeedsAux = FALSE;
destroyRawImage();
diff --git a/indra/newview/llwaterparammanager.cpp b/indra/newview/llwaterparammanager.cpp
index d239347810..4b3a9a4dc3 100644
--- a/indra/newview/llwaterparammanager.cpp
+++ b/indra/newview/llwaterparammanager.cpp
@@ -72,6 +72,8 @@ LLWaterParamManager::LLWaterParamManager() :
mWave1Dir(.5f, .5f, "wave1Dir"),
mWave2Dir(.5f, .5f, "wave2Dir"),
mDensitySliderValue(1.0f),
+ mPrevFogDensity(16.0f), // 2^4
+ mPrevFogColor(22.f/255.f, 43.f/255.f, 54.f/255.f, 0.0f),
mWaterFogKS(1.0f)
{
}
@@ -265,6 +267,20 @@ void LLWaterParamManager::update(LLViewerCamera * cam)
// update the shaders and the menu
propagateParameters();
+ // If water fog color has been changed, save it.
+ if (mPrevFogColor != mFogColor)
+ {
+ gSavedSettings.setColor4("WaterFogColor", mFogColor);
+ mPrevFogColor = mFogColor;
+ }
+
+ // If water fog density has been changed, save it.
+ if (mPrevFogDensity != mFogDensity)
+ {
+ gSavedSettings.setF32("WaterFogDensity", mFogDensity);
+ mPrevFogDensity = mFogDensity;
+ }
+
// sync menus if they exist
LLFloaterWater* waterfloater = LLFloaterReg::findTypedInstance<LLFloaterWater>("env_water");
if(waterfloater)
@@ -449,7 +465,24 @@ LLWaterParamManager * LLWaterParamManager::instance()
sInstance->loadAllPresets(LLStringUtil::null);
sInstance->getParamSet("Default", sInstance->mCurParams);
+ sInstance->initOverrides();
}
return sInstance;
}
+
+void LLWaterParamManager::initOverrides()
+{
+ // Override fog color from the current preset with the saved setting.
+ LLColor4 fog_color_override = gSavedSettings.getColor4("WaterFogColor");
+ mFogColor = fog_color_override;
+ mPrevFogColor = fog_color_override;
+ mCurParams.set("waterFogColor", fog_color_override);
+
+ // Do the same with fog density.
+ F32 fog_density = gSavedSettings.getF32("WaterFogDensity");
+ mPrevFogDensity = fog_density;
+ mFogDensity = fog_density;
+ mCurParams.set("waterFogDensity", fog_density);
+ setDensitySliderValue(mFogDensity.mExp);
+}
diff --git a/indra/newview/llwaterparammanager.h b/indra/newview/llwaterparammanager.h
index c479f1861c..f465034c39 100644
--- a/indra/newview/llwaterparammanager.h
+++ b/indra/newview/llwaterparammanager.h
@@ -284,6 +284,9 @@ public:
// singleton pattern implementation
static LLWaterParamManager * instance();
+private:
+ void initOverrides();
+
public:
LLWaterParamSet mCurParams;
@@ -314,6 +317,9 @@ private:
LLVector4 mWaterPlane;
F32 mWaterFogKS;
+ LLColor4 mPrevFogColor;
+ F32 mPrevFogDensity;
+
// our parameter manager singleton instance
static LLWaterParamManager * sInstance;
};
diff --git a/indra/newview/llwearabletype.cpp b/indra/newview/llwearabletype.cpp
index f933be4d8f..9e95604712 100644
--- a/indra/newview/llwearabletype.cpp
+++ b/indra/newview/llwearabletype.cpp
@@ -144,6 +144,7 @@ BOOL LLWearableType::getDisableCameraSwitch(LLWearableType::EType type)
{
const LLWearableDictionary *dict = LLWearableDictionary::getInstance();
const WearableEntry *entry = dict->lookup(type);
+ if (!entry) return FALSE;
return entry->mDisableCameraSwitch;
}
@@ -152,6 +153,7 @@ BOOL LLWearableType::getAllowMultiwear(LLWearableType::EType type)
{
const LLWearableDictionary *dict = LLWearableDictionary::getInstance();
const WearableEntry *entry = dict->lookup(type);
+ if (!entry) return FALSE;
return entry->mAllowMultiwear;
}
diff --git a/indra/newview/llworld.cpp b/indra/newview/llworld.cpp
index c6f9b6f6e4..6b2af1f8b7 100644
--- a/indra/newview/llworld.cpp
+++ b/indra/newview/llworld.cpp
@@ -1446,59 +1446,52 @@ void LLWorld::getAvatars(uuid_vec_t* avatar_ids, std::vector<LLVector3d>* positi
{
positions->clear();
}
- for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
- iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
+ // get the list of avatars from the character list first, so distances are correct
+ // when agent is above 1020m and other avatars are nearby
+ for (std::vector<LLCharacter*>::iterator iter = LLCharacter::sInstances.begin();
+ iter != LLCharacter::sInstances.end(); ++iter)
{
- LLViewerRegion* regionp = *iter;
- const LLVector3d& origin_global = regionp->getOriginGlobal();
- S32 count = regionp->mMapAvatars.count();
- for (S32 i = 0; i < count; i++)
+ LLVOAvatar* pVOAvatar = (LLVOAvatar*) *iter;
+ if(!pVOAvatar->isDead() && !pVOAvatar->isSelf())
{
- LLVector3d pos_global = unpackLocalToGlobalPosition(regionp->mMapAvatars.get(i), origin_global);
- if(dist_vec(pos_global, relative_to) <= radius)
+ LLUUID uuid = pVOAvatar->getID();
+ if(!uuid.isNull())
{
- if(positions != NULL)
+ LLVector3d pos_global = pVOAvatar->getPositionGlobal();
+ if(dist_vec(pos_global, relative_to) <= radius)
{
- positions->push_back(pos_global);
- }
- if(avatar_ids != NULL)
- {
- avatar_ids->push_back(regionp->mMapAvatarIDs.get(i));
+ if(positions != NULL)
+ {
+ positions->push_back(pos_global);
+ }
+ if(avatar_ids !=NULL)
+ {
+ avatar_ids->push_back(uuid);
+ }
}
}
}
}
- // retrieve the list of close avatars from viewer objects as well
- // for when we are above 1000m, only do this when we are retrieving
- // uuid's too as there could be duplicates
- if(avatar_ids != NULL)
+ // region avatars added for situations where radius is greater than RenderFarClip
+ for (LLWorld::region_list_t::const_iterator iter = LLWorld::getInstance()->getRegionList().begin();
+ iter != LLWorld::getInstance()->getRegionList().end(); ++iter)
{
- for (std::vector<LLCharacter*>::iterator iter = LLCharacter::sInstances.begin();
- iter != LLCharacter::sInstances.end(); ++iter)
+ LLViewerRegion* regionp = *iter;
+ const LLVector3d& origin_global = regionp->getOriginGlobal();
+ S32 count = regionp->mMapAvatars.count();
+ for (S32 i = 0; i < count; i++)
{
- LLVOAvatar* pVOAvatar = (LLVOAvatar*) *iter;
- if(pVOAvatar->isDead() || pVOAvatar->isSelf())
- continue;
- LLUUID uuid = pVOAvatar->getID();
- if(uuid.isNull())
- continue;
- LLVector3d pos_global = pVOAvatar->getPositionGlobal();
+ LLVector3d pos_global = unpackLocalToGlobalPosition(regionp->mMapAvatars.get(i), origin_global);
if(dist_vec(pos_global, relative_to) <= radius)
{
- bool found = false;
- uuid_vec_t::iterator sel_iter = avatar_ids->begin();
- for (; sel_iter != avatar_ids->end(); sel_iter++)
- {
- if(*sel_iter == uuid)
- {
- found = true;
- break;
- }
- }
- if(!found)
+ LLUUID uuid = regionp->mMapAvatarIDs.get(i);
+ // if this avatar doesn't already exist in the list, add it
+ if(uuid.notNull() && avatar_ids!=NULL && std::find(avatar_ids->begin(), avatar_ids->end(), uuid) == avatar_ids->end())
{
if(positions != NULL)
+ {
positions->push_back(pos_global);
+ }
avatar_ids->push_back(uuid);
}
}
diff --git a/indra/newview/skins/default/colors.xml b/indra/newview/skins/default/colors.xml
index 48fa01f0d9..a19eccf748 100644
--- a/indra/newview/skins/default/colors.xml
+++ b/indra/newview/skins/default/colors.xml
@@ -115,9 +115,6 @@
name="AlertCautionTextColor"
reference="LtYellow" />
<color
- name="AlertTextColor"
- value="0.58 0.66 0.84 1" />
- <color
name="AvatarListItemIconDefaultColor"
reference="White" />
<color
diff --git a/indra/newview/skins/default/xui/da/panel_preferences_chat.xml b/indra/newview/skins/default/xui/da/panel_preferences_chat.xml
index 3705a5902a..ed499619f6 100644
--- a/indra/newview/skins/default/xui/da/panel_preferences_chat.xml
+++ b/indra/newview/skins/default/xui/da/panel_preferences_chat.xml
@@ -29,7 +29,8 @@
<check_box label="IM chats" name="EnableIMChatPopups" tool_tip="Vælg for at se popup vindue når personlige beskeder (IM) modtages"/>
<spinner label="Tid før chatvisning forsvinder:" name="nearby_toasts_lifetime"/>
<spinner label="Tid før chatvisning forsvinder:" name="nearby_toasts_fadingtime"/>
- <check_box label="Benyt maskin-oversættelse ved chat (håndteret af Google)" name="translate_chat_checkbox"/>
+ <check_box name="translate_chat_checkbox"/>
+ <text name="translate_chb_label" >Benyt maskin-oversættelse ved chat (håndteret af Google)</text>
<text name="translate_language_text" width="110">
Oversæt chat til :
</text>
diff --git a/indra/newview/skins/default/xui/da/panel_preferences_sound.xml b/indra/newview/skins/default/xui/da/panel_preferences_sound.xml
index 5810cc21e7..067463be02 100644
--- a/indra/newview/skins/default/xui/da/panel_preferences_sound.xml
+++ b/indra/newview/skins/default/xui/da/panel_preferences_sound.xml
@@ -4,7 +4,8 @@
Midterste museknap
</panel.string>
<slider label="Generel" name="System Volume"/>
- <check_box initial_value="true" label="Sluk lyd når minimeret" name="mute_when_minimized"/>
+ <check_box initial_value="true" name="mute_when_minimized"/>
+ <text name="mute_chb_label">Sluk lyd når minimeret</text>
<slider label="Knapper" name="UI Volume"/>
<slider label="Omgivelser" name="Wind Volume"/>
<slider label="Lyd effekter" name="SFX Volume"/>
diff --git a/indra/newview/skins/default/xui/de/panel_preferences_chat.xml b/indra/newview/skins/default/xui/de/panel_preferences_chat.xml
index 8086128dd7..8c8cdd31fe 100644
--- a/indra/newview/skins/default/xui/de/panel_preferences_chat.xml
+++ b/indra/newview/skins/default/xui/de/panel_preferences_chat.xml
@@ -29,7 +29,8 @@
<check_box label="IM-Chats" name="EnableIMChatPopups" tool_tip="Markieren, um Popups zu sehen, wenn Instant Message eintrifft"/>
<spinner label="Lebenszeit von Toasts für Chat in der Nähe:" name="nearby_toasts_lifetime"/>
<spinner label="Ein-/Ausblenddauer von Toasts für Chat in der Nähe:" name="nearby_toasts_fadingtime"/>
- <check_box label="Bei Chat Maschinenübersetzung verwenden (Service von Google)" name="translate_chat_checkbox"/>
+ <check_box name="translate_chat_checkbox"/>
+ <text name="translate_chb_label" >Bei Chat Maschinenübersetzung verwenden (Service von Google)</text>
<text name="translate_language_text">
Chat übersetzen in:
</text>
diff --git a/indra/newview/skins/default/xui/de/panel_preferences_sound.xml b/indra/newview/skins/default/xui/de/panel_preferences_sound.xml
index 0f029d8664..07631b6a91 100644
--- a/indra/newview/skins/default/xui/de/panel_preferences_sound.xml
+++ b/indra/newview/skins/default/xui/de/panel_preferences_sound.xml
@@ -4,7 +4,8 @@
Mittlere Maustaste
</panel.string>
<slider label="Master-Lautstärke" name="System Volume"/>
- <check_box initial_value="true" label="Stummschalten, wenn minimiert" name="mute_when_minimized"/>
+ <check_box initial_value="true" name="mute_when_minimized"/>
+ <text name="mute_chb_label">Stummschalten, wenn minimiert</text>
<slider label="Schaltflächen" name="UI Volume"/>
<slider label="Umgebung" name="Wind Volume"/>
<slider label="Soundeffekte" name="SFX Volume"/>
diff --git a/indra/newview/skins/default/xui/en/floater_preferences.xml b/indra/newview/skins/default/xui/en/floater_preferences.xml
index ef670bdd52..dcfa8bc060 100644
--- a/indra/newview/skins/default/xui/en/floater_preferences.xml
+++ b/indra/newview/skins/default/xui/en/floater_preferences.xml
@@ -45,7 +45,7 @@
name="pref core"
tab_group="1"
tab_position="left"
- tab_width="115"
+ tab_width="140"
tab_padding_right="0"
top="21"
width="658">
diff --git a/indra/newview/skins/default/xui/en/menu_viewer.xml b/indra/newview/skins/default/xui/en/menu_viewer.xml
index 51610c0ae0..a5115b0faa 100644
--- a/indra/newview/skins/default/xui/en/menu_viewer.xml
+++ b/indra/newview/skins/default/xui/en/menu_viewer.xml
@@ -3113,6 +3113,16 @@
function="ToggleControl"
parameter="ImagePipelineUseHTTP" />
</menu_item_check>
+ <menu_item_check
+ label="HTTP Inventory"
+ name="HTTP Inventory">
+ <menu_item_check.on_check
+ function="CheckControl"
+ parameter="UseHTTPInventory" />
+ <menu_item_check.on_click
+ function="ToggleControl"
+ parameter="UseHTTPInventory" />
+ </menu_item_check>
<menu_item_call
label="Compress Images"
name="Compress Images">
diff --git a/indra/newview/skins/default/xui/en/panel_preferences_alerts.xml b/indra/newview/skins/default/xui/en/panel_preferences_alerts.xml
index 559df5bec9..714dca7fac 100644
--- a/indra/newview/skins/default/xui/en/panel_preferences_alerts.xml
+++ b/indra/newview/skins/default/xui/en/panel_preferences_alerts.xml
@@ -67,7 +67,7 @@
image_overlay="Arrow_Up"
hover_glow_amount="0.15"
layout="topleft"
- left="180"
+ left="200"
name="enable_this_popup"
top_pad="5"
width="40">
@@ -81,7 +81,7 @@
image_overlay="Arrow_Down"
hover_glow_amount="0.15"
layout="topleft"
- left_pad="40"
+ left_pad="20"
name="disable_this_popup"
top_delta="0"
width="40">
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 a1082d9c32..404537e1f2 100644
--- a/indra/newview/skins/default/xui/en/panel_preferences_chat.xml
+++ b/indra/newview/skins/default/xui/en/panel_preferences_chat.xml
@@ -208,15 +208,27 @@
<check_box
control_name="TranslateChat"
enabled="true"
- height="16"
- label="Use machine translation while chatting (powered by Google)"
+ height="16"
layout="topleft"
left="30"
name="translate_chat_checkbox"
- bottom_delta="30"
+ top_pad="5"
width="400" />
+ <!-- *HACK
+ After storm-1109 will be fixed: instead of using this text_box, word_wrap should be applied for "translate_chat_checkbox" check_box's label.-->
+ <text
+ follows="top|left"
+ height="15"
+ layout="topleft"
+ left="50"
+ name="translate_chb_label"
+ top_delta="1"
+ width="450"
+ wrap="true">
+ Use machine translation while chatting (powered by Google)
+ </text>
<text
- bottom_delta="30"
+ top_pad="20"
name="translate_language_text"
follows="left|top"
layout="topleft"
diff --git a/indra/newview/skins/default/xui/en/panel_preferences_general.xml b/indra/newview/skins/default/xui/en/panel_preferences_general.xml
index 36f8f99178..9c718fdb87 100644
--- a/indra/newview/skins/default/xui/en/panel_preferences_general.xml
+++ b/indra/newview/skins/default/xui/en/panel_preferences_general.xml
@@ -307,17 +307,6 @@
tool_tip="Check to use display names in chat, IM, name tags, etc."
top_pad="3"/>
- <check_box
- control_name="EnableUIHints"
- follows="top|left"
- height="16"
- label="Enable Viewer UI Hints"
- layout="topleft"
- left="27"
- name="viewer_hints_check"
- top_pad="5"
- width="237"/>
-
<text
type="string"
length="1"
@@ -326,7 +315,7 @@
layout="topleft"
left="30"
name="inworld_typing_rg_label"
- top_pad="6"
+ top_pad="1"
width="400">
Pressing letter keys:
</text>
@@ -348,9 +337,9 @@
width="150" />
<radio_item
label="Affects movement (i.e. WASD)"
- left_pad="0"
+ left="0"
layout="topleft"
- top_delta="0"
+ top="18"
height="16"
name="radio_move"
value="0"
@@ -365,7 +354,7 @@
layout="topleft"
left="30"
name="title_afk_text"
- top_pad="4"
+ top_pad="15"
width="190">
Away timeout:
</text>
@@ -408,7 +397,7 @@
left="30"
mouse_opaque="false"
name="text_box3"
- top_pad="5"
+ top_pad="3"
width="240">
Busy mode response:
</text>
diff --git a/indra/newview/skins/default/xui/en/panel_preferences_move.xml b/indra/newview/skins/default/xui/en/panel_preferences_move.xml
index d2fc6ea09a..04412bdb9c 100644
--- a/indra/newview/skins/default/xui/en/panel_preferences_move.xml
+++ b/indra/newview/skins/default/xui/en/panel_preferences_move.xml
@@ -120,12 +120,13 @@
type="string"
length="1"
follows="left|top"
- height="10"
+ height="15"
layout="topleft"
left_delta="3"
name=" Mouse Sensitivity"
top_pad="10"
- width="160">
+ width="160"
+ wrap="true">
Mouselook mouse sensitivity:
</text>
<slider
@@ -139,7 +140,7 @@
max_val="15"
name="mouse_sensitivity"
top_delta="-1"
- width="145" />
+ width="115" />
<check_box
control_name="InvertMouse"
height="16"
@@ -158,7 +159,7 @@
left="78"
name="arrow_keys_move_avatar_check"
width="237"
- top_pad="1"/>
+ top_pad="10"/>
<check_box
control_name="AllowTapTapHoldRun"
follows="left|top"
diff --git a/indra/newview/skins/default/xui/en/panel_preferences_privacy.xml b/indra/newview/skins/default/xui/en/panel_preferences_privacy.xml
index 6954a8b53a..30be5bc853 100644
--- a/indra/newview/skins/default/xui/en/panel_preferences_privacy.xml
+++ b/indra/newview/skins/default/xui/en/panel_preferences_privacy.xml
@@ -82,8 +82,8 @@
control_name="ShowFavoritesOnLogin"
enabled="false"
height="16"
- label="Show my Favorite Landmarks at Login (via &apos;Start At&apos; drop-down menu)"
layout="topleft"
+ label="Show my Favorite Landmarks at Login (via &apos;Start At&apos; drop-down menu)"
left="30"
name="favorites_on_login_check"
top_pad="10"
diff --git a/indra/newview/skins/default/xui/en/panel_preferences_sound.xml b/indra/newview/skins/default/xui/en/panel_preferences_sound.xml
index 26af8dc29d..f89494da72 100644
--- a/indra/newview/skins/default/xui/en/panel_preferences_sound.xml
+++ b/indra/newview/skins/default/xui/en/panel_preferences_sound.xml
@@ -50,12 +50,24 @@
control_name="MuteWhenMinimized"
height="15"
initial_value="true"
- label="Mute when minimized"
layout="topleft"
name="mute_when_minimized"
top_delta="3"
left_pad="5"
- width="235" />
+ width="20" />
+ <!-- *HACK
+ After storm-1109 will be fixed: instead of using this text_box, word_wrap should be applied for "mute_when_minimized" check_box's label.-->
+ <text
+ follows="top|left"
+ height="15"
+ layout="topleft"
+ left_pad="0"
+ name="mute_chb_label"
+ top_delta="0"
+ width="150"
+ wrap="true">
+ Mute when minimized
+ </text>
<slider
control_name="AudioLevelUI"
disabled_control="MuteAudio"
diff --git a/indra/newview/skins/default/xui/es/panel_preferences_chat.xml b/indra/newview/skins/default/xui/es/panel_preferences_chat.xml
index 0b304fe287..aba85f9ff1 100644
--- a/indra/newview/skins/default/xui/es/panel_preferences_chat.xml
+++ b/indra/newview/skins/default/xui/es/panel_preferences_chat.xml
@@ -29,7 +29,8 @@
<check_box label="Chats de MI" name="EnableIMChatPopups" tool_tip="Activa esta casilla para ver una ventana emergente cada vez que recibas un mensaje instantáneo"/>
<spinner label="Duración de los interlocutores favoritos:" name="nearby_toasts_lifetime"/>
<spinner label="Tiempo de los otros interlocutores:" name="nearby_toasts_fadingtime"/>
- <check_box label="Usar la traducción automática (con Google) en el chat" name="translate_chat_checkbox"/>
+ <check_box name="translate_chat_checkbox"/>
+ <text name="translate_chb_label" >Usar la traducción automática (con Google) en el chat</text>
<text name="translate_language_text">
Traducir el chat al:
</text>
diff --git a/indra/newview/skins/default/xui/es/panel_preferences_sound.xml b/indra/newview/skins/default/xui/es/panel_preferences_sound.xml
index db3659abcd..2bc82307a8 100644
--- a/indra/newview/skins/default/xui/es/panel_preferences_sound.xml
+++ b/indra/newview/skins/default/xui/es/panel_preferences_sound.xml
@@ -4,7 +4,8 @@
Botón medio del ratón
</panel.string>
<slider label="Volumen general" name="System Volume"/>
- <check_box initial_value="true" label="Silenciar cuando minimice" name="mute_when_minimized"/>
+ <check_box initial_value="true" name="mute_when_minimized"/>
+ <text name="mute_chb_label">Silenciar cuando minimice</text>
<slider label="Botones" name="UI Volume"/>
<slider label="Ambiental" name="Wind Volume"/>
<slider label="Efectos de sonido" name="SFX Volume"/>
diff --git a/indra/newview/skins/default/xui/fr/panel_preferences_chat.xml b/indra/newview/skins/default/xui/fr/panel_preferences_chat.xml
index 4b3fc35150..d5cecfc698 100644
--- a/indra/newview/skins/default/xui/fr/panel_preferences_chat.xml
+++ b/indra/newview/skins/default/xui/fr/panel_preferences_chat.xml
@@ -29,7 +29,8 @@
<check_box label="Chats IM" name="EnableIMChatPopups" tool_tip="Cocher cette case pour qu&apos;un popup s&apos;affiche à réception d&apos;un message instantané."/>
<spinner label="Durée de vie du popup Chat près de moi :" name="nearby_toasts_lifetime"/>
<spinner label="Disparition progressive du popup Chat près de moi :" name="nearby_toasts_fadingtime"/>
- <check_box label="Utiliser la traduction automatique lors des chats (fournie par Google)" name="translate_chat_checkbox"/>
+ <check_box name="translate_chat_checkbox"/>
+ <text name="translate_chb_label" >Utiliser la traduction automatique lors des chats (fournie par Google)</text>
<text name="translate_language_text">
Traduire le chat en :
</text>
diff --git a/indra/newview/skins/default/xui/fr/panel_preferences_sound.xml b/indra/newview/skins/default/xui/fr/panel_preferences_sound.xml
index 48630918d7..ac7f72d367 100644
--- a/indra/newview/skins/default/xui/fr/panel_preferences_sound.xml
+++ b/indra/newview/skins/default/xui/fr/panel_preferences_sound.xml
@@ -4,7 +4,8 @@
Bouton central de la souris
</panel.string>
<slider label="Volume principal" name="System Volume"/>
- <check_box initial_value="true" label="Couper quand minimisé" name="mute_when_minimized"/>
+ <check_box initial_value="true" name="mute_when_minimized"/>
+ <text name="mute_chb_label">Couper quand minimisé</text>
<slider label="Boutons" name="UI Volume"/>
<slider label="Ambiant" name="Wind Volume"/>
<slider label="Effets sonores" name="SFX Volume"/>
diff --git a/indra/newview/skins/default/xui/it/panel_preferences_chat.xml b/indra/newview/skins/default/xui/it/panel_preferences_chat.xml
index 4a1bbdf64a..208dd5ed28 100644
--- a/indra/newview/skins/default/xui/it/panel_preferences_chat.xml
+++ b/indra/newview/skins/default/xui/it/panel_preferences_chat.xml
@@ -56,7 +56,8 @@
<radio_item label="Finestre separate" name="radio" value="0"/>
<radio_item label="Schede" name="radio2" value="1"/>
</radio_group>
- <check_box label="Usa la traduzione meccanica durante le chat (tecnologia Google)" name="translate_chat_checkbox"/>
+ <check_box name="translate_chat_checkbox"/>
+ <text name="translate_chb_label" >Usa la traduzione meccanica durante le chat (tecnologia Google)</text>
<text name="translate_language_text" width="110">
Traduci chat in:
</text>
diff --git a/indra/newview/skins/default/xui/it/panel_preferences_sound.xml b/indra/newview/skins/default/xui/it/panel_preferences_sound.xml
index 6e70a314c5..e2332b63d0 100644
--- a/indra/newview/skins/default/xui/it/panel_preferences_sound.xml
+++ b/indra/newview/skins/default/xui/it/panel_preferences_sound.xml
@@ -1,7 +1,8 @@
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<panel label="Suoni" name="Preference Media panel">
<slider label="Vol. principale" name="System Volume"/>
- <check_box initial_value="true" label="Disatt. se a icona" name="mute_when_minimized"/>
+ <check_box initial_value="true" label="" name="mute_when_minimized"/>
+ <text name="mute_chb_label">Disatt. se a icona</text>
<slider label="Pulsanti" name="UI Volume"/>
<slider label="Ambiente" name="Wind Volume"/>
<slider label="Effetti sonori" name="SFX Volume"/>
diff --git a/indra/newview/skins/default/xui/ja/panel_preferences_chat.xml b/indra/newview/skins/default/xui/ja/panel_preferences_chat.xml
index c260cebef8..ce2a0f35e4 100644
--- a/indra/newview/skins/default/xui/ja/panel_preferences_chat.xml
+++ b/indra/newview/skins/default/xui/ja/panel_preferences_chat.xml
@@ -56,7 +56,8 @@
<radio_item label="別々のウィンドウ" name="radio" value="0"/>
<radio_item label="タブ" name="radio2" value="1"/>
</radio_group>
- <check_box label="チャット中に内容を機械翻訳する(Google翻訳)" name="translate_chat_checkbox"/>
+ <check_box name="translate_chat_checkbox"/>
+ <text name="translate_chb_label" >チャット中に内容を機械翻訳する(Google翻訳)</text>
<text name="translate_language_text">
翻訳する言語:
</text>
diff --git a/indra/newview/skins/default/xui/ja/panel_preferences_sound.xml b/indra/newview/skins/default/xui/ja/panel_preferences_sound.xml
index 9fbbd46220..74696a3b35 100644
--- a/indra/newview/skins/default/xui/ja/panel_preferences_sound.xml
+++ b/indra/newview/skins/default/xui/ja/panel_preferences_sound.xml
@@ -1,7 +1,8 @@
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<panel label="サウンド" name="Preference Media panel">
<slider label="全体の音量" name="System Volume"/>
- <check_box initial_value="true" label="最小化でミュート" name="mute_when_minimized"/>
+ <check_box initial_value="true" name="mute_when_minimized"/>
+ <text name="mute_chb_label">最小化でミュート</text>
<slider label="ボタン" name="UI Volume"/>
<slider label="風" name="Wind Volume"/>
<slider label="効果音" name="SFX Volume"/>
diff --git a/indra/newview/skins/default/xui/nl/panel_preferences_sound.xml b/indra/newview/skins/default/xui/nl/panel_preferences_sound.xml
index 2b709bde40..5ded015868 100644
--- a/indra/newview/skins/default/xui/nl/panel_preferences_sound.xml
+++ b/indra/newview/skins/default/xui/nl/panel_preferences_sound.xml
@@ -1,7 +1,8 @@
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<panel label="Geluid" name="Preference Media panel">
<slider label="Hoofd volume" name="System Volume"/>
- <check_box initial_value="true" label="Dempen indien geminimaliseerd" name="mute_when_minimized"/>
+ <check_box initial_value="true" name="mute_when_minimized"/>
+ <text name="mute_chb_label">Dempen indien geminimaliseerd</text>
<slider label="Omliggend" name="Wind Volume"/>
<slider label="Knoppen" name="UI Volume"/>
<slider label="Media" name="Media Volume"/>
diff --git a/indra/newview/skins/default/xui/pl/panel_preferences_chat.xml b/indra/newview/skins/default/xui/pl/panel_preferences_chat.xml
index c7142c8419..4a4e6509ab 100644
--- a/indra/newview/skins/default/xui/pl/panel_preferences_chat.xml
+++ b/indra/newview/skins/default/xui/pl/panel_preferences_chat.xml
@@ -29,7 +29,8 @@
<check_box label="Czat IM" name="EnableIMChatPopups" tool_tip="Zaznacz aby widzieć wyskakujące okienka kiedy IM się pojawia"/>
<spinner label="Czas widoczności czatu w pobliżu:" name="nearby_toasts_lifetime"/>
<spinner label="Czas znikania czatu w pobliżu:" name="nearby_toasts_fadingtime"/>
- <check_box label="Używaj translatora podczas rozmowy (wspierany przez Google)" name="translate_chat_checkbox"/>
+ <check_box name="translate_chat_checkbox"/>
+ <text name="translate_chb_label" >Używaj translatora podczas rozmowy (wspierany przez Google)</text>
<text name="translate_language_text">
Przetłumacz czat na:
</text>
diff --git a/indra/newview/skins/default/xui/pl/panel_preferences_sound.xml b/indra/newview/skins/default/xui/pl/panel_preferences_sound.xml
index ac93949a1b..692f24715b 100644
--- a/indra/newview/skins/default/xui/pl/panel_preferences_sound.xml
+++ b/indra/newview/skins/default/xui/pl/panel_preferences_sound.xml
@@ -4,7 +4,8 @@
Środkowy przycisk myszy
</panel.string>
<slider label="Główny" name="System Volume"/>
- <check_box initial_value="true" label="Wycisz podczas minimalizacji" name="mute_when_minimized"/>
+ <check_box initial_value="true" name="mute_when_minimized"/>
+ <text name="mute_chb_label">Wycisz podczas minimalizacji</text>
<slider label="Interfejs" name="UI Volume"/>
<slider label="Otoczenie" name="Wind Volume"/>
<slider label="Efekty dźwiękowe" name="SFX Volume"/>
diff --git a/indra/newview/skins/default/xui/pt/panel_preferences_chat.xml b/indra/newview/skins/default/xui/pt/panel_preferences_chat.xml
index 368c474ee9..412bdbb13e 100644
--- a/indra/newview/skins/default/xui/pt/panel_preferences_chat.xml
+++ b/indra/newview/skins/default/xui/pt/panel_preferences_chat.xml
@@ -29,7 +29,8 @@
<check_box label="Bate-papos de MI" name="EnableIMChatPopups" tool_tip="Exibir pop-up de mensagens instantâneas novas"/>
<spinner label="Transição de avisos de bate-papos por perto:" name="nearby_toasts_lifetime"/>
<spinner label="Transição de avisos de bate-papos por perto:" name="nearby_toasts_fadingtime"/>
- <check_box label="Traduzir bate-papo automaticamente (via Google)" name="translate_chat_checkbox"/>
+ <check_box name="translate_chat_checkbox"/>
+ <text name="translate_chb_label" >Traduzir bate-papo automaticamente (via Google)</text>
<text name="translate_language_text">
Traduzir bate-papo para:
</text>
diff --git a/indra/newview/skins/default/xui/pt/panel_preferences_sound.xml b/indra/newview/skins/default/xui/pt/panel_preferences_sound.xml
index 3846bfb377..6053deb5b1 100644
--- a/indra/newview/skins/default/xui/pt/panel_preferences_sound.xml
+++ b/indra/newview/skins/default/xui/pt/panel_preferences_sound.xml
@@ -4,7 +4,8 @@
Botão do meio do mouse
</panel.string>
<slider label="Volume principal" name="System Volume"/>
- <check_box initial_value="true" label="Silenciar ao minimizar" name="mute_when_minimized"/>
+ <check_box initial_value="true" name="mute_when_minimized"/>
+ <text name="mute_chb_label">Silenciar ao minimizar</text>
<slider label="Botões" name="UI Volume"/>
<slider label="Ambiente" name="Wind Volume"/>
<slider label="Efeitos sonoros" name="SFX Volume"/>
diff --git a/indra/newview/viewer_manifest.py b/indra/newview/viewer_manifest.py
index f0b1973fdf..f671c770ea 100644
--- a/indra/newview/viewer_manifest.py
+++ b/indra/newview/viewer_manifest.py
@@ -939,9 +939,9 @@ class Linux_i686Manifest(LinuxManifest):
self.path("libdb-5.1.so")
self.path("libdb-5.so")
self.path("libdb.so")
- self.path("libcrypto.so.0.9.8")
+ self.path("libcrypto.so.1.0.0")
self.path("libexpat.so.1.5.2")
- self.path("libssl.so.0.9.8")
+ self.path("libssl.so.1.0.0")
self.path("libuuid.so")
self.path("libuuid.so.16")
self.path("libuuid.so.16.0.22")
diff --git a/indra/test_apps/llplugintest/llmediaplugintest.cpp b/indra/test_apps/llplugintest/llmediaplugintest.cpp
index ee65e0aa87..884b00f0cc 100644
--- a/indra/test_apps/llplugintest/llmediaplugintest.cpp
+++ b/indra/test_apps/llplugintest/llmediaplugintest.cpp
@@ -4,7 +4,7 @@
*
* $LicenseInfo:firstyear=2008&license=viewerlgpl$
* Second Life Viewer Source Code
- * Copyright (C) 2010, Linden Research, Inc.
+ * Copyright (C) 2011, 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
@@ -2237,7 +2237,13 @@ void LLMediaPluginTest::handleMediaEvent(LLPluginClassMedia* self, EMediaEvent e
case MEDIA_EVENT_LINK_HOVERED:
{
std::cerr << "Media event: MEDIA_EVENT_LINK_HOVERED, hover text is: " << self->getHoverText() << std::endl;
- };
+ }
+ break;
+
+ default:
+ {
+ std::cerr << "Media event: <unknown>, code is: " << int(event) << std::endl;
+ }
break;
}
}