From d74c6acc0bf6989df231dfa4a78ef78574f3d8b2 Mon Sep 17 00:00:00 2001 From: Kilrah Date: Mon, 11 Jun 2018 23:01:50 +0200 Subject: [PATCH] We can now know what radio a random file comes from a little more easily... --- companion/src/firmwares/boards.cpp | 11 +++++------ companion/src/firmwares/boards.h | 1 + companion/src/mdichild.cpp | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/companion/src/firmwares/boards.cpp b/companion/src/firmwares/boards.cpp index dfdcae256..c6ac946ec 100644 --- a/companion/src/firmwares/boards.cpp +++ b/companion/src/firmwares/boards.cpp @@ -384,8 +384,6 @@ const bool Boards::isBoardCompatible(Type board1, Type board2) return (getFourCC(board1) == getFourCC(board2)); } -/* Currently unused - const QString Boards::getBoardName(Board::Type board) { switch (board) { @@ -398,7 +396,9 @@ const QString Boards::getBoardName(Board::Type board) case BOARD_MEGA2560: return "MEGA2560"; case BOARD_TARANIS_X7: - return "Taranis X7"; + return "Taranis X7/X7S"; + case BOARD_TARANIS_XLITE: + return "Taranis X-Lite"; case BOARD_TARANIS_X9D: return "Taranis X9D"; case BOARD_TARANIS_X9DP: @@ -412,11 +412,10 @@ const QString Boards::getBoardName(Board::Type board) case BOARD_AR9X: return "AR9X"; case BOARD_X12S: - return "Horus"; + return "Horus X12S"; case BOARD_X10: - return "X10"; + return "Horus X10/X10S"; default: return tr("Unknown"); } } -*/ diff --git a/companion/src/firmwares/boards.h b/companion/src/firmwares/boards.h index 603d0dd9a..ce9dafe5a 100644 --- a/companion/src/firmwares/boards.h +++ b/companion/src/firmwares/boards.h @@ -170,6 +170,7 @@ class Boards static const QString getAxisName(int index); static const QString getAnalogInputName(Board::Type board, unsigned index); static const bool isBoardCompatible(Board::Type board1, Board::Type board2); + static const QString getBoardName(Board::Type board); protected: diff --git a/companion/src/mdichild.cpp b/companion/src/mdichild.cpp index 12bfe1489..74763794d 100644 --- a/companion/src/mdichild.cpp +++ b/companion/src/mdichild.cpp @@ -1452,7 +1452,7 @@ bool MdiChild::convertStorage(Board::Type from, Board::Type to, bool newFile) { QMessageBox::StandardButtons btns; QMessageBox::StandardButton dfltBtn; - QString q = tr("

Current radio type is not compatible with file %1, models and settings need to be converted.

").arg(userFriendlyCurrentFile()); + QString q = tr("

Currently selected radio type (%1) is not compatible with file %3 (from %2), models and settings need to be converted.

").arg(Boards::getBoardName(to)).arg(Boards::getBoardName(from)).arg(userFriendlyCurrentFile()); if (newFile) { q.append(tr("Do you wish to continue with the conversion?")); btns = (QMessageBox::Yes | QMessageBox::No);