From 6de2c35e80bd14c498fb9931dac1d4d85ff06c47 Mon Sep 17 00:00:00 2001 From: Peter Feerick Date: Sat, 1 Oct 2022 19:30:33 +1000 Subject: [PATCH] fix: "Show Channel Monitor" btn only on touch only radios Resurrecting evil PCBNV14 define as @raphaelcoeffic said he'd quit if he had to keep scrolling past the "show channel monitor" button --- radio/src/gui/colorlcd/menu_model.cpp | 6 +++++- radio/src/gui/colorlcd/menu_model.h | 2 ++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/radio/src/gui/colorlcd/menu_model.cpp b/radio/src/gui/colorlcd/menu_model.cpp index e76f42ad9..a2f255027 100644 --- a/radio/src/gui/colorlcd/menu_model.cpp +++ b/radio/src/gui/colorlcd/menu_model.cpp @@ -61,7 +61,9 @@ ModelMenu::ModelMenu(): #endif addTab(new ModelTelemetryPage()); +#if defined(PCBNV14) || defined(PCBPL18) addGoToMonitorsButton(); +#endif } void ModelMenu::onEvent(event_t event) @@ -76,6 +78,7 @@ void ModelMenu::onEvent(event_t event) #endif } +#if defined(PCBNV14) || defined(PCBPL18) void ModelMenu::addGoToMonitorsButton() { OpenTxTheme::instance()->createTextButton( @@ -84,4 +87,5 @@ void ModelMenu::addGoToMonitorsButton() pushEvent(EVT_KEY_FIRST(KEY_MODEL)); return 0; }); -} \ No newline at end of file +} +#endif diff --git a/radio/src/gui/colorlcd/menu_model.h b/radio/src/gui/colorlcd/menu_model.h index 57e85cfe0..c0b59eaa9 100644 --- a/radio/src/gui/colorlcd/menu_model.h +++ b/radio/src/gui/colorlcd/menu_model.h @@ -35,8 +35,10 @@ class ModelMenu : public TabsGroup std::string getName() const override { return "ModelMenu"; } #endif +#if defined(PCBNV14) || defined(PCBPL18) protected: void addGoToMonitorsButton(void); +#endif }; #endif // _MENU_MODEL_H_