Screen Setup fixed

This commit is contained in:
Bertrand Songis
2019-10-19 19:07:03 +02:00
parent d2eecac722
commit 4bcce12d76
2 changed files with 5 additions and 6 deletions
+2 -3
View File
@@ -56,8 +56,8 @@ class ColorBox: public Window {
LcdFlags color; LcdFlags color;
}; };
ColorEdit::ColorEdit(Window * parent, const rect_t & rect, std::function<uint16_t()> getValue, std::function<void(uint16_t)> setValue): ColorEdit::ColorEdit(FormGroup * parent, const rect_t & rect, std::function<uint16_t()> getValue, std::function<void(uint16_t)> setValue):
Window(parent, rect, FORWARD_SCROLL) FormGroup(parent, rect, FORWARD_SCROLL | FORM_FORWARD_FOCUS)
{ {
auto width = rect.w / 4 - 5; auto width = rect.w / 4 - 5;
@@ -77,7 +77,6 @@ ColorEdit::ColorEdit(Window * parent, const rect_t & rect, std::function<uint16_
box->setColor(value); box->setColor(value);
}); });
} }
} }
ColorEdit::~ColorEdit() ColorEdit::~ColorEdit()
+3 -3
View File
@@ -20,11 +20,11 @@
#ifndef _COLOREDIT_H_ #ifndef _COLOREDIT_H_
#define _COLOREDIT_H_ #define _COLOREDIT_H_
#include "window.h" #include "form.h"
class ColorEdit : public Window { class ColorEdit : public FormGroup {
public: public:
ColorEdit(Window * parent, const rect_t & rect, std::function<uint16_t()> getValue, std::function<void(uint16_t)> setValue = nullptr); ColorEdit(FormGroup * parent, const rect_t & rect, std::function<uint16_t()> getValue, std::function<void(uint16_t)> setValue = nullptr);
#if defined(DEBUG_WINDOWS) #if defined(DEBUG_WINDOWS)
std::string getName() override std::string getName() override