mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-21 12:55:31 +08:00
@@ -1,6 +1,7 @@
|
|||||||
#include "introwindow.h"
|
#include "introwindow.h"
|
||||||
#include "mainwindow.h"
|
#include "mainwindow.h"
|
||||||
#include "guimodeenums.h"
|
#include "guimodeenums.h"
|
||||||
|
#include "blackcore/blackcorefreefunctions.h"
|
||||||
#include "blackcore/context_runtime_config.h"
|
#include "blackcore/context_runtime_config.h"
|
||||||
#include "blacksim/blacksimfreefunctions.h"
|
#include "blacksim/blacksimfreefunctions.h"
|
||||||
#include "blackmisc/blackmiscfreefunctions.h"
|
#include "blackmisc/blackmiscfreefunctions.h"
|
||||||
@@ -23,6 +24,7 @@ int main(int argc, char *argv[])
|
|||||||
BlackMisc::initResources();
|
BlackMisc::initResources();
|
||||||
BlackMisc::registerMetadata();
|
BlackMisc::registerMetadata();
|
||||||
BlackSim::registerMetadata();
|
BlackSim::registerMetadata();
|
||||||
|
BlackCore::registerMetadata();
|
||||||
// BlackMisc::displayAllUserMetatypesTypes();
|
// BlackMisc::displayAllUserMetatypesTypes();
|
||||||
|
|
||||||
QFile file(":blackmisc/translations/blackmisc_i18n_de.qm");
|
QFile file(":blackmisc/translations/blackmisc_i18n_de.qm");
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
#include "introwindow.h"
|
#include "introwindow.h"
|
||||||
#include "dockwindow.h"
|
#include "dockwindow.h"
|
||||||
#include "guimodeenums.h"
|
#include "guimodeenums.h"
|
||||||
|
#include "blackcore/blackcorefreefunctions.h"
|
||||||
#include "blackmisc/blackmiscfreefunctions.h"
|
#include "blackmisc/blackmiscfreefunctions.h"
|
||||||
#include <QtGlobal>
|
#include <QtGlobal>
|
||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
@@ -19,6 +20,7 @@ int main(int argc, char *argv[])
|
|||||||
Q_INIT_RESOURCE(blackgui);
|
Q_INIT_RESOURCE(blackgui);
|
||||||
BlackMisc::initResources();
|
BlackMisc::initResources();
|
||||||
BlackMisc::registerMetadata();
|
BlackMisc::registerMetadata();
|
||||||
|
BlackCore::registerMetadata();
|
||||||
// BlackMisc::displayAllUserMetatypesTypes();
|
// BlackMisc::displayAllUserMetatypesTypes();
|
||||||
|
|
||||||
QFile file(":blackmisc/translations/blackmisc_i18n_de.qm");
|
QFile file(":blackmisc/translations/blackmisc_i18n_de.qm");
|
||||||
|
|||||||
@@ -4,6 +4,7 @@
|
|||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
#include "blackcore/voice_vatlib.h"
|
#include "blackcore/voice_vatlib.h"
|
||||||
|
#include "blackcore/blackcorefreefunctions.h"
|
||||||
#include "blackmisc/blackmiscfreefunctions.h"
|
#include "blackmisc/blackmiscfreefunctions.h"
|
||||||
|
|
||||||
#include "client.h"
|
#include "client.h"
|
||||||
@@ -20,6 +21,7 @@ int main(int argc, char *argv[])
|
|||||||
QCoreApplication app (argc, argv);
|
QCoreApplication app (argc, argv);
|
||||||
Client client(&app);
|
Client client(&app);
|
||||||
BlackMisc::registerMetadata();
|
BlackMisc::registerMetadata();
|
||||||
|
BlackCore::registerMetadata();
|
||||||
BlackCore::IVoice *m_voice = new BlackCore::CVoiceVatlib();
|
BlackCore::IVoice *m_voice = new BlackCore::CVoiceVatlib();
|
||||||
QThread m_voiceThread;
|
QThread m_voiceThread;
|
||||||
m_voice->moveToThread(&m_voiceThread);
|
m_voice->moveToThread(&m_voiceThread);
|
||||||
|
|||||||
17
src/blackcore/blackcorefreefunctions.cpp
Normal file
17
src/blackcore/blackcorefreefunctions.cpp
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
/* Copyright (C) 2013 VATSIM Community / contributors
|
||||||
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||||
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
|
#include "blackcorefreefunctions.h"
|
||||||
|
#include "voice.h"
|
||||||
|
|
||||||
|
|
||||||
|
namespace BlackCore
|
||||||
|
{
|
||||||
|
void registerMetadata()
|
||||||
|
{
|
||||||
|
IVoice::registerMetadata();
|
||||||
|
}
|
||||||
|
|
||||||
|
} // namespace
|
||||||
21
src/blackcore/blackcorefreefunctions.h
Normal file
21
src/blackcore/blackcorefreefunctions.h
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
/* Copyright (C) 2013 VATSIM Community / contributors
|
||||||
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||||
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
|
#ifndef BLACKCORE_FREEFUNCTIONS_H
|
||||||
|
#define BLACKCORE_FREEFUNCTIONS_H
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* Free functions in BlackSim
|
||||||
|
*/
|
||||||
|
namespace BlackCore
|
||||||
|
{
|
||||||
|
/*!
|
||||||
|
* \brief Register all relevant metadata in BlackCore
|
||||||
|
*/
|
||||||
|
void registerMetadata();
|
||||||
|
|
||||||
|
} // BlackCore
|
||||||
|
|
||||||
|
#endif // guard
|
||||||
@@ -1,6 +1,7 @@
|
|||||||
#include "blackcore/context_runtime.h"
|
#include "blackcore/context_runtime.h"
|
||||||
#include "blackcore/context_all_impl.h"
|
#include "blackcore/context_all_impl.h"
|
||||||
#include "blackcore/context_all_proxies.h"
|
#include "blackcore/context_all_proxies.h"
|
||||||
|
#include "blackcore/blackcorefreefunctions.h"
|
||||||
|
|
||||||
#include "blacksim/blacksimfreefunctions.h"
|
#include "blacksim/blacksimfreefunctions.h"
|
||||||
|
|
||||||
@@ -224,6 +225,7 @@ namespace BlackCore
|
|||||||
BlackMisc::registerMetadata();
|
BlackMisc::registerMetadata();
|
||||||
BlackMisc::initResources();
|
BlackMisc::initResources();
|
||||||
BlackSim::registerMetadata();
|
BlackSim::registerMetadata();
|
||||||
|
BlackCore::registerMetadata();
|
||||||
|
|
||||||
// upfront reading of settings, as DBus server already relies on settings
|
// upfront reading of settings, as DBus server already relies on settings
|
||||||
CContextSettings *settings = nullptr;
|
CContextSettings *settings = nullptr;
|
||||||
|
|||||||
@@ -9,10 +9,13 @@ namespace BlackCore
|
|||||||
{
|
{
|
||||||
IVoice::IVoice(QObject *parent) : QObject(parent)
|
IVoice::IVoice(QObject *parent) : QObject(parent)
|
||||||
{
|
{
|
||||||
// http://qt-project.org/forums/viewthread/27495
|
}
|
||||||
qRegisterMetaType<IVoice::ComUnit>("ComUnit");
|
|
||||||
qRegisterMetaType<IVoice::ComUnit>("IVoice::ComUnit");
|
void IVoice::registerMetadata()
|
||||||
qRegisterMetaType<IVoice::ConnectionStatus>("ConnectionStatus");
|
{
|
||||||
qRegisterMetaType<IVoice::ConnectionStatus>("IVoice::ConnectionStatus");
|
qRegisterMetaType<ComUnit>();
|
||||||
|
qRegisterMetaType<ComUnit>("ComUnit");
|
||||||
|
qRegisterMetaType<ConnectionStatus>();
|
||||||
|
qRegisterMetaType<ConnectionStatus>("ConnectionStatus");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -126,6 +126,9 @@ namespace BlackCore
|
|||||||
*/
|
*/
|
||||||
virtual QString micTestResultAsString() const = 0;
|
virtual QString micTestResultAsString() const = 0;
|
||||||
|
|
||||||
|
//! \brief Register metadata
|
||||||
|
static void registerMetadata();
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
|
|||||||
Reference in New Issue
Block a user