Skip to content

Commit

Permalink
Fix rebase.
Browse files Browse the repository at this point in the history
  • Loading branch information
philmoz committed Jun 20, 2024
1 parent 13c36e5 commit af86149
Show file tree
Hide file tree
Showing 14 changed files with 39 additions and 38 deletions.
16 changes: 8 additions & 8 deletions radio/src/gui/colorlcd/fullscreen_dialog.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,14 +58,14 @@ class FullScreenDialog : public Window

void closeDialog();

static LAYOUT_VAL(ALERT_FRAME_TOP, 50, 70)
static LAYOUT_VAL(ALERT_FRAME_HEIGHT, LCD_H - 120, LCD_H - 2 * ALERT_FRAME_TOP)
static LAYOUT_VAL(ALERT_BITMAP_TOP, ALERT_FRAME_TOP + 25, ALERT_FRAME_TOP + 15)
static LAYOUT_VAL(ALERT_BITMAP_LEFT, 20, 15)
static LAYOUT_VAL(ALERT_TITLE_TOP, ALERT_FRAME_TOP + 5, ALERT_FRAME_TOP + 10)
static LAYOUT_VAL(ALERT_TITLE_LEFT, 146, 140)
static LAYOUT_VAL(ALERT_MESSAGE_TOP, ALERT_TITLE_TOP + 85, ALERT_TITLE_TOP + 130)
static LAYOUT_VAL(ALERT_MESSAGE_LEFT, ALERT_TITLE_LEFT, 15)
static LAYOUT_VAL(ALERT_FRAME_TOP, 50, 70, LS(50))
static LAYOUT_VAL(ALERT_FRAME_HEIGHT, LCD_H - 120, LCD_H - 2 * ALERT_FRAME_TOP, LCD_H - LS(120))
static LAYOUT_VAL(ALERT_BITMAP_TOP, ALERT_FRAME_TOP + 25, ALERT_FRAME_TOP + 15, ALERT_FRAME_TOP +LS(25))
static LAYOUT_VAL(ALERT_BITMAP_LEFT, 20, 15, LS(20))
static LAYOUT_VAL(ALERT_TITLE_TOP, ALERT_FRAME_TOP + 5, ALERT_FRAME_TOP + 10, ALERT_FRAME_TOP + LS(5))
static LAYOUT_VAL(ALERT_TITLE_LEFT, 146, 140, LS(146))
static LAYOUT_VAL(ALERT_MESSAGE_TOP, ALERT_TITLE_TOP + 85, ALERT_TITLE_TOP + 130, ALERT_TITLE_TOP + LS(85))
static LAYOUT_VAL(ALERT_MESSAGE_LEFT, ALERT_TITLE_LEFT, 15, ALERT_TITLE_LEFT)

protected:
uint8_t type;
Expand Down
2 changes: 1 addition & 1 deletion radio/src/gui/colorlcd/model_curves.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class ModelCurvesPage : public PageTab

virtual void build(Window* window) override;

static LAYOUT_VAL(PER_ROW, 3, 2)
static LAYOUT_VAL(PER_ROW, 3, 2, LS(3))

protected:
uint8_t focusIndex = -1;
Expand Down
2 changes: 1 addition & 1 deletion radio/src/gui/colorlcd/model_flightmodes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ class FlightModeEdit : public Page
}
}

static LAYOUT_VAL(TRIMS_PER_LINE, 2, 1)
static LAYOUT_VAL(TRIMS_PER_LINE, 2, 1, 2)

protected:
uint8_t index;
Expand Down
2 changes: 1 addition & 1 deletion radio/src/gui/colorlcd/model_telemetry.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -800,7 +800,7 @@ class SensorEditWindow : public SubPage
updateSensorParameters();
}

static LAYOUT_VAL(NUM_EDIT_W, 100, 80)
static LAYOUT_VAL(NUM_EDIT_W, 100, 80, LS(100))
};

ModelTelemetryPage::ModelTelemetryPage() :
Expand Down
16 changes: 8 additions & 8 deletions radio/src/gui/colorlcd/model_usbjoystick.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ class USBChannelEditStatusBar : public Window
channel, true);
}

static LAYOUT_VAL(USBCH_EDIT_STATUS_BAR_MARGIN, 3, 0)
static LAYOUT_VAL(USBCH_EDIT_STATUS_BAR_MARGIN, 3, 0, LS(3))

protected:
ComboChannelBar* channelBar;
Expand Down Expand Up @@ -215,9 +215,9 @@ class USBChannelEditWindow : public Page
buildBody(body);
}

static LAYOUT_VAL(USBCH_EDIT_STATUS_BAR_WIDTH, 250, 160)
static LAYOUT_VAL(USBCH_EDIT_RIGHT_MARGIN, 0, 3)
static LAYOUT_VAL(USBCH_COLS, 4, 2)
static LAYOUT_VAL(USBCH_EDIT_STATUS_BAR_WIDTH, 250, 160, LS(250))
static LAYOUT_VAL(USBCH_EDIT_RIGHT_MARGIN, 0, 3, 0)
static LAYOUT_VAL(USBCH_COLS, 4, 2, 4)

protected:
uint8_t channel;
Expand Down Expand Up @@ -488,10 +488,10 @@ class USBChannelLineButton : public ListLineButton

bool isActive() const override { return false; }

static LAYOUT_VAL(USBCH_LINE_HEIGHT, 32, 48)
static LAYOUT_VAL(USBCH_CHN_ROWS, 1, 2)
static LAYOUT_VAL(USBCH_BTN_MODE_COL, 4, 2)
static LAYOUT_VAL(USBCH_BTN_MODE_ROW, 0, 1)
static LAYOUT_VAL(USBCH_LINE_HEIGHT, 32, 48, LS(32))
static LAYOUT_VAL(USBCH_CHN_ROWS, 1, 2, 1)
static LAYOUT_VAL(USBCH_BTN_MODE_COL, 4, 2, 4)
static LAYOUT_VAL(USBCH_BTN_MODE_ROW, 0, 1, 0)

protected:
bool init = false;
Expand Down
4 changes: 2 additions & 2 deletions radio/src/gui/colorlcd/radio_diaganas.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ class AnaCalibratedViewWindow : public AnaViewWindow
}
#endif

static LAYOUT_VAL(TSI2CEventsCol, 5, 0)
static LAYOUT_VAL(TSI2CEventsCol, 5, 0, 5)

protected:
#if defined(HARDWARE_TOUCH)
Expand Down Expand Up @@ -448,7 +448,7 @@ class AnaMinMaxViewWindow : public AnaViewWindow
AnaViewWindow::checkEvents();
}

static LAYOUT_VAL(GRIDCOLS, 10, 5)
static LAYOUT_VAL(GRIDCOLS, 10, 5, 10)
};

class AnaCalibratedViewPage : public PageTab
Expand Down
4 changes: 2 additions & 2 deletions radio/src/gui/colorlcd/radio_ghost_module_config.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ class GhostModuleConfigWindow : public Window
}
}

static LAYOUT_VAL(xOffset, 140, 20)
static LAYOUT_VAL(xOffset2, 260, 140)
static LAYOUT_VAL(xOffset, 140, 20, LS(140))
static LAYOUT_VAL(xOffset2, 260, 140, LS(260))

protected:
StaticText* menuLines[GHST_MENU_LINES][2];
Expand Down
4 changes: 2 additions & 2 deletions radio/src/gui/colorlcd/radio_sdmanager.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ class RadioSdManagerPage : public PageTab
RadioSdManagerPage();
void build(Window* window) override;

static LAYOUT_VAL(PREVIEW_W, LCD_W * 2 / 5 - PAD_SMALL * 2, LCD_W - PAD_MEDIUM * 2)
static LAYOUT_VAL(PREVIEW_H, LCD_H - 68, (LCD_H - 68) / 3)
static LAYOUT_VAL(PREVIEW_W, LCD_W * 2 / 5 - PAD_SMALL * 2, LCD_W - PAD_MEDIUM * 2, LCD_W * 2 / 5 - PAD_SMALL * 2)
static LAYOUT_VAL(PREVIEW_H, LCD_H - 68, (LCD_H - 68) / 3, LCD_H - LS(68))

protected:
void fileAction(const char* path, const char* name, const char* fullpath);
Expand Down
2 changes: 1 addition & 1 deletion radio/src/gui/colorlcd/sourcechoice.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ class SourceChoiceMenuToolbar : public MenuToolbar
}
}

static LAYOUT_VAL(FILTER_COLUMNS, 3, 2)
static LAYOUT_VAL(FILTER_COLUMNS, 3, 2, LS(3))

protected:
#if defined(HARDWARE_TOUCH)
Expand Down
8 changes: 4 additions & 4 deletions radio/src/gui/colorlcd/tabsgroup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -220,10 +220,10 @@ class TabsGroupHeader : public Window
bool isCurrent(uint8_t idx) const { return currentIndex == idx; }
uint8_t tabCount() const { return buttons.size(); }

static LAYOUT_VAL(DATE_XO, 48, 48)
static LAYOUT_VAL(DATE_Y, 6, 6)
static LAYOUT_VAL(MENU_HEADER_BUTTON_WIDTH, 33, 33)
static LAYOUT_VAL(HDR_DATE_FULL_WIDTH, 51, 51)
static LAYOUT_VAL(DATE_XO, 48, 48, LS(48))
static LAYOUT_VAL(DATE_Y, 6, 6, LS(6))
static LAYOUT_VAL(MENU_HEADER_BUTTON_WIDTH, 33, 33, LS(33))
static LAYOUT_VAL(HDR_DATE_FULL_WIDTH, 51, 51, LS(51))

protected:
uint8_t currentIndex = 0;
Expand Down
8 changes: 4 additions & 4 deletions radio/src/gui/colorlcd/theme_manager.h
Original file line number Diff line number Diff line change
Expand Up @@ -165,9 +165,9 @@ class HeaderDateTime : public Window

void setColor(uint32_t color);

static LAYOUT_VAL(HDR_DATE_WIDTH, 45, 45)
static LAYOUT_VAL(HDR_DATE_HEIGHT, 12, 12)
static LAYOUT_VAL(HDR_DATE_LINE2, 15, 15)
static LAYOUT_VAL(HDR_DATE_WIDTH, 45, 45,LS(45))
static LAYOUT_VAL(HDR_DATE_HEIGHT, 12, 12, LS(12))
static LAYOUT_VAL(HDR_DATE_LINE2, 15, 15, LS(15))

protected:
lv_obj_t *date = nullptr;
Expand All @@ -188,7 +188,7 @@ class UsbSDConnected : public Window
public:
UsbSDConnected();

static LAYOUT_VAL(HDR_DATE_Y, 6, 6)
static LAYOUT_VAL(HDR_DATE_Y, 6, 6, LS(6))

protected:
HeaderDateTime* dateTime = nullptr;
Expand Down
4 changes: 2 additions & 2 deletions radio/src/gui/colorlcd/view_channels.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ class ChannelsViewFooter : public Window
STR_MONITOR_MIXER_DESC, COLOR_THEME_PRIMARY2);
}

static LAYOUT_VAL(LEG_COLORBOX, 14, 14)
static LAYOUT_VAL(TXT_H, 18, 18)
static LAYOUT_VAL(LEG_COLORBOX, 14, 14, LS(14))
static LAYOUT_VAL(TXT_H, 18, 18, LS(18))
};

//-----------------------------------------------------------------------------
Expand Down
1 change: 1 addition & 0 deletions radio/src/gui/colorlcd/view_logical_switches.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ class LogicalSwitchesViewPage : public PageTab
LogicalSwitchesViewPage();

static LAYOUT_VAL(FOOTER_HEIGHT, 20, 40, LS(20))
static LAYOUT_VAL(BTN_WIDTH, 57, 76, LS(57))
static LAYOUT_VAL(BTN_HEIGHT, 20, 21, 18)
static LAYOUT_VAL(BTN_MATRIX_COL, 8, 4, 8)

Expand Down
4 changes: 2 additions & 2 deletions radio/src/gui/colorlcd/view_main_menu.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ class ViewMainMenu : public Window
void onClicked() override;
void deleteLater(bool detach = true, bool trash = true) override;

static LAYOUT_VAL(QM_COLS, 4, 3)
static LAYOUT_VAL(QM_ROWS, 2, 3)
static LAYOUT_VAL(QM_COLS, 4, 3, 4)
static LAYOUT_VAL(QM_ROWS, 2, 3, 2)

protected:
std::function<void()> closeHandler = nullptr;
Expand Down

0 comments on commit af86149

Please sign in to comment.