From 33e11be3e077b72427101bacf5a25a5ea7a53c61 Mon Sep 17 00:00:00 2001 From: Ryan Huffman Date: Thu, 26 Jun 2014 16:06:49 -0700 Subject: [PATCH] Add user locations to menu --- interface/src/Menu.cpp | 11 +++++++++++ interface/src/Menu.h | 2 ++ 2 files changed, 13 insertions(+) diff --git a/interface/src/Menu.cpp b/interface/src/Menu.cpp index fa30e0382b..7c9356045c 100644 --- a/interface/src/Menu.cpp +++ b/interface/src/Menu.cpp @@ -45,6 +45,7 @@ #include "ui/ModelsBrowser.h" #include "ui/LoginDialog.h" #include "ui/NodeBounds.h" +#include "ui/UserLocationsWindow.h" #include "devices/OculusManager.h" @@ -165,6 +166,11 @@ Menu::Menu() : Qt::CTRL | Qt::Key_N, this, SLOT(nameLocation())); + addActionToQMenuAndActionHash(fileMenu, + MenuOption::MyLocations, + Qt::CTRL | Qt::Key_L, + this, + SLOT(showLocationList())); addActionToQMenuAndActionHash(fileMenu, MenuOption::GoTo, Qt::Key_At, @@ -1179,6 +1185,11 @@ void Menu::namedLocationCreated(LocationManager::NamedLocationCreateResponse res msgBox.exec(); } +void Menu::showLocationList() { + UserLocationsWindow* window = new UserLocationsWindow(); + window->show(); +} + void Menu::nameLocation() { // check if user is logged in or show login dialog if not diff --git a/interface/src/Menu.h b/interface/src/Menu.h index 4d2174a448..e353b420dd 100644 --- a/interface/src/Menu.h +++ b/interface/src/Menu.h @@ -193,6 +193,7 @@ private slots: void goToDomainDialog(); void goToLocation(); void nameLocation(); + void showLocationList(); void bandwidthDetailsClosed(); void octreeStatsDetailsClosed(); void lodToolsClosed(); @@ -387,6 +388,7 @@ namespace MenuOption { const QString MoveWithLean = "Move with Lean"; const QString MuteAudio = "Mute Microphone"; const QString MuteEnvironment = "Mute Environment"; + const QString MyLocations = "My Locations..."; const QString NameLocation = "Name this location"; const QString NewVoxelCullingMode = "New Voxel Culling Mode"; const QString OctreeStats = "Voxel and Particle Statistics";