mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-04 16:56:53 +08:00
DBus: track, heading, transponder. Added I18N for track/heading, added further I18N keys. Of course not all I18N strings are translated yet.
This commit is contained in:
@@ -27,7 +27,25 @@ protected:
|
||||
* \brief Specific stream operation for Track
|
||||
* \return
|
||||
*/
|
||||
virtual QString stringForConverter() const;
|
||||
virtual QString stringForConverter(bool i18n = false) const;
|
||||
|
||||
/*!
|
||||
* \brief Stream to DBus <<
|
||||
* \param argument
|
||||
*/
|
||||
virtual void marshallToDbus(QDBusArgument &argument) const {
|
||||
CAngle::marshallToDbus(argument);
|
||||
argument << this->m_magnetic;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Stream from DBus >>
|
||||
* \param argument
|
||||
*/
|
||||
virtual void unmarshallFromDbus(const QDBusArgument &argument) {
|
||||
CAngle::unmarshallFromDbus(argument);
|
||||
argument >> this->m_magnetic;
|
||||
}
|
||||
|
||||
public:
|
||||
/*!
|
||||
@@ -85,7 +103,10 @@ public:
|
||||
*/
|
||||
bool isMagneticTrack() const {
|
||||
return this->m_magnetic;
|
||||
QT_TRANSLATE_NOOP("Aviation", "magnetic");
|
||||
QT_TRANSLATE_NOOP("Aviation", "true");
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief True Track?
|
||||
* \return
|
||||
@@ -93,10 +114,17 @@ public:
|
||||
bool isTrueTrack() const {
|
||||
return !this->m_magnetic;
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Register metadata
|
||||
*/
|
||||
static void registerMetadata();
|
||||
};
|
||||
|
||||
} // namespace
|
||||
|
||||
} // namespace
|
||||
|
||||
Q_DECLARE_METATYPE(BlackMisc::Aviation::CTrack)
|
||||
|
||||
#endif // BLACKMISC_AVTRACK_H
|
||||
|
||||
Reference in New Issue
Block a user