fix(color): subtrim value on Outputs page not updated when copying all trims to sub trims (#6998)
This commit is contained in:
@@ -228,6 +228,8 @@ void ModelOutputsPage::build(Window* window)
|
||||
STR_TRIMS2OFFSETS, STR_ADD_ALL_TRIMS_TO_SUBTRIMS,
|
||||
[=] {
|
||||
moveTrimsToOffsets();
|
||||
for (int i = 0; i < outputButtons.size(); i += 1)
|
||||
outputButtons[i]->refresh();
|
||||
});
|
||||
return 0;
|
||||
});
|
||||
@@ -241,6 +243,8 @@ void ModelOutputsPage::build(Window* window)
|
||||
lv_obj_set_pos(btn->getLvObj(), TRIMB_X, TRIMB_Y + (ch * (OutputLineButton::CH_LINE_H + PAD_TINY)));
|
||||
btn->setWidth(TRIMB_W);
|
||||
|
||||
outputButtons.emplace_back(btn);
|
||||
|
||||
LimitData* output = limitAddress(ch);
|
||||
btn->setPressHandler([=]() -> uint8_t {
|
||||
Menu* menu = new Menu();
|
||||
|
||||
@@ -21,6 +21,8 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include "pagegroup.h"
|
||||
|
||||
class OutputLineButton;
|
||||
@@ -49,5 +51,7 @@ class ModelOutputsPage : public PageGroupItem
|
||||
static constexpr coord_t TRIMB_W = LCD_W - PAD_SMALL * 2;
|
||||
|
||||
protected:
|
||||
std::vector<OutputLineButton*> outputButtons;
|
||||
|
||||
void editOutput(uint8_t channel, OutputLineButton* btn);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user