mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-05 17:35:34 +08:00
Style
This commit is contained in:
@@ -37,7 +37,7 @@ namespace BlackMisc
|
||||
//! Properties by index
|
||||
enum ColumnIndex
|
||||
{
|
||||
IndexStrobe = BlackMisc::CPropertyIndex::GlobalIndexCAircraftLights,
|
||||
IndexStrobe = CPropertyIndex::GlobalIndexCAircraftLights,
|
||||
IndexLanding,
|
||||
IndexTaxi,
|
||||
IndexBeacon,
|
||||
|
||||
@@ -69,10 +69,10 @@ namespace BlackMisc
|
||||
const CAircraftEngineList &engines, bool onGround);
|
||||
|
||||
//! \copydoc BlackMisc::Mixin::Index::propertyByIndex
|
||||
CVariant propertyByIndex(const BlackMisc::CPropertyIndex &index) const;
|
||||
CVariant propertyByIndex(const CPropertyIndex &index) const;
|
||||
|
||||
//! \copydoc BlackMisc::Mixin::Index::setPropertyByIndex
|
||||
void setPropertyByIndex(const BlackMisc::CPropertyIndex &index, const CVariant &variant);
|
||||
void setPropertyByIndex(const CPropertyIndex &index, const CVariant &variant);
|
||||
|
||||
//! Compare for index
|
||||
int comparePropertyByIndex(const CPropertyIndex &index, const CAircraftParts &compareValue) const;
|
||||
|
||||
@@ -109,7 +109,7 @@ namespace BlackMisc
|
||||
const int i = CSimConnectUtilities::staticMetaObject.indexOfEnumerator(enumName);
|
||||
if (i < 0) { return QString("No enumerator for %1").arg(enumName); }
|
||||
const QMetaEnum m = CSimConnectUtilities::staticMetaObject.enumerator(i);
|
||||
const char *k = m.valueToKey(id);
|
||||
const char *k = m.valueToKey(static_cast<int>(id));
|
||||
return (k) ? QLatin1String(k) : QString("Id '%1' not found for %2").arg(id).arg(enumName);
|
||||
}
|
||||
|
||||
|
||||
@@ -350,9 +350,7 @@ namespace BlackSimPlugin
|
||||
MultiPlayerPacketParser::readMessage(message, mpChatText);
|
||||
break;
|
||||
}
|
||||
|
||||
default:
|
||||
break;
|
||||
default: break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -56,8 +56,8 @@ namespace BlackSimPlugin
|
||||
double com2StandbyMHz; //!< COM1 standby frequency
|
||||
|
||||
double flapsHandlePosition; //!< Flaps handle position in percent
|
||||
double spoilersHandlePosition; //!< Spoilers out?
|
||||
double gearHandlePosition; //!< Gear handle position
|
||||
double spoilersHandlePosition; //!< Spoilers out? (flag)
|
||||
double gearHandlePosition; //!< Gear handle position (flag)
|
||||
|
||||
double numberOfEngines; //!< Number of engines
|
||||
double engine1Combustion; //!< Engine 1 combustion flag
|
||||
|
||||
@@ -225,9 +225,9 @@ namespace BlackSimPlugin
|
||||
switch (message.getSeverity())
|
||||
{
|
||||
case CStatusMessage::SeverityDebug: return;
|
||||
case CStatusMessage::SeverityInfo: type = SIMCONNECT_TEXT_TYPE_PRINT_GREEN; break;
|
||||
case CStatusMessage::SeverityInfo: type = SIMCONNECT_TEXT_TYPE_PRINT_GREEN; break;
|
||||
case CStatusMessage::SeverityWarning: type = SIMCONNECT_TEXT_TYPE_PRINT_YELLOW; break;
|
||||
case CStatusMessage::SeverityError: type = SIMCONNECT_TEXT_TYPE_PRINT_RED; break;
|
||||
case CStatusMessage::SeverityError: type = SIMCONNECT_TEXT_TYPE_PRINT_RED; break;
|
||||
}
|
||||
const HRESULT hr = SimConnect_Text(m_hSimConnect, type, 7.5, EventTextMessage, static_cast<DWORD>(m.size()), m.data());
|
||||
Q_UNUSED(hr);
|
||||
|
||||
Reference in New Issue
Block a user