mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-04 00:16:51 +08:00
refs #507, split up blackmiscfreefunctions
* single register metadata functions * string utils * metadata utils * some formatting / license header where applicable
This commit is contained in:
@@ -21,12 +21,6 @@ namespace BlackSimPlugin
|
||||
{
|
||||
namespace Fs9
|
||||
{
|
||||
void registerMetadata()
|
||||
{
|
||||
qRegisterMetaType<CFs9Host::HostStatus>();
|
||||
qRegisterMetaType<CFs9Client::ClientStatus>();
|
||||
}
|
||||
|
||||
CAircraftSituation aircraftSituationfromFS9(const MPPositionVelocity &positionVelocity)
|
||||
{
|
||||
CAircraftSituation situation;
|
||||
|
||||
@@ -46,9 +46,6 @@ namespace BlackSimPlugin
|
||||
pT = nullptr;
|
||||
}
|
||||
|
||||
//! Register all relevant metadata in BlackMisc
|
||||
void registerMetadata();
|
||||
|
||||
//! Convert FS9 struct to aircraft situation
|
||||
BlackMisc::Aviation::CAircraftSituation aircraftSituationfromFS9(const MPPositionVelocity &positionVelocity);
|
||||
|
||||
@@ -63,7 +60,7 @@ namespace BlackSimPlugin
|
||||
//! Print the direct play error
|
||||
HRESULT logDirectPlayError(HRESULT error);
|
||||
|
||||
}
|
||||
}
|
||||
} // ns
|
||||
} // ns
|
||||
|
||||
#endif // guard
|
||||
|
||||
24
src/plugins/simulator/fs9/registermetadata.cpp
Normal file
24
src/plugins/simulator/fs9/registermetadata.cpp
Normal file
@@ -0,0 +1,24 @@
|
||||
/* Copyright (C) 2015
|
||||
* swift project community / contributors
|
||||
*
|
||||
* This file is part of swift project. It is subject to the license terms in the LICENSE file found in the top-level
|
||||
* directory of this distribution and at http://www.swift-project.org/license.html. No part of swift project,
|
||||
* including this file, may be copied, modified, propagated, or distributed except according to the terms
|
||||
* contained in the LICENSE file.
|
||||
*/
|
||||
|
||||
#include "registermetadata.h"
|
||||
#include "fs9_host.h"
|
||||
#include "fs9_client.h"
|
||||
|
||||
namespace BlackSimPlugin
|
||||
{
|
||||
namespace Fs9
|
||||
{
|
||||
void registerMetadata()
|
||||
{
|
||||
qRegisterMetaType<CFs9Host::HostStatus>();
|
||||
qRegisterMetaType<CFs9Client::ClientStatus>();
|
||||
}
|
||||
}
|
||||
}
|
||||
24
src/plugins/simulator/fs9/registermetadata.h
Normal file
24
src/plugins/simulator/fs9/registermetadata.h
Normal file
@@ -0,0 +1,24 @@
|
||||
/* Copyright (C) 2015
|
||||
* swift project community / contributors
|
||||
*
|
||||
* This file is part of swift project. It is subject to the license terms in the LICENSE file found in the top-level
|
||||
* directory of this distribution and at http://www.swift-project.org/license.html. No part of swift project,
|
||||
* including this file, may be copied, modified, propagated, or distributed except according to the terms
|
||||
* contained in the LICENSE file.
|
||||
*/
|
||||
|
||||
//! \file
|
||||
|
||||
#ifndef BLACKSIMPLUGIN_REGISTERMETADATA_H
|
||||
#define BLACKSIMPLUGIN_REGISTERMETADATA_H
|
||||
|
||||
namespace BlackSimPlugin
|
||||
{
|
||||
namespace Fs9
|
||||
{
|
||||
//! Register all relevant metadata in plugin
|
||||
void registerMetadata();
|
||||
} // ns
|
||||
} // ns
|
||||
|
||||
#endif // guard
|
||||
@@ -14,6 +14,7 @@
|
||||
#include "fs9_client.h"
|
||||
#include "multiplayer_packets.h"
|
||||
#include "multiplayer_packet_parser.h"
|
||||
#include "registermetadata.h"
|
||||
#include "blackcore/interpolator_linear.h"
|
||||
#include "blackmisc/simulation/simulatorplugininfo.h"
|
||||
#include "blackmisc/logmessage.h"
|
||||
|
||||
Reference in New Issue
Block a user