mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-01 13:36:48 +08:00
moved enum metadata registration out of static methods of QObject-derived classes, which fixes #280 (GCC linker errors)
This commit is contained in:
committed by
Klaus Basan
parent
f775ac88d3
commit
e7c14e2c1c
@@ -11,8 +11,13 @@ namespace BlackCore
|
||||
{
|
||||
void registerMetadata()
|
||||
{
|
||||
IVoice::registerMetadata();
|
||||
ISimulator::registerMetadata();
|
||||
// for some reasons (ask RW) these are registered twice
|
||||
qRegisterMetaType<ISimulator::Status>();
|
||||
qRegisterMetaType<ISimulator::Status>("Status");
|
||||
qRegisterMetaType<IVoice::ComUnit>();
|
||||
qRegisterMetaType<IVoice::ComUnit>("ComUnit");
|
||||
qRegisterMetaType<IVoice::ConnectionStatus>();
|
||||
qRegisterMetaType<IVoice::ConnectionStatus>("ConnectionStatus");
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
||||
@@ -9,11 +9,4 @@ namespace BlackCore
|
||||
{
|
||||
ISimulator::ISimulator(QObject *parent) : QObject(parent)
|
||||
{ }
|
||||
|
||||
void ISimulator::registerMetadata()
|
||||
{
|
||||
// for some reasons (ask RW) this is registered twice, see IVoice
|
||||
qRegisterMetaType<Status>();
|
||||
qRegisterMetaType<Status>("Status");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -49,10 +49,6 @@ namespace BlackCore
|
||||
//! ISimulatorCan we connect?
|
||||
virtual bool canConnect() = 0;
|
||||
|
||||
//! ISimulatorRegister metadata
|
||||
static void registerMetadata();
|
||||
|
||||
|
||||
public slots:
|
||||
|
||||
//! ISimulatorConnect to simulator
|
||||
|
||||
@@ -9,13 +9,4 @@ namespace BlackCore
|
||||
{
|
||||
IVoice::IVoice(QObject *parent) : QObject(parent)
|
||||
{ }
|
||||
|
||||
void IVoice::registerMetadata()
|
||||
{
|
||||
// for some reasons (ask RW) this is registered twice
|
||||
qRegisterMetaType<ComUnit>();
|
||||
qRegisterMetaType<ComUnit>("ComUnit");
|
||||
qRegisterMetaType<ConnectionStatus>();
|
||||
qRegisterMetaType<ConnectionStatus>("ConnectionStatus");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -128,9 +128,6 @@ namespace BlackCore
|
||||
*/
|
||||
virtual QString micTestResultAsString() const = 0;
|
||||
|
||||
//! \brief Register metadata
|
||||
static void registerMetadata();
|
||||
|
||||
public slots:
|
||||
|
||||
/*!
|
||||
|
||||
Reference in New Issue
Block a user