diff --git a/radio/src/gui/colorlcd/layouts/layout1x1.cpp b/radio/src/gui/colorlcd/layouts/layout1x1.cpp index 13dcf0cd1..e287c1a3f 100644 --- a/radio/src/gui/colorlcd/layouts/layout1x1.cpp +++ b/radio/src/gui/colorlcd/layouts/layout1x1.cpp @@ -21,12 +21,6 @@ #include "opentx.h" #include "trims.h" -#define HAS_TOPBAR() (persistentData->options[0].value.boolValue == true) -#define HAS_FM() (persistentData->options[1].value.boolValue == true) -#define HAS_SLIDERS() (persistentData->options[2].value.boolValue == true) -#define HAS_TRIMS() (persistentData->options[3].value.boolValue == true) -#define IS_MIRRORED() (persistentData->options[4].value.boolValue == true) - constexpr coord_t border = 10; const uint8_t LBM_LAYOUT_1x1[] = { diff --git a/radio/src/gui/colorlcd/layouts/layout2+1.cpp b/radio/src/gui/colorlcd/layouts/layout2+1.cpp index e99b09291..449cc4d82 100644 --- a/radio/src/gui/colorlcd/layouts/layout2+1.cpp +++ b/radio/src/gui/colorlcd/layouts/layout2+1.cpp @@ -22,12 +22,6 @@ #include "sliders.h" #include "trims.h" -#define HAS_TOPBAR() (persistentData->options[0].value.boolValue == true) -#define HAS_FM() (persistentData->options[1].value.boolValue == true) -#define HAS_SLIDERS() (persistentData->options[2].value.boolValue == true) -#define HAS_TRIMS() (persistentData->options[3].value.boolValue == true) -#define IS_MIRRORED() (persistentData->options[4].value.boolValue == true) - constexpr coord_t border = 10; const uint8_t LBM_LAYOUT_2P1[] = { @@ -66,7 +60,7 @@ class Layout2P1: public Layout rect_t getZone(unsigned int index) const override { - if (IS_MIRRORED()) + if (isMirrored()) index = 2 - index; rect_t zone = getMainZone({border, border, LCD_W - 2 * border, LCD_H - 2 * border}); diff --git a/radio/src/gui/colorlcd/layouts/layout2x1.cpp b/radio/src/gui/colorlcd/layouts/layout2x1.cpp index 1e1e078ad..71509cdf6 100644 --- a/radio/src/gui/colorlcd/layouts/layout2x1.cpp +++ b/radio/src/gui/colorlcd/layouts/layout2x1.cpp @@ -22,12 +22,6 @@ #include "sliders.h" #include "trims.h" -#define HAS_TOPBAR() (persistentData->options[0].value.boolValue == true) -#define HAS_FM() (persistentData->options[1].value.boolValue == true) -#define HAS_SLIDERS() (persistentData->options[2].value.boolValue == true) -#define HAS_TRIMS() (persistentData->options[3].value.boolValue == true) -#define IS_MIRRORED() (persistentData->options[4].value.boolValue == true) - constexpr coord_t border = 10; const uint8_t LBM_LAYOUT_2x1[] = { @@ -66,7 +60,7 @@ class Layout2x1: public Layout rect_t getZone(unsigned int index) const override { - if (IS_MIRRORED()) + if (isMirrored()) index = 1 - index; rect_t zone = getMainZone({border, border, LCD_W - 2 * border, LCD_H - 2 * border}); diff --git a/radio/src/gui/colorlcd/layouts/layout2x2.cpp b/radio/src/gui/colorlcd/layouts/layout2x2.cpp index 5ee745a43..aba64d808 100644 --- a/radio/src/gui/colorlcd/layouts/layout2x2.cpp +++ b/radio/src/gui/colorlcd/layouts/layout2x2.cpp @@ -22,12 +22,6 @@ #include "sliders.h" #include "trims.h" -#define HAS_TOPBAR() (persistentData->options[0].value.boolValue == true) -#define HAS_FM() (persistentData->options[1].value.boolValue == true) -#define HAS_SLIDERS() (persistentData->options[2].value.boolValue == true) -#define HAS_TRIMS() (persistentData->options[3].value.boolValue == true) -#define IS_MIRRORED() (persistentData->options[4].value.boolValue == true) - constexpr coord_t border = 10; const uint8_t LBM_LAYOUT_2x2[] = { @@ -66,7 +60,7 @@ class Layout2x2: public Layout rect_t getZone(unsigned int index) const override { - if (IS_MIRRORED()) + if (isMirrored()) index = 3 - index; rect_t zone = getMainZone({border, border, LCD_W - 2 * border, LCD_H - 2 * border}); diff --git a/radio/src/gui/colorlcd/layouts/layout2x4.cpp b/radio/src/gui/colorlcd/layouts/layout2x4.cpp index 4e04bb9ca..fbf6a7a81 100644 --- a/radio/src/gui/colorlcd/layouts/layout2x4.cpp +++ b/radio/src/gui/colorlcd/layouts/layout2x4.cpp @@ -20,12 +20,6 @@ #include "opentx.h" -#define HAS_TOPBAR() (persistentData->options[0].value.boolValue == true) -#define HAS_FM() (persistentData->options[1].value.boolValue == true) -#define HAS_SLIDERS() (persistentData->options[2].value.boolValue == true) -#define HAS_TRIMS() (persistentData->options[3].value.boolValue == true) -#define IS_MIRRORED() (persistentData->options[4].value.boolValue == true) - constexpr coord_t border = 10; const uint8_t LBM_LAYOUT_2x4[] = { @@ -69,7 +63,7 @@ class Layout2x4: public Layout rect_t getZone(unsigned int index) const override { - if (IS_MIRRORED()) + if (isMirrored()) index = 7 - index; rect_t zone = getMainZone({border, border, LCD_W - 2 * border, LCD_H - 2 * border});