diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp index 4e5fdb1219dbf0a2444daf1738be5d74329803cc..92c2570c33142deb2d8f9a66c058e4cd7afc0de4 100644 --- a/indra/newview/llagent.cpp +++ b/indra/newview/llagent.cpp @@ -1785,6 +1785,8 @@ void LLAgent::endAnimationUpdateUI() } gAgentCamera.setLookAt(LOOKAT_TARGET_CLEAR); + + LLFloaterCamera::onAvatarEditingAppearance(false); } //--------------------------------------------------------------------- @@ -1891,6 +1893,8 @@ void LLAgent::endAnimationUpdateUI() { mPauseRequest = gAgentAvatarp->requestPause(); } + + LLFloaterCamera::onAvatarEditingAppearance(true); } if (isAgentAvatarValid()) diff --git a/indra/newview/llfloatercamera.cpp b/indra/newview/llfloatercamera.cpp index d6effb2b21d58a8eee624b13cd2efff8b09e7a61..0fa536dfadcd107f5ab036a67d839efaf8ffe811 100644 --- a/indra/newview/llfloatercamera.cpp +++ b/indra/newview/llfloatercamera.cpp @@ -243,6 +243,20 @@ void LLFloaterCamera::resetCameraMode() floater_camera->switchMode(CAMERA_CTRL_MODE_PAN); } +void LLFloaterCamera::onAvatarEditingAppearance(bool editing) +{ + LLFloaterCamera* floater_camera = LLFloaterCamera::findInstance(); + if (!floater_camera) return; + + //camera presets (rear, front, etc.) + floater_camera->childSetEnabled("preset_views_list", !editing); + floater_camera->childSetEnabled("presets_btn", !editing); + + //camera modes (object view, mouselook view) + floater_camera->childSetEnabled("camera_modes_list", !editing); + floater_camera->childSetEnabled("avatarview_btn", !editing); +} + void LLFloaterCamera::update() { ECameraControlMode mode = determineMode(); diff --git a/indra/newview/llfloatercamera.h b/indra/newview/llfloatercamera.h index 564e38d02de1ed50137fe736cc0558c43ea50dbf..c5f8cd6db5d44097f5a6d71254d1020eb7334f9b 100644 --- a/indra/newview/llfloatercamera.h +++ b/indra/newview/llfloatercamera.h @@ -68,6 +68,9 @@ class LLFloaterCamera /** resets current camera mode to orbit mode */ static void resetCameraMode(); + /** Called when Avatar is entered/exited editing appearance mode */ + static void onAvatarEditingAppearance(bool editing); + /* determines actual mode and updates ui */ void update();