diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index 7a10a6af90..427c91176f 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -860,11 +860,13 @@ void Application::idle() { } // Update from Mouse - QPoint mouse = QCursor::pos(); - _myAvatar.updateFromMouse(_glWidget->mapFromGlobal(mouse).x(), - _glWidget->mapFromGlobal(mouse).y(), - _glWidget->width(), - _glWidget->height()); + if (_mouseLook->isChecked()) { + QPoint mouse = QCursor::pos(); + _myAvatar.updateFromMouse(_glWidget->mapFromGlobal(mouse).x(), + _glWidget->mapFromGlobal(mouse).y(), + _glWidget->width(), + _glWidget->height()); + } // Read serial port interface devices if (_serialPort.active) { @@ -1117,6 +1119,8 @@ void Application::initMenu() { optionsMenu->addAction("Noise", this, SLOT(setNoise(bool)), Qt::Key_N)->setCheckable(true); (_gyroLook = optionsMenu->addAction("Gyro Look"))->setCheckable(true); _gyroLook->setChecked(true); + (_mouseLook = optionsMenu->addAction("Mouse Look"))->setCheckable(true); + _mouseLook->setChecked(false); optionsMenu->addAction("Fullscreen", this, SLOT(setFullscreen(bool)), Qt::Key_F)->setCheckable(true); QMenu* renderMenu = menuBar->addMenu("Render"); diff --git a/interface/src/Application.h b/interface/src/Application.h index 8a949fa183..f1c8d3ff1c 100644 --- a/interface/src/Application.h +++ b/interface/src/Application.h @@ -133,6 +133,7 @@ private: QAction* _lookingInMirror; // Are we currently rendering one's own head as if in mirror? QAction* _gyroLook; // Whether to allow the gyro data from head to move your view + QAction* _mouseLook; // Whether the have the mouse near edge of screen move your view QAction* _renderVoxels; // Whether to render voxels QAction* _renderStarsOn; // Whether to display the stars QAction* _renderAtmosphereOn; // Whether to display the atmosphere