diff options
Diffstat (limited to 'indra/newview/llviewermenu.cpp')
-rwxr-xr-x | indra/newview/llviewermenu.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp index be9b4439a8..fbd7dbeefd 100755 --- a/indra/newview/llviewermenu.cpp +++ b/indra/newview/llviewermenu.cpp @@ -2830,6 +2830,8 @@ BOOL enable_object_build(void*) bool enable_object_edit() { + if (!isAgentAvatarValid()) return false; + // *HACK: The new "prelude" Help Islands have a build sandbox area, // so users need the Edit and Create pie menu options when they are // there. Eventually this needs to be replaced with code that only @@ -3881,6 +3883,14 @@ class LLEnableEditShape : public view_listener_t } }; +class LLEnableHoverHeight : public view_listener_t +{ + bool handleEvent(const LLSD& userdata) + { + return gAgent.getRegion() && gAgent.getRegion()->avatarHoverHeightEnabled(); + } +}; + class LLEnableEditPhysics : public view_listener_t { bool handleEvent(const LLSD& userdata) @@ -6075,6 +6085,11 @@ void handle_edit_shape() LLFloaterSidePanelContainer::showPanel("appearance", LLSD().with("type", "edit_shape")); } +void handle_hover_height() +{ + LLFloaterReg::showInstance("edit_hover_height"); +} + void handle_edit_physics() { LLFloaterSidePanelContainer::showPanel("appearance", LLSD().with("type", "edit_physics")); @@ -8567,10 +8582,12 @@ void initialize_menus() view_listener_t::addMenu(new LLEditEnableTakeOff(), "Edit.EnableTakeOff"); view_listener_t::addMenu(new LLEditEnableCustomizeAvatar(), "Edit.EnableCustomizeAvatar"); view_listener_t::addMenu(new LLEnableEditShape(), "Edit.EnableEditShape"); + view_listener_t::addMenu(new LLEnableHoverHeight(), "Edit.EnableHoverHeight"); view_listener_t::addMenu(new LLEnableEditPhysics(), "Edit.EnableEditPhysics"); commit.add("CustomizeAvatar", boost::bind(&handle_customize_avatar)); commit.add("EditOutfit", boost::bind(&handle_edit_outfit)); commit.add("EditShape", boost::bind(&handle_edit_shape)); + commit.add("HoverHeight", boost::bind(&handle_hover_height)); commit.add("EditPhysics", boost::bind(&handle_edit_physics)); // View menu |