StateEditorController.h
Go to the documentation of this file.
1/*
2 * This file is part of ArmarX.
3 *
4 * Copyright (C) 2011-2016, High Performance Humanoid Technologies (H2T), Karlsruhe Institute of Technology (KIT), all rights reserved.
5 *
6 * ArmarX is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as
8 * published by the Free Software Foundation.
9 *
10 * ArmarX is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 *
18 * @package
19 * @author
20 * @date
21 * @copyright http://www.gnu.org/licenses/gpl-2.0.txt
22 * GNU General Public License
23 */
24#pragma once
25
26
27#include <QObject>
28
31
35
38
39namespace armarx
40{
41
43 using StateTreeControllerPtr = std::shared_ptr<StateTreeController>;
44 class StateTreeNode;
45 using StateTreeNodePtr = std::shared_ptr<StateTreeNode>;
46
47 class StateTabWidget;
48
49 class StateEditorController : public QObject
50 {
51 Q_OBJECT
52
53 public:
59 QPointer<TipDialog> tipDialog,
60 QObject* parent = 0);
61
62 QList<QString> getRelevantProfiles() const;
63 signals:
64
65 public slots:
67 QPoint mouseScreenPos,
68 QPointF mouseItemPos);
71 QPoint mouseScreenPos,
72 QPointF mouseItemPos);
73 void setLockRemoteStatesByDefault(bool lock);
74 void editSelectedState();
75 private slots:
76 void connectToStateTab(int index);
77
78 protected:
80 const armarx::StateDialog& d);
81
84
91 QPointer<TipDialog> tipDialog;
93 QMenu menu;
94 QAction* editState;
95 QAction* deleteState;
96 QAction* layoutState;
97 QAction* setstartstate;
98
99 QAction* newEndstate;
100 QAction* replaceState;
101 QAction* openCode;
103 };
104
105 using StateEditorControllerPtr = std::shared_ptr<StateEditorController>;
106
107} // namespace armarx
uint8_t index
The EditorFileOpener class.
void showTransitionContextMenu(statechartmodel::TransitionCPtr transition, statechartmodel::StatePtr state, QPoint mouseScreenPos, QPointF mouseItemPos)
void stateDialogAccepted(statechartmodel::StateInstancePtr stateInstance, const armarx::StateDialog &d)
void showStateContextMenu(statechartmodel::StateInstancePtr stateInstance, QPoint mouseScreenPos, QPointF mouseItemPos)
StateTreeControllerPtr treeController
StatechartEditorMainWindow * mainWindow
StateEditorController(StatechartEditorMainWindow *mainWindow, StateTreeControllerPtr treeController, Ice::CommunicatorPtr communicator, VariantInfoPtr variantInfo, StatechartProfilePtr currentProfile, QPointer< TipDialog > tipDialog, QObject *parent=0)
QList< QString > getRelevantProfiles() const
::IceInternal::Handle<::Ice::Communicator > CommunicatorPtr
Definition IceManager.h:49
std::shared_ptr< State > StatePtr
Definition State.h:48
std::shared_ptr< StateInstance > StateInstancePtr
std::shared_ptr< const Transition > TransitionCPtr
Definition Transition.h:91
This file offers overloads of toIce() and fromIce() functions for STL container types.
std::shared_ptr< StateEditorController > StateEditorControllerPtr
std::shared_ptr< VariantInfo > VariantInfoPtr
Definition VariantInfo.h:39
std::shared_ptr< class StatechartProfile > StatechartProfilePtr
std::shared_ptr< StateTreeNode > StateTreeNodePtr
std::shared_ptr< StateTreeController > StateTreeControllerPtr