From 6e5847bb1c773c7f790a90b3bd65b9b6cbab04e5 Mon Sep 17 00:00:00 2001 From: Brad Hefta-Gaub Date: Tue, 6 Oct 2015 19:58:25 -0700 Subject: [PATCH] make Hand Input Mouse off by default --- interface/src/Application.cpp | 2 +- interface/src/Menu.cpp | 2 +- interface/src/Menu.h | 2 +- interface/src/ui/ApplicationCompositor.cpp | 7 ++++--- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index b44ac6804d..3ac667f7b4 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -2745,7 +2745,7 @@ void Application::update(float deltaTime) { Hand* hand = DependencyManager::get()->getMyAvatar()->getHand(); setPalmData(hand, leftHand, deltaTime, LEFT_HAND_INDEX, userInputMapper->getActionState(UserInputMapper::LEFT_HAND_CLICK)); setPalmData(hand, rightHand, deltaTime, RIGHT_HAND_INDEX, userInputMapper->getActionState(UserInputMapper::RIGHT_HAND_CLICK)); - if (Menu::getInstance()->isOptionChecked(MenuOption::HandMouseInput)) { + if (Menu::getInstance()->isOptionChecked(MenuOption::EnableHandMouseInput)) { emulateMouse(hand, userInputMapper->getActionState(UserInputMapper::LEFT_HAND_CLICK), userInputMapper->getActionState(UserInputMapper::SHIFT), LEFT_HAND_INDEX); emulateMouse(hand, userInputMapper->getActionState(UserInputMapper::RIGHT_HAND_CLICK), diff --git a/interface/src/Menu.cpp b/interface/src/Menu.cpp index 9abfd1e34c..ae41ca2493 100644 --- a/interface/src/Menu.cpp +++ b/interface/src/Menu.cpp @@ -464,7 +464,7 @@ Menu::Menu() { MenuWrapper* handOptionsMenu = developerMenu->addMenu("Hands"); addCheckableActionToQMenuAndActionHash(handOptionsMenu, MenuOption::DisplayHandTargets, 0, false); - addCheckableActionToQMenuAndActionHash(handOptionsMenu, MenuOption::HandMouseInput, 0, true); + addCheckableActionToQMenuAndActionHash(handOptionsMenu, MenuOption::EnableHandMouseInput, 0, false); addCheckableActionToQMenuAndActionHash(handOptionsMenu, MenuOption::LowVelocityFilter, 0, true, qApp, SLOT(setLowVelocityFilter(bool))); addCheckableActionToQMenuAndActionHash(handOptionsMenu, MenuOption::ShowIKConstraints, 0, false); diff --git a/interface/src/Menu.h b/interface/src/Menu.h index 33ce659a51..4c9c3ef7b5 100644 --- a/interface/src/Menu.h +++ b/interface/src/Menu.h @@ -204,7 +204,7 @@ namespace MenuOption { const QString FrameTimer = "Show Timer"; const QString FullscreenMirror = "Fullscreen Mirror"; const QString GlowWhenSpeaking = "Glow When Speaking"; - const QString HandMouseInput = "Enable Hand Mouse Input"; + const QString EnableHandMouseInput = "Enable Hand Controller Mouse Input"; const QString IncreaseAvatarSize = "Increase Avatar Size"; const QString IndependentMode = "Independent Mode"; const QString InputMenu = "Avatar>Input Devices"; diff --git a/interface/src/ui/ApplicationCompositor.cpp b/interface/src/ui/ApplicationCompositor.cpp index cb4ae9990c..7a90e30e53 100644 --- a/interface/src/ui/ApplicationCompositor.cpp +++ b/interface/src/ui/ApplicationCompositor.cpp @@ -313,8 +313,8 @@ void ApplicationCompositor::displayOverlayTextureHmd(RenderArgs* renderArgs, int glm::mat4 overlayXfm; _modelTransform.getMatrix(overlayXfm); - // Only render the hand pointers if the HandMouseInput is enabled - if (Menu::getInstance()->isOptionChecked(MenuOption::HandMouseInput)) { + // Only render the hand pointers if the EnableHandMouseInput is enabled + if (Menu::getInstance()->isOptionChecked(MenuOption::EnableHandMouseInput)) { MyAvatar* myAvatar = DependencyManager::get()->getMyAvatar(); for (int i = 0; i < (int)myAvatar->getHand()->getNumPalms(); i++) { PalmData& palm = myAvatar->getHand()->getPalms()[i]; @@ -435,7 +435,8 @@ void ApplicationCompositor::renderPointers(gpu::Batch& batch) { _magActive[MOUSE] = _magnifier; _reticleActive[LEFT_CONTROLLER] = false; _reticleActive[RIGHT_CONTROLLER] = false; - } else if (qApp->getLastMouseMoveWasSimulated() && Menu::getInstance()->isOptionChecked(MenuOption::HandMouseInput)) { + } else if (qApp->getLastMouseMoveWasSimulated() + && Menu::getInstance()->isOptionChecked(MenuOption::EnableHandMouseInput)) { //only render controller pointer if we aren't already rendering a mouse pointer _reticleActive[MOUSE] = false; _magActive[MOUSE] = false;