From b0fb15a1599bf4058fe27b718d5a5fdd458dc357 Mon Sep 17 00:00:00 2001 From: Bryant Date: Mon, 1 Dec 2014 18:02:35 -0800 Subject: [PATCH] Remove the Software view. --- src/ui/MainWindow.cc | 29 +---------------------------- src/ui/MainWindow.h | 7 ++----- src/ui/MainWindow.ui | 12 ------------ 3 files changed, 3 insertions(+), 45 deletions(-) diff --git a/src/ui/MainWindow.cc b/src/ui/MainWindow.cc index eb8cc70d1..303ee1718 100644 --- a/src/ui/MainWindow.cc +++ b/src/ui/MainWindow.cc @@ -160,7 +160,6 @@ MainWindow::MainWindow(QSplashScreen* splashScreen, enum MainWindow::CUSTOM_MODE case VIEW_FLIGHT: case VIEW_SIMULATION: case VIEW_SETUP: - case VIEW_SOFTWARE_CONFIG: case VIEW_TERMINAL: // And only re-load views if they're supported with the current QGC build @@ -210,23 +209,20 @@ MainWindow::MainWindow(QSplashScreen* splashScreen, enum MainWindow::CUSTOM_MODE toolBar = new QGCToolBar(this); this->addToolBar(toolBar); - // Add actions for average users (displayed next to each other) + // Add the perspectives to the toolbar QList actions; actions << ui.actionSetup; actions << ui.actionMissionView; actions << ui.actionFlightView; actions << ui.actionEngineersView; - toolBar->setPerspectiveChangeActions(actions); // Add actions for advanced users (displayed in dropdown under "advanced") QList advancedActions; advancedActions << ui.actionGoogleEarthView; advancedActions << ui.actionLocal3DView; - advancedActions << ui.actionSoftwareConfig; advancedActions << ui.actionTerminalView; advancedActions << ui.actionSimulationView; - toolBar->setPerspectiveChangeAdvancedActions(advancedActions); customStatusBar = new QGCStatusBar(this); @@ -1176,11 +1172,6 @@ void MainWindow::connectCommonActions() ui.actionSetup->setChecked(true); ui.actionSetup->activate(QAction::Trigger); } - if (currentView == VIEW_SOFTWARE_CONFIG) - { - ui.actionSoftwareConfig->setChecked(true); - ui.actionSoftwareConfig->activate(QAction::Trigger); - } if (currentView == VIEW_TERMINAL) { ui.actionTerminalView->setChecked(true); @@ -1228,7 +1219,6 @@ void MainWindow::connectCommonActions() connect(ui.actionSetup,SIGNAL(triggered()),this,SLOT(loadSetupView())); connect(ui.actionGoogleEarthView, SIGNAL(triggered()), this, SLOT(loadGoogleEarthView())); connect(ui.actionLocal3DView, SIGNAL(triggered()), this, SLOT(loadLocal3DView())); - connect(ui.actionSoftwareConfig,SIGNAL(triggered()),this,SLOT(loadSoftwareConfigView())); connect(ui.actionTerminalView,SIGNAL(triggered()),this,SLOT(loadTerminalView())); // Help Actions @@ -1574,10 +1564,6 @@ void MainWindow::loadViewState() case VIEW_SETUP: centerStack->setCurrentWidget(setupView); break; - case VIEW_SOFTWARE_CONFIG: - if (softwareConfigView) - centerStack->setCurrentWidget(softwareConfigView); - break; case VIEW_ENGINEER: centerStack->setCurrentWidget(engineeringView); break; @@ -1588,11 +1574,9 @@ void MainWindow::loadViewState() case VIEW_MISSION: centerStack->setCurrentWidget(plannerView); break; - case VIEW_SIMULATION: centerStack->setCurrentWidget(simView); break; - case VIEW_TERMINAL: centerStack->setCurrentWidget(terminalView); break; @@ -1694,17 +1678,6 @@ void MainWindow::loadSetupView() } } -void MainWindow::loadSoftwareConfigView() -{ - if (currentView != VIEW_SOFTWARE_CONFIG) - { - storeViewState(); - currentView = VIEW_SOFTWARE_CONFIG; - ui.actionSoftwareConfig->setChecked(true); - loadViewState(); - } -} - void MainWindow::loadTerminalView() { if (currentView != VIEW_TERMINAL) diff --git a/src/ui/MainWindow.h b/src/ui/MainWindow.h index e545d810e..1ef89685e 100644 --- a/src/ui/MainWindow.h +++ b/src/ui/MainWindow.h @@ -195,7 +195,6 @@ public slots: void handleMisconfiguration(UASInterface* uas); /** @brief Load configuration views */ void loadSetupView(); - void loadSoftwareConfigView(); /** @brief Load view for pilot */ void loadPilotView(); /** @brief Load view for simulation */ @@ -303,11 +302,9 @@ protected: { VIEW_ENGINEER, // Engineering/Analyze view mode. Used for analyzing data and modifying onboard parameters VIEW_MISSION, // Mission/Map/Plan view mode. Used for setting mission waypoints and high-level system commands. - VIEW_FLIGHT, // Flight/Fly/Operate view mode. Used for 1st-person observation of the vehicle - VIEW_SIMULATION, // Simulation view. Useful overview of the entire system for simulation. - VIEW_FIRMWAREUPDATE, // UNUSED, left for backwards compatibility with existing saved settings. + VIEW_FLIGHT, // Flight/Fly/Operate view mode. Used for 1st-person observation of the vehicle. + VIEW_SIMULATION, // HIL Simulation view. Useful overview of the entire system when doing hardware-in-the-loop simulations. VIEW_SETUP, // Setup view. Used for initializing the system for operation. Includes UI for calibration, firmware updating/checking, and parameter modifcation. - VIEW_SOFTWARE_CONFIG, // Software view. Used for configuring the onboard software/firmware. VIEW_TERMINAL, // Terminal interface. Used for communicating with the remote system, usually in a special configuration input mode. VIEW_LOCAL3D, // A local 3D view. Provides a local 3D view that makes visualizing 3D attitude/orientation/pose easy while in operation. VIEW_GOOGLEEARTH // 3D Google Earth view. A 3D terrain view, though the vehicle is still 2D. diff --git a/src/ui/MainWindow.ui b/src/ui/MainWindow.ui index ebeddfe18..346a37b58 100644 --- a/src/ui/MainWindow.ui +++ b/src/ui/MainWindow.ui @@ -457,18 +457,6 @@ Simulation - - - true - - - - :/files/images/categories/applications-system.svg:/files/images/categories/applications-system.svg - - - Software - - true -- 2.22.0