From 1bf2af9f0d7eec46cd420a6d61d8a55376aa72c5 Mon Sep 17 00:00:00 2001 From: philmoz Date: Thu, 30 Oct 2025 20:20:07 +1100 Subject: [PATCH] feat(color): channel monitor only shows active channels, page buttons if more pages (#6732) --- .../gui/colorlcd/mainview/view_channels.cpp | 88 ++++++++++++++----- .../gui/colorlcd/setup_menus/pagegroup.cpp | 17 +++- .../src/gui/colorlcd/setup_menus/pagegroup.h | 2 + radio/src/gui/gui_common.h | 1 + radio/src/translations/i18n/cn.h | 5 +- radio/src/translations/i18n/cz.h | 5 +- radio/src/translations/i18n/da.h | 5 +- radio/src/translations/i18n/de.h | 5 +- radio/src/translations/i18n/en.h | 5 +- radio/src/translations/i18n/es.h | 5 +- radio/src/translations/i18n/fi.h | 5 +- radio/src/translations/i18n/fr.h | 5 +- radio/src/translations/i18n/he.h | 5 +- radio/src/translations/i18n/it.h | 5 +- radio/src/translations/i18n/jp.h | 5 +- radio/src/translations/i18n/ko.h | 5 +- radio/src/translations/i18n/nl.h | 5 +- radio/src/translations/i18n/pl.h | 5 +- radio/src/translations/i18n/pt.h | 5 +- radio/src/translations/i18n/ru.h | 5 +- radio/src/translations/i18n/se.h | 5 +- radio/src/translations/i18n/tw.h | 5 +- radio/src/translations/i18n/ua.h | 5 +- radio/src/translations/string_list.h | 2 +- radio/src/translations/translation_def.h | 1 - 25 files changed, 103 insertions(+), 103 deletions(-) diff --git a/radio/src/gui/colorlcd/mainview/view_channels.cpp b/radio/src/gui/colorlcd/mainview/view_channels.cpp index a6df91fff..410c36c98 100644 --- a/radio/src/gui/colorlcd/mainview/view_channels.cpp +++ b/radio/src/gui/colorlcd/mainview/view_channels.cpp @@ -32,8 +32,7 @@ class ChannelsViewFooter : public Window { public: explicit ChannelsViewFooter(Window* parent) : - Window(parent, {0, parent->height() - LEG_COLORBOX - PAD_SMALL * 2 - 2, LCD_W, - LEG_COLORBOX + PAD_SMALL * 2 + 2}) + Window(parent, {0, parent->height() - FOOTER_H, LCD_W, FOOTER_H}) { etx_solid_bg(lvobj, COLOR_THEME_SECONDARY1_INDEX); @@ -62,6 +61,7 @@ class ChannelsViewFooter : public Window static LAYOUT_VAL_SCALED(LEG_COLORBOX, 14) static LAYOUT_VAL_SCALED(TXT_H, 18) + static constexpr coord_t FOOTER_H = LEG_COLORBOX + PAD_SMALL * 2 + PAD_TINY; }; //----------------------------------------------------------------------------- @@ -69,36 +69,45 @@ class ChannelsViewFooter : public Window class ChannelsViewPage : public PageGroupItem { public: - explicit ChannelsViewPage(uint8_t pageIndex = 0) : - PageGroupItem(STR_MONITOR_CHANNELS[pageIndex]), - pageIndex(pageIndex) + explicit ChannelsViewPage(uint8_t startChan, int rows, int cols, const char* title) : + PageGroupItem(title), startChan(startChan), rows(rows), cols(cols) { icon = ICON_MONITOR; } + static constexpr coord_t CHANS_H = 3 * ChannelBar::BAR_HEIGHT + PAD_THREE; + protected: - uint8_t pageIndex = 0; + uint8_t startChan; + int rows; + int cols; void build(Window* window) override { - constexpr coord_t hmargin = PAD_SMALL; window->padAll(PAD_ZERO); - // Channels bars - for (uint8_t chan = pageIndex * 8; chan < 8 + pageIndex * 8; chan++) { #if PORTRAIT - coord_t width = window->width() - (hmargin * 2); - coord_t xPos = hmargin; - coord_t yPos = (chan % 8) * - ((window->height() - PAD_LARGE* 3) / 8); + coord_t w = window->width() - (PAD_SMALL * 2); #else - coord_t width = window->width() / 2 - (hmargin * 2); - coord_t xPos = (chan % 8) >= 4 ? width + (hmargin * 2) : hmargin; - coord_t yPos = (chan % 4) * - ((window->height() - (PAD_LARGE * 3 - 1)) / 4); + coord_t w = window->width() / 2 - (PAD_SMALL * 2); #endif - new ComboChannelBar(window, {xPos, yPos, width, 3 * ChannelBar::BAR_HEIGHT + PAD_THREE}, - chan); + + // Channels bars + for (uint8_t i = 0, j = 0; j < rows * cols; i += 1) { + uint8_t chan = startChan + i; + if (chan >= MAX_OUTPUT_CHANNELS) break; + if (isChannelUsed(chan)) { +#if PORTRAIT + coord_t xPos = PAD_SMALL; + coord_t yPos = j * ((window->height() - PAD_LARGE * 3) / rows); +#else + coord_t xPos = (j & 1) ? w + (PAD_SMALL * 2) : PAD_SMALL; + coord_t yPos = (j / cols) * ((window->height() - ChannelsViewFooter::FOOTER_H) / rows); +#endif + new ComboChannelBar(window, {xPos, yPos, w, CHANS_H}, chan); + + j += 1; + } } // Footer @@ -113,8 +122,41 @@ ChannelsViewMenu::ChannelsViewMenu() : { QuickMenu::setCurrentPage(QuickMenu::TOOLS_CHAN_MON); - addTab(new ChannelsViewPage(0)); - addTab(new ChannelsViewPage(1)); - addTab(new ChannelsViewPage(2)); - addTab(new ChannelsViewPage(3)); +#if PORTRAIT + int cols = 1; + int rows = 8; +#else + int cols = 2; + int rows = (LCD_H - EdgeTxStyles::MENU_HEADER_HEIGHT - ChannelsViewFooter::FOOTER_H) / ChannelsViewPage::CHANS_H; +#endif + + int pages = 0; + int chansPerPage = rows * cols; + + char s[50]; + + for (int i = 0; i < MAX_OUTPUT_CHANNELS;) { + int start = i; + while (!isChannelUsed(start)) { + start += 1; + if (start >= MAX_OUTPUT_CHANNELS) break; + } + if (start >= MAX_OUTPUT_CHANNELS) break; + int count = 1; + int last = start; + int end = start + 1; + while (end < MAX_OUTPUT_CHANNELS && count < chansPerPage) { + if (isChannelUsed(end)) { + count += 1; + last = end; + } + end += 1; + } + sprintf(s, STR_MONITOR_CHANNELS, start + 1, last + 1); + addTab(new ChannelsViewPage(start, rows, cols, s)); + pages += 1; + i = end; + } + + if (pages < 2) hidePageButtons(); } diff --git a/radio/src/gui/colorlcd/setup_menus/pagegroup.cpp b/radio/src/gui/colorlcd/setup_menus/pagegroup.cpp index 827220897..028c0a3d8 100644 --- a/radio/src/gui/colorlcd/setup_menus/pagegroup.cpp +++ b/radio/src/gui/colorlcd/setup_menus/pagegroup.cpp @@ -381,12 +381,12 @@ class TabsGroupHeader : public PageGroupHeaderBase lv_obj_set_size(titleLabel, LCD_W, TabsGroup::PAGE_ALT_TITLE_H); #endif - new IconButton(this, ICON_BTN_PREV, LCD_W - PageGroup::PAGE_TOP_BAR_H * 3, PAD_MEDIUM, [=]() { + prevBtn = new IconButton(this, ICON_BTN_PREV, LCD_W - PageGroup::PAGE_TOP_BAR_H * 3, PAD_MEDIUM, [=]() { prevTab(); return 0; }); - new IconButton(this, ICON_BTN_NEXT, LCD_W - PageGroup::PAGE_TOP_BAR_H * 2, PAD_MEDIUM, [=]() { + nextBtn = new IconButton(this, ICON_BTN_NEXT, LCD_W - PageGroup::PAGE_TOP_BAR_H * 2, PAD_MEDIUM, [=]() { nextTab(); return 0; }); @@ -405,7 +405,15 @@ class TabsGroupHeader : public PageGroupHeaderBase menu->setCurrentTab(idx); } + void hidePageButtons() + { + if (prevBtn) prevBtn->hide(); + if (nextBtn) nextBtn->hide(); + } + protected: + IconButton* nextBtn = nullptr; + IconButton* prevBtn = nullptr; }; //----------------------------------------------------------------------------- @@ -444,3 +452,8 @@ void TabsGroup::openMenu() } }, p, subMenu); } + +void TabsGroup::hidePageButtons() +{ + ((TabsGroupHeader*)header)->hidePageButtons(); +} diff --git a/radio/src/gui/colorlcd/setup_menus/pagegroup.h b/radio/src/gui/colorlcd/setup_menus/pagegroup.h index 61e921683..be6a3c25b 100644 --- a/radio/src/gui/colorlcd/setup_menus/pagegroup.h +++ b/radio/src/gui/colorlcd/setup_menus/pagegroup.h @@ -218,6 +218,8 @@ class TabsGroup : public PageGroupBase std::string getName() const override { return "TabsGroup"; } #endif + void hidePageButtons(); + static LAYOUT_ORIENTATION_SCALED(PAGE_TOP_BAR_H, 45, 48) static LAYOUT_ORIENTATION(PAGE_ALT_TITLE_H, 0, EdgeTxStyles::STD_FONT_HEIGHT) static constexpr coord_t TABS_GROUP_BODY_Y = PAGE_TOP_BAR_H + PAGE_ALT_TITLE_H; diff --git a/radio/src/gui/gui_common.h b/radio/src/gui/gui_common.h index dea397a31..7effb8875 100644 --- a/radio/src/gui/gui_common.h +++ b/radio/src/gui/gui_common.h @@ -53,6 +53,7 @@ enum SwitchContext int getFirstAvailable(int min, int max, IsValueAvailable isValueAvailable); +bool isChannelUsed(int channel); bool checkSourceAvailable(int source, uint32_t sourceTypes); bool checkSwitchAvailable(int swtch, uint32_t swtchTypes); bool isInputAvailable(int input); diff --git a/radio/src/translations/i18n/cn.h b/radio/src/translations/i18n/cn.h index d7fdda416..01e1d86c2 100644 --- a/radio/src/translations/i18n/cn.h +++ b/radio/src/translations/i18n/cn.h @@ -664,10 +664,7 @@ #define TR_MENULOGICALSWITCH "逻辑开关" #define TR_MENUSTAT "统计" #define TR_MENUDEBUG "Debug" -#define TR_MONITOR_CHANNELS1 "1-8通道查看" -#define TR_MONITOR_CHANNELS2 "9-16通道查看" -#define TR_MONITOR_CHANNELS3 "17-24通道查看" -#define TR_MONITOR_CHANNELS4 "25-32通道查看" +#define TR_MONITOR_CHANNELS "%d-%d通道查看" #define TR_MONITOR_OUTPUT_DESC "输出查看" #define TR_MONITOR_MIXER_DESC "混控查看" #define TR_RECEIVER_NUM TR("RxNum", "接收机编号") diff --git a/radio/src/translations/i18n/cz.h b/radio/src/translations/i18n/cz.h index 39b332352..ef7d42946 100644 --- a/radio/src/translations/i18n/cz.h +++ b/radio/src/translations/i18n/cz.h @@ -669,10 +669,7 @@ #define TR_MENULOGICALSWITCH "LOG. SPÍNAČ" #define TR_MENUSTAT "STATISTIKA" #define TR_MENUDEBUG "DIAG" -#define TR_MONITOR_CHANNELS1 "MONITOR KANÁLŮ 1/8" -#define TR_MONITOR_CHANNELS2 "MONITOR KANÁLŮ 9/16" -#define TR_MONITOR_CHANNELS3 "MONITOR KANÁLŮ 17/24" -#define TR_MONITOR_CHANNELS4 "MONITOR KANÁLŮ 25/32" +#define TR_MONITOR_CHANNELS "MONITOR KANÁLŮ %d/%d" #define TR_MONITOR_OUTPUT_DESC "Výstupy" #define TR_MONITOR_MIXER_DESC "Mixy" #define TR_RECEIVER_NUM TR("RX číslo", "Číslo přijímače") diff --git a/radio/src/translations/i18n/da.h b/radio/src/translations/i18n/da.h index ec17c2c9c..4ca600fdc 100644 --- a/radio/src/translations/i18n/da.h +++ b/radio/src/translations/i18n/da.h @@ -669,10 +669,7 @@ #define TR_MENULOGICALSWITCH "LOGISK FUNKTION" #define TR_MENUSTAT "STAT" #define TR_MENUDEBUG "DEBUG" -#define TR_MONITOR_CHANNELS1 "KANAL MONITOR 1-8" -#define TR_MONITOR_CHANNELS2 "KANAL MONITOR 9-16" -#define TR_MONITOR_CHANNELS3 "KANAL MONITOR 17-24" -#define TR_MONITOR_CHANNELS4 "KANAL MONITOR 25-32" +#define TR_MONITOR_CHANNELS "KANAL MONITOR %d-%d" #define TR_MONITOR_OUTPUT_DESC "Udgange" #define TR_MONITOR_MIXER_DESC "Mix" #define TR_RECEIVER_NUM TR("RxNr", "Rx modtager Nr.") diff --git a/radio/src/translations/i18n/de.h b/radio/src/translations/i18n/de.h index cae7dff12..59a46d9ac 100644 --- a/radio/src/translations/i18n/de.h +++ b/radio/src/translations/i18n/de.h @@ -665,10 +665,7 @@ #define TR_MENULOGICALSWITCH "LOGIKSCHALTER" #define TR_MENUSTAT "STAT" #define TR_MENUDEBUG "DEBUG" -#define TR_MONITOR_CHANNELS1 "KANAL+MISCHER MONITOR 1-8" -#define TR_MONITOR_CHANNELS2 "KANAL+MISCHER MONITOR 9-16" -#define TR_MONITOR_CHANNELS3 "KANAL+MISCHER MONITOR 17-24" -#define TR_MONITOR_CHANNELS4 "KANAL+MISCHER MONITOR 25-32" +#define TR_MONITOR_CHANNELS "KANAL+MISCHER MONITOR %d-%d" #define TR_MONITOR_OUTPUT_DESC "Kanäle" #define TR_MONITOR_MIXER_DESC "Mischer" #define TR_RECEIVER_NUM TR("Empf Nr.", "Empfänger Nummer") diff --git a/radio/src/translations/i18n/en.h b/radio/src/translations/i18n/en.h index 80d6edff7..d247192a1 100644 --- a/radio/src/translations/i18n/en.h +++ b/radio/src/translations/i18n/en.h @@ -665,10 +665,7 @@ #define TR_MENULOGICALSWITCH "LOGICAL SWITCH" #define TR_MENUSTAT "STATS" #define TR_MENUDEBUG "DEBUG" -#define TR_MONITOR_CHANNELS1 "CHANNELS 1-8" -#define TR_MONITOR_CHANNELS2 "CHANNELS 9-16" -#define TR_MONITOR_CHANNELS3 "CHANNELS 17-24" -#define TR_MONITOR_CHANNELS4 "CHANNELS 25-32" +#define TR_MONITOR_CHANNELS "CHANNELS %d-%d" #define TR_MONITOR_OUTPUT_DESC "Outputs" #define TR_MONITOR_MIXER_DESC "Mixers" #define TR_RECEIVER_NUM TR("RxNum", "Receiver No.") diff --git a/radio/src/translations/i18n/es.h b/radio/src/translations/i18n/es.h index a7718331c..93b310955 100644 --- a/radio/src/translations/i18n/es.h +++ b/radio/src/translations/i18n/es.h @@ -664,10 +664,7 @@ #define TR_MENULOGICALSWITCH "INTERRUP.LÓGICO" #define TR_MENUSTAT TR("ESTAD.", "ESTADÍSTICAS") #define TR_MENUDEBUG "DEBUG" -#define TR_MONITOR_CHANNELS1 "MONITOR CANALES 1/8" -#define TR_MONITOR_CHANNELS2 "MONITOR CANALES 9/16" -#define TR_MONITOR_CHANNELS3 "MONITOR CANALES 17/24" -#define TR_MONITOR_CHANNELS4 "MONITOR CANALES 25/32" +#define TR_MONITOR_CHANNELS "MONITOR CANALES %d/%d" #define TR_MONITOR_OUTPUT_DESC "SALIDAS" #define TR_MONITOR_MIXER_DESC "Mixers" #define TR_RECEIVER_NUM TR("Num Rx", "Receptor No.") diff --git a/radio/src/translations/i18n/fi.h b/radio/src/translations/i18n/fi.h index a72591a55..f5a19d352 100644 --- a/radio/src/translations/i18n/fi.h +++ b/radio/src/translations/i18n/fi.h @@ -664,10 +664,7 @@ #define TR_MENULOGICALSWITCH "CUSTOM SWITCH" #define TR_MENUSTAT "STATS" #define TR_MENUDEBUG "DEBUG" -#define TR_MONITOR_CHANNELS1 "CHANNELS 1/8" -#define TR_MONITOR_CHANNELS2 "CHANNELS 9/16" -#define TR_MONITOR_CHANNELS3 "CHANNELS 17/24" -#define TR_MONITOR_CHANNELS4 "CHANNELS 25/32" +#define TR_MONITOR_CHANNELS "CHANNELS %d/%d" #define TR_MONITOR_OUTPUT_DESC "Outputs" #define TR_MONITOR_MIXER_DESC "Mixers" #define TR_RECEIVER_NUM TR("RxNum", "Receiver No.") diff --git a/radio/src/translations/i18n/fr.h b/radio/src/translations/i18n/fr.h index 5292b5abf..c279fc845 100644 --- a/radio/src/translations/i18n/fr.h +++ b/radio/src/translations/i18n/fr.h @@ -669,10 +669,7 @@ #define TR_MENULOGICALSWITCH "INTER LOG." #define TR_MENUSTAT TR("STATS", "STATISTIQUES") #define TR_MENUDEBUG "DEBUG" -#define TR_MONITOR_CHANNELS1 "VOIES 1-8" -#define TR_MONITOR_CHANNELS2 "VOIES 9-16" -#define TR_MONITOR_CHANNELS3 "VOIES 17-24" -#define TR_MONITOR_CHANNELS4 "VOIES 25-32" +#define TR_MONITOR_CHANNELS "VOIES %d-%d" #define TR_MONITOR_OUTPUT_DESC "Sorties" #define TR_MONITOR_MIXER_DESC "Mixeurs" #define TR_RECEIVER_NUM TR("NumRx", "No. Récepteur") diff --git a/radio/src/translations/i18n/he.h b/radio/src/translations/i18n/he.h index d60ce3b76..dddca76d9 100644 --- a/radio/src/translations/i18n/he.h +++ b/radio/src/translations/i18n/he.h @@ -667,10 +667,7 @@ #define TR_MENULOGICALSWITCH "מתג לוגי" #define TR_MENUSTAT "סטטוס" #define TR_MENUDEBUG "DEBUG" -#define TR_MONITOR_CHANNELS1 "מצגי ערוצים 8-1" -#define TR_MONITOR_CHANNELS2 "מצגי ערוצים 16-9" -#define TR_MONITOR_CHANNELS3 "מצגי ערוצים 24-17" -#define TR_MONITOR_CHANNELS4 "מצגי ערוצים 32-25" +#define TR_MONITOR_CHANNELS "מצגי ערוצים %d-%d" #define TR_MONITOR_OUTPUT_DESC "יציאות" #define TR_MONITOR_MIXER_DESC "מיקסרים" #define TR_RECEIVER_NUM TR("RxNum", "Receiver No.") diff --git a/radio/src/translations/i18n/it.h b/radio/src/translations/i18n/it.h index e22b695ac..d503c9d76 100644 --- a/radio/src/translations/i18n/it.h +++ b/radio/src/translations/i18n/it.h @@ -664,10 +664,7 @@ #define TR_MENULOGICALSWITCH "INTER. PERSON." #define TR_MENUSTAT "STATO" #define TR_MENUDEBUG "DEBUG" -#define TR_MONITOR_CHANNELS1 "MONITOR CANALI 1/8" -#define TR_MONITOR_CHANNELS2 "MONITOR CANALI 9/16" -#define TR_MONITOR_CHANNELS3 "MONITOR CANALI 17/24" -#define TR_MONITOR_CHANNELS4 "MONITOR CANALI 25/32" +#define TR_MONITOR_CHANNELS "MONITOR CANALI %d/%d" #define TR_MONITOR_OUTPUT_DESC "Uscite" #define TR_MONITOR_MIXER_DESC "Mixers" #define TR_RECEIVER_NUM TR("RxNum", "Ricevente N.") diff --git a/radio/src/translations/i18n/jp.h b/radio/src/translations/i18n/jp.h index 521798715..097d901c3 100644 --- a/radio/src/translations/i18n/jp.h +++ b/radio/src/translations/i18n/jp.h @@ -663,10 +663,7 @@ #define TR_MENULOGICALSWITCH "論理スイッチ" #define TR_MENUSTAT "統計" #define TR_MENUDEBUG "デバッグ" -#define TR_MONITOR_CHANNELS1 "チャンネルモニター 1-8" -#define TR_MONITOR_CHANNELS2 "チャンネルモニター 9-16" -#define TR_MONITOR_CHANNELS3 "チャンネルモニター 17-24" -#define TR_MONITOR_CHANNELS4 "チャンネルモニター 25-32" +#define TR_MONITOR_CHANNELS "チャンネルモニター %d-%d" #define TR_MONITOR_OUTPUT_DESC "出力" #define TR_MONITOR_MIXER_DESC "ミキサー" #define TR_RECEIVER_NUM TR("RxNum", "受信機 No.") diff --git a/radio/src/translations/i18n/ko.h b/radio/src/translations/i18n/ko.h index 601538e1b..eb9deebbd 100644 --- a/radio/src/translations/i18n/ko.h +++ b/radio/src/translations/i18n/ko.h @@ -685,10 +685,7 @@ #define TR_MENUSTAT "통계" #define TR_MENUDEBUG "디버그" -#define TR_MONITOR_CHANNELS1 "채널 모니터 1-8" -#define TR_MONITOR_CHANNELS2 "채널 모니터 9-16" -#define TR_MONITOR_CHANNELS3 "채널 모니터 17-24" -#define TR_MONITOR_CHANNELS4 "채널 모니터 25-32" +#define TR_MONITOR_CHANNELS "채널 모니터 %d-%d" #define TR_MONITOR_OUTPUT_DESC "출력 상태" #define TR_MONITOR_MIXER_DESC "믹서 상태" diff --git a/radio/src/translations/i18n/nl.h b/radio/src/translations/i18n/nl.h index a35ae7694..7da4c8d64 100644 --- a/radio/src/translations/i18n/nl.h +++ b/radio/src/translations/i18n/nl.h @@ -666,10 +666,7 @@ #define TR_MENULOGICALSWITCH "LOGISCHE SCHAK." #define TR_MENUSTAT "STAT" #define TR_MENUDEBUG "DEBUG" -#define TR_MONITOR_CHANNELS1 "CHANNELS 1-8" -#define TR_MONITOR_CHANNELS2 "CHANNELS 9-16" -#define TR_MONITOR_CHANNELS3 "CHANNELS 17-24" -#define TR_MONITOR_CHANNELS4 "CHANNELS 25-32" +#define TR_MONITOR_CHANNELS "CHANNELS %d-%d" #define TR_MONITOR_OUTPUT_DESC "Outputs" #define TR_MONITOR_MIXER_DESC "Mixers" #define TR_RECEIVER_NUM TR("RxNum", "Receiver Nr.") diff --git a/radio/src/translations/i18n/pl.h b/radio/src/translations/i18n/pl.h index 8baaeae23..c76c5fbc9 100644 --- a/radio/src/translations/i18n/pl.h +++ b/radio/src/translations/i18n/pl.h @@ -663,10 +663,7 @@ #define TR_MENULOGICALSWITCH "PRZEŁ. LOGICZNY" #define TR_MENUSTAT "STAT" #define TR_MENUDEBUG "DEBUG" -#define TR_MONITOR_CHANNELS1 "MONITOR KANAŁÓW 1/8" -#define TR_MONITOR_CHANNELS2 "MONITOR KANAŁÓW 9/16" -#define TR_MONITOR_CHANNELS3 "MONITOR KANAŁÓW 17/24" -#define TR_MONITOR_CHANNELS4 "MONITOR KANAŁÓW 25/32" +#define TR_MONITOR_CHANNELS "MONITOR KANAŁÓW %d/%d" #define TR_MONITOR_OUTPUT_DESC "Wyjścia" #define TR_MONITOR_MIXER_DESC "Mixers" #define TR_RECEIVER_NUM TR("Nr RX", "Nr odbiornika") diff --git a/radio/src/translations/i18n/pt.h b/radio/src/translations/i18n/pt.h index f1f5ca23e..248d8f10f 100644 --- a/radio/src/translations/i18n/pt.h +++ b/radio/src/translations/i18n/pt.h @@ -664,10 +664,7 @@ #define TR_MENULOGICALSWITCH "CHAVE LÓGICA" #define TR_MENUSTAT "STATS" #define TR_MENUDEBUG "DEBUG" -#define TR_MONITOR_CHANNELS1 "MONITOR CANAIS 1-8" -#define TR_MONITOR_CHANNELS2 "MONITOR CANAIS 9-16" -#define TR_MONITOR_CHANNELS3 "MONITOR CANAIS 17-24" -#define TR_MONITOR_CHANNELS4 "MONITOR CANAIS 25-32" +#define TR_MONITOR_CHANNELS "MONITOR CANAIS %d-%d" #define TR_MONITOR_OUTPUT_DESC "Saídas" #define TR_MONITOR_MIXER_DESC "Mixers" #define TR_RECEIVER_NUM TR("# Rx", "# Recept") diff --git a/radio/src/translations/i18n/ru.h b/radio/src/translations/i18n/ru.h index e69700e75..ba4d5d11b 100644 --- a/radio/src/translations/i18n/ru.h +++ b/radio/src/translations/i18n/ru.h @@ -666,10 +666,7 @@ #define TR_MENULOGICALSWITCH "ЛОГИЧ ТУМБЛ." #define TR_MENUSTAT "СТАТИСТИКА" #define TR_MENUDEBUG "ОТЛАДКА" -#define TR_MONITOR_CHANNELS1 "МОНИТОР КАН 1-8" -#define TR_MONITOR_CHANNELS2 "МОНИТОР КАН 9-16" -#define TR_MONITOR_CHANNELS3 "МОНИТОР КАН 17-24" -#define TR_MONITOR_CHANNELS4 "МОНИТОР КАН 25-32" +#define TR_MONITOR_CHANNELS "МОНИТОР КАН %d-%d" #define TR_MONITOR_OUTPUT_DESC "Выходы" #define TR_MONITOR_MIXER_DESC "Микшеры" #define TR_RECEIVER_NUM TR("Rx Ном", "Номер") diff --git a/radio/src/translations/i18n/se.h b/radio/src/translations/i18n/se.h index 2cf1ec763..ccc2bacbe 100644 --- a/radio/src/translations/i18n/se.h +++ b/radio/src/translations/i18n/se.h @@ -669,10 +669,7 @@ #define TR_MENULOGICALSWITCH "LOGISK BRYTARE" #define TR_MENUSTAT "STATISTIK" #define TR_MENUDEBUG "DEBUG" -#define TR_MONITOR_CHANNELS1 "KANALÖVERSIKT - KA 1-8" -#define TR_MONITOR_CHANNELS2 "KANALÖVERSIKT - KA 9-16" -#define TR_MONITOR_CHANNELS3 "KANALÖVERSIKT - KA 17-24" -#define TR_MONITOR_CHANNELS4 "KANALÖVERSIKT - KA 25-32" +#define TR_MONITOR_CHANNELS "KANALÖVERSIKT - KA %d-%d" #define TR_MONITOR_OUTPUT_DESC "Utdata" #define TR_MONITOR_MIXER_DESC "Mixar" #define TR_RECEIVER_NUM TR("RxNum","Mottagare nr.") diff --git a/radio/src/translations/i18n/tw.h b/radio/src/translations/i18n/tw.h index 2d62b0114..6ff7e7e48 100644 --- a/radio/src/translations/i18n/tw.h +++ b/radio/src/translations/i18n/tw.h @@ -661,10 +661,7 @@ #define TR_MENULOGICALSWITCH "邏輯開關" #define TR_MENUSTAT "統計" #define TR_MENUDEBUG "Debug" -#define TR_MONITOR_CHANNELS1 "1-8通道查看" -#define TR_MONITOR_CHANNELS2 "9-16通道查看" -#define TR_MONITOR_CHANNELS3 "17-24通道查看" -#define TR_MONITOR_CHANNELS4 "25-32通道查看" +#define TR_MONITOR_CHANNELS "%d-%d通道查看" #define TR_MONITOR_OUTPUT_DESC "輸出查看" #define TR_MONITOR_MIXER_DESC "混控查看" #define TR_RECEIVER_NUM TR("RxNum", "接收機ID.") diff --git a/radio/src/translations/i18n/ua.h b/radio/src/translations/i18n/ua.h index d8a7bab31..7f37f172e 100644 --- a/radio/src/translations/i18n/ua.h +++ b/radio/src/translations/i18n/ua.h @@ -665,10 +665,7 @@ #define TR_MENULOGICALSWITCH "ЛОГІЧНИЙ ПЕРЕМИКАЧ" #define TR_MENUSTAT "СТАТ." #define TR_MENUDEBUG "ВІДЛАГОДЖЕННЯ" -#define TR_MONITOR_CHANNELS1 "МОНІТОР КАН 1-8" -#define TR_MONITOR_CHANNELS2 "МОНІТОР КАН 9-16" -#define TR_MONITOR_CHANNELS3 "МОНІТОР КАН 17-24" -#define TR_MONITOR_CHANNELS4 "МОНІТОР КАН 25-32" +#define TR_MONITOR_CHANNELS "МОНІТОР КАН %d-%d" #define TR_MONITOR_OUTPUT_DESC "Виходи" #define TR_MONITOR_MIXER_DESC "Мікшери" #define TR_RECEIVER_NUM TR("RxNum", "No. приймача") diff --git a/radio/src/translations/string_list.h b/radio/src/translations/string_list.h index 4648f95a9..e69a69aa5 100644 --- a/radio/src/translations/string_list.h +++ b/radio/src/translations/string_list.h @@ -399,7 +399,7 @@ STR(POTWARNINGSTATE) STR(POTWARNING) STR(MENUSTAT) STR(MENUDEBUG) -STRARRAY(MONITOR_CHANNELS) +STR(MONITOR_CHANNELS) STR(MONITOR_SWITCHES) STR(MONITOR_OUTPUT_DESC) STR(MONITOR_MIXER_DESC) diff --git a/radio/src/translations/translation_def.h b/radio/src/translations/translation_def.h index e1104c711..8dd794663 100644 --- a/radio/src/translations/translation_def.h +++ b/radio/src/translations/translation_def.h @@ -98,7 +98,6 @@ #define TR_MULTI_DSM_OPTIONS DSM2_OPTION_SERVOFREQ_NAMES #define TR_MULTI_DSM_CLONE DSM_CLONE_NAMES -#define TR_MONITOR_CHANNELS TR_MONITOR_CHANNELS1, TR_MONITOR_CHANNELS2, TR_MONITOR_CHANNELS3, TR_MONITOR_CHANNELS4 #define TR_TIMER_MODES TR_OFFON,TR_START,TR_THROTTLE_LABEL,TR_THROTTLE_PERCENT_LABEL,TR_THROTTLE_START #define TR_PHASES_HEADERS TR_PHASES_HEADERS_NAME, TR_PHASES_HEADERS_SW, TR_PHASES_HEADERS_RUD_TRIM, TR_PHASES_HEADERS_ELE_TRIM, TR_PHASES_HEADERS_THT_TRIM, TR_PHASES_HEADERS_AIL_TRIM, TR_PHASES_HEADERS_FAD_IN, TR_PHASES_HEADERS_FAD_OUT #define TR_LIMITS_HEADERS TR_LIMITS_HEADERS_NAME, TR_LIMITS_HEADERS_SUBTRIM, TR_LIMITS_HEADERS_MIN, TR_LIMITS_HEADERS_MAX, TR_LIMITS_HEADERS_DIRECTION, TR_LIMITS_HEADERS_CURVE, TR_LIMITS_HEADERS_PPMCENTER, TR_LIMITS_HEADERS_SUBTRIMMODE