ViewSelectionWidgetController.h
Go to the documentation of this file.
1/*
2 * This file is part of ArmarX.
3 *
4 * ArmarX is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation.
7 *
8 * ArmarX is distributed in the hope that it will be useful, but
9 * WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 *
16 * @package RobotAPI::gui-plugins::ViewSelectionWidgetController
17 * @author Markus Grotz ( markus dot grotz at kit dot edu )
18 * @date 2016
19 * @copyright http://www.gnu.org/licenses/gpl-2.0.txt
20 * GNU General Public License
21 */
22
23#pragma once
24
26
29
30#include <RobotAPI/gui-plugins/ViewSelection/ui_ViewSelectionWidget.h>
31#include <RobotAPI/interface/components/ViewSelectionInterface.h>
32
34
35namespace armarx
36{
37
38 //class ViewSelectionConfigDialog;
39
40
41 /**
42 \page RobotAPI-GuiPlugins-ViewSelection ViewSelection
43 \brief The ViewSelection allows visualizing ...
44
45 \image html ViewSelection.png
46 The user can
47
48 API Documentation \ref ViewSelectionWidgetController
49
50 \see ViewSelectionGuiPlugin
51 */
52
53 /**
54 * \class ViewSelectionWidgetController
55 * \brief ViewSelectionWidgetController brief one line description
56 *
57 * Detailed description
58 */
60 public ArmarXComponentWidgetControllerTemplate<ViewSelectionWidgetController>,
61 public armarx::ViewSelectionObserver
62 {
63 Q_OBJECT
64
65 public:
66 /**
67 * Controller Constructor
68 */
70
71 /**
72 * Controller destructor
73 */
75
76 /**
77 * @see ArmarXWidgetController::loadSettings()
78 */
79 void loadSettings(QSettings* settings) override;
80
81 /**
82 * @see ArmarXWidgetController::saveSettings()
83 */
84 void saveSettings(QSettings* settings) override;
85
86 void configured() override;
87
88 void onActivateAutomaticViewSelection(const Ice::Current& c = Ice::emptyCurrent) override;
89 void onDeactivateAutomaticViewSelection(const Ice::Current& c = Ice::emptyCurrent) override;
90 void nextViewTarget(Ice::Long, const Ice::Current& c = Ice::emptyCurrent) override;
91
92 /**
93 * Returns the Widget name displayed in the ArmarXGui to create an
94 * instance of this class.
95 */
96 static QString
98 {
99 return "RobotControl.ViewSelection";
100 }
101
102 /**
103 * \see armarx::Component::onInitComponent()
104 */
105 void onInitComponent() override;
106
107 /**
108 * \see armarx::Component::onConnectComponent()
109 */
110 void onConnectComponent() override;
111
112
113 QPointer<QDialog> getConfigDialog(QWidget* parent) override;
114
115 public slots:
116
117 void triggerSaliencyMapVisualization();
118 void clearSaliencyMapVisualization();
119 void updateSaliencyMapNames();
120 void toggleViewSelection(bool enabled);
121 /* QT slot declarations */
122
123 signals:
124 /* QT signal declarations */
125
126 private:
127 /**
128 * Widget Form
129 */
130 Ui::ViewSelectionWidget widget;
131
132 QPointer<ViewSelectionConfigDialog> configDialog;
133
134 ViewSelectionInterfacePrx viewSelection;
135
136 std::string viewSelectionName;
137 };
138} // namespace armarx
#define ARMARXCOMPONENT_IMPORT_EXPORT
constexpr T c
void onDeactivateAutomaticViewSelection(const Ice::Current &c=Ice::emptyCurrent) override
void loadSettings(QSettings *settings) override
void saveSettings(QSettings *settings) override
void onActivateAutomaticViewSelection(const Ice::Current &c=Ice::emptyCurrent) override
void nextViewTarget(Ice::Long, const Ice::Current &c=Ice::emptyCurrent) override
void configured() override
This function must be implemented by the user, if he supplies a config dialog.
static QString GetWidgetName()
Returns the Widget name displayed in the ArmarXGui to create an instance of this class.
This file offers overloads of toIce() and fromIce() functions for STL container types.