OpenTwin 0.1
OpenTwin
 
Loading...
Searching...
No Matches
ContextMenuAction.h
Go to the documentation of this file.
1
4// ###########################################################################################################################################################################################################################################################################################################################
5
6#pragma once
7
8// OpenTwin header
10#include "OTGui/MenuButtonCfg.h"
12
13// Qt header
14#include <QtWidgets/qaction.h>
15
16namespace ot {
17
20 public:
21 ContextMenuAction(QObject* _parent = (QObject*) nullptr);
22 ContextMenuAction(const MenuButtonCfg& _config, QObject* _parent = (QObject*) nullptr);
23 virtual ~ContextMenuAction();
24
25 void setFromConfiguration(const MenuButtonCfg& _config);
26
27 void setContextMenuActionName(const std::string& _name) { m_name = _name; };
28 const std::string& getContextMenuActionName(void) const { return m_name; };
29
30 private:
31 std::string m_name;
32 };
33
34}
This file contains defines that may be used simplyfy class creation.
#define OT_DECL_NOCOPY(___class)
Removes the default copy constructor and assignment operator.
Definition OTClassHelper.h:14
#define OT_WIDGETS_API_EXPORT
Definition OTWidgetsAPIExport.h:12
Definition ContextMenuAction.h:18
const std::string & getContextMenuActionName(void) const
Definition ContextMenuAction.h:28
void setContextMenuActionName(const std::string &_name)
Definition ContextMenuAction.h:27
Definition MenuButtonCfg.h:13
Definition Connector.h:8