Go to the source code of this file.
◆ MP_CREATE_DESCRIPTOR
#define MP_CREATE_DESCRIPTOR |
( |
| _interfaceclass | ) |
|
◆ MP_DECLARE_DESCRIPTOR
#define MP_DECLARE_DESCRIPTOR |
( |
| _interfaceclass | ) |
|
Value:
{ \
public: \
_interfaceclass##Descriptor(); \
virtual ~_interfaceclass##Descriptor(); \
\
protected: \
_interfaceclass * m_pInstance; \
QString m_szName; \
QString m_szDescription; \
\
public: \
virtual const QString & name(); \
virtual const QString & description(); \
};
Definition MpInterface.h:189
Definition MpInterface.h:32
◆ MP_IMPLEMENT_DESCRIPTOR
#define MP_IMPLEMENT_DESCRIPTOR |
( |
| _interfaceclass, |
|
|
| _name, |
|
|
| _description ) |
Value: _interfaceclass##Descriptor::_interfaceclass##Descriptor() \
{ \
m_pInstance = nullptr; \
m_szName = _name; \
m_szDescription = _description; \
} \
_interfaceclass##Descriptor::~_interfaceclass##Descriptor() \
{ \
if(m_pInstance) \
delete m_pInstance; \
} \
const QString & _interfaceclass##Descriptor::name() \
{ \
return m_szName; \
} \
const QString & _interfaceclass##Descriptor::description() \
{ \
return m_szDescription; \
} \
MpInterface * _interfaceclass##Descriptor::instance() \
{ \
if(!m_pInstance) \
m_pInstance = new _interfaceclass(); \
return m_pInstance; \
}