|
QGroundControl
Ground Control Station for MAVLink Drones
|
#include <ComponentInformationTranslation.h>
Inheritance diagram for ComponentInformationTranslation:
Collaboration diagram for ComponentInformationTranslation:Signals | |
| void | downloadComplete (QString translatedJsonTempFile, QString errorMsg) |
Public Member Functions | |
| ComponentInformationTranslation (QObject *parent, QGCCachedFileDownload *cachedFileDownload) | |
| bool | downloadAndTranslate (const QString &summaryJsonFile, const QString &toTranslateJsonFile, int maxCacheAgeSec, const QString &componentName) |
| QString | translateJsonUsingTS (const QString &toTranslateJsonFile, const QString &tsFile) |
Definition at line 13 of file ComponentInformationTranslation.h.
| ComponentInformationTranslation::ComponentInformationTranslation | ( | QObject * | parent, |
| QGCCachedFileDownload * | cachedFileDownload | ||
| ) |
Definition at line 15 of file ComponentInformationTranslation.cc.
| bool ComponentInformationTranslation::downloadAndTranslate | ( | const QString & | summaryJsonFile, |
| const QString & | toTranslateJsonFile, | ||
| int | maxCacheAgeSec, | ||
| const QString & | componentName | ||
| ) |
Download translation file according to the currently set locale and translate the json file. emits downloadComplete() when done (with a temporary file that should be deleted)
| summaryJsonFile | json file with url's to translation files (.ts) |
| toTranslateJsonFile | json file to be translated |
| maxCacheAgeSec | Maximum age of cached item in seconds |
Definition at line 21 of file ComponentInformationTranslation.cc.
References QGCCachedFileDownload::download(), and QGCCachedFileDownload::finished().
|
signal |
| QString ComponentInformationTranslation::translateJsonUsingTS | ( | const QString & | toTranslateJsonFile, |
| const QString & | tsFile | ||
| ) |
Definition at line 105 of file ComponentInformationTranslation.cc.
References errorString, and JsonParsing::isJsonFile().